git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Simplifying the camelCase logic used in the CSS and Effects modules.
[jquery.git]
/
src
/
effects.js
diff --git
a/src/effects.js
b/src/effects.js
index
9c8abe5
..
9db341a
100644
(file)
--- a/
src/effects.js
+++ b/
src/effects.js
@@
-3,7
+3,6
@@
var elemdisplay = {},
rfxtypes = /toggle|show|hide/,
rfxnum = /^([+\-]=)?([\d+.\-]+)(.*)$/,
var elemdisplay = {},
rfxtypes = /toggle|show|hide/,
rfxnum = /^([+\-]=)?([\d+.\-]+)(.*)$/,
- rdashAlpha = /-([a-z])/ig,
timerId,
fxAttrs = [
// height animations
timerId,
fxAttrs = [
// height animations
@@
-12,11
+11,7
@@
var elemdisplay = {},
[ "width", "marginLeft", "marginRight", "paddingLeft", "paddingRight" ],
// opacity animations
[ "opacity" ]
[ "width", "marginLeft", "marginRight", "paddingLeft", "paddingRight" ],
// opacity animations
[ "opacity" ]
- ],
-
- fcamelCase = function( all, letter ) {
- return letter.toUpperCase();
- };
+ ];
jQuery.fn.extend({
show: function( speed, callback ) {
jQuery.fn.extend({
show: function( speed, callback ) {
@@
-125,7
+120,7
@@
jQuery.fn.extend({
self = this;
for ( p in prop ) {
self = this;
for ( p in prop ) {
- var name = p.replace(rdashAlpha, fcamelCase);
+ var name = jQuery.camelCase( p );
if ( p !== name ) {
prop[ name ] = prop[ p ];
if ( p !== name ) {
prop[ name ] = prop[ p ];