Oleg Gaidarenko
f61314ff5c
Fixes #8335 . Do not allow add data to non-elements (2.x). Closes gh-1232
2013-04-08 15:10:39 -04:00
Rick Waldron
73b315538f
Better approach the hasData side effects fix. Thanks gibson042
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-04-01 17:09:37 -04:00
Rick Waldron
332a490573
Avoid side-effects when calling jQuery.hasData
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-04-01 12:48:30 -04:00
stonelee
92b23673e6
No ticket: Move property descriptor assignment to save a byte. Close gh-1188.
2013-03-14 09:53:19 -04:00
Rick Waldron
692afbcc5f
Fixes #13551 . Guard against illegal data access by undefined elem-owner
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-03-03 19:40:33 -05:00
Rick Waldron
91824bd292
Simplify data-* attr lookup with camelKey
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-03-02 14:09:39 -05:00
Michał Gołębiowski
761b96c301
Fixes #13550 . .data should not miss attr() set data-* with hyphenated property names. Closes gh-1189
2013-03-02 13:04:48 -05:00
Rick Waldron
8f7218198d
Remove dup camelKey path
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-03-01 19:33:12 -05:00
Rick Waldron
3212a29369
Fixes #13548 . .data should not miss attr() set data-* with hyphenated property names
2013-03-01 19:02:57 -05:00
Richard Gibson
1b6be73721
No ticket: Squeeze data
2013-02-26 23:41:57 -05:00
Richard Gibson
85f1985f24
Fix #13494 : Fallback defineProperties to jQuery.extend. Close gh-1182.
...
Android<4 (ancient WebKit) doesn't have full ES5 support.
2013-02-26 22:38:06 -05:00
Richard Gibson
6d188186d4
No ticket: move jQuery.expando to core
2013-02-25 15:48:22 -05:00
Rick Waldron
93043d002a
Refactor: Data.prototype.access. Thanks to @RubyLouvre and @gibson042. Closes #1167
2013-02-13 12:14:20 -05:00
Rick Waldron
1d5d959ee0
Optimized Data rewrite
2013-02-11 12:39:44 -05:00
Richard Gibson
a5b456edff
Ref fd43865c
: restore correct logic
2013-02-04 09:35:33 -05:00
Rick Waldron
cf260fe285
Match the codebase standard, .split(" ") => .match( core_rnotwhite ) || []… no matter how awful it is >:|
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-02-03 18:09:49 -05:00
Rick Waldron
f50680898b
Standardize on a.indexOf(b) === -1, per @gibson042 review notes
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-02-03 18:04:53 -05:00
Rick Waldron
fd43865c6d
Reduce hasData per @gibson042 review notes.
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-02-03 17:55:28 -05:00
Rick Waldron
64630eaf85
Reduce Data.prototype.add by using the returned length value of this.owners.push(owner)
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-02-03 15:31:23 -05:00
Rick Waldron
7f94a5cc3a
2.0: Rewrite data.js (Incl. event, manipulation, tests)
2013-02-03 15:27:55 -05:00
Timmy Willison
f5110cdec0
Minor updates. All parameters of an internal function are for internal use only.
2013-01-30 20:36:58 -05:00
Richard Gibson
8871218cdf
Fix jQuery #13251 : use slice instead of substring
...
(cherry picked from commit 37eb6125c0
)
2013-01-17 17:01:42 -05:00
danilsomsikov
cc324abf73
Fix #8335 : Avoid memory leak by never setting data on non-element non-document nodes. Close gh-1127.
2013-01-16 14:31:29 -05:00
Dave Methvin
445dbd9d95
Revert data.js rewrite.
...
Reverts the following commits:
commit f717226b3a
Author: Rick Waldron <waldron.rick@gmail.com>
Date: Mon Dec 31 18:06:38 2012 -0500
Only splice from internal arrays when item actually exists.
commit b9cdc4136b
Author: Rick Waldron <waldron.rick@gmail.com>
Date: Mon Dec 31 16:20:35 2012 -0500
Updates to data.js re-write to pass events and manipulation
commit d1de3000c6
Author: Rick Waldron <waldron.rick@gmail.com>
Date: Mon Dec 31 15:09:45 2012 -0500
2.0: Rewrite data.js
2013-01-03 20:43:01 -05:00
Rick Waldron
f717226b3a
Only splice from internal arrays when item actually exists.
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2012-12-31 18:06:38 -05:00
Rick Waldron
b9cdc4136b
Updates to data.js re-write to pass events and manipulation (full pass in local test runs)
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2012-12-31 16:23:20 -05:00
Rick Waldron
d1de3000c6
2.0: Rewrite data.js
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2012-12-31 16:23:20 -05:00
Richard Gibson
0877d424e0
Fix #12959 : Optimize library-wide patterns
2012-11-27 01:59:22 +01:00
Richard Gibson
0ee9415902
Restore jQuery.access parameter mistakenly removed in 80d45a69
2012-11-06 09:53:00 -05:00
Dave Methvin
e8cf41a051
Fix #10544 . Remove deprecated .data() event namespaced triggering.
...
Data events were horribly slow, never documented, and caused strange interpretation of data items with dots in them.
2012-10-31 21:27:42 -04:00
Rick Waldron
812c6087ad
Brute force property removal when removeData([a,b,c]). Fixes #12786
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2012-10-24 14:12:28 -04:00
Dave Methvin
08341437e0
Remove deprecated $.uuid and dunseled $.deletedIds.
2012-10-20 22:18:29 -04:00
Rick Waldron
8076a33bd8
Don't expose jQuery.deletedIds. Close gh-889.
2012-10-20 21:02:21 -04:00
carldanley
08e134548f
Create private methods for processing data/removeData requests. Fixes #12519 , Closes gh-976
2012-10-16 11:15:41 -04:00
Richard Gibson
15b5dbfe23
Fix #12229 , size/consistency improvements. Close gh-887.
2012-09-18 18:04:31 -04:00
Dave Methvin
2263134b22
Fix #10863 . Allow newlines in JSON data- attributes.
2012-08-23 22:19:06 -04:00
Dave Methvin
ce15bd7d0c
Fix #7579 . Don't convert to number if it changes the string. Close gh-852.
...
Net effect here is that hex numbers and most exponential-format numbers or long sequences of digits will remain strings rather than being coerced to numbers. `The people have spoken.
2012-07-25 10:28:50 -04:00
Mike Sherov
8f01b92b8f
Follow the style guide, lose 72 bytes! Closes gh-840.
2012-07-09 21:39:22 -04:00
Richard Gibson
f8baea8f7a
DRY out removeData/cleanData, closes gh-838.
2012-07-06 09:22:44 -04:00
Dave Methvin
9e0c056171
Fix #10589 . Remove deprecated $.fn.data("events") special case.
...
No unit tests were harmed in the removal of this hack.
2012-06-11 17:16:19 -04:00
Rick Waldron
7c23b77af2
Strips IIFEs from modules; Always require built jQuery for tests.
2012-06-04 12:48:18 -04:00
Oleg
203a168980
Fix #8545 . Plug event handling memory leak in oldIE.
2012-04-04 21:38:46 -04:00
Sindre Sorhus
96bb57d4ef
Fix #11309 . Recognize hexadecimal in data attributes.
2012-02-09 20:27:27 -05:00
Dave Methvin
2c75a993be
Precompute the parts array; clean up a JSLint complaint.
...
Followup to 6c2a501de4
for bug #5571 .
2011-12-06 20:07:29 -05:00
Richard Gibson
6c2a501de4
Fix #5571 . Setters should treat undefined
as a no-op and be chainable.
2011-12-06 15:25:38 -05:00
Justin
abcdaf9043
It seems the convention is to use self
for caching jQuery ( this )
instead of using $this
.
2011-11-06 22:54:21 +00:00
Corey Frang
471290deb6
Removing a stale line of code in .data()
2011-11-06 17:24:44 -05:00
Rick Waldron
e086c22826
User internalKey instead of jQuery.expando. Fixes #10675
2011-11-06 16:05:45 -05:00
Dave Methvin
c82dbf1928
Make sure .data("events")
still works, for now.
2011-10-26 22:56:26 -04:00
Dave Methvin
24e416dca3
Fix #10588 . For now, event voyeurism only merits the look of disapproval.
...
If you are using `.data("events")` we would like to know how we can provide a documented interface that satisfies the need.
2011-10-26 17:04:15 -04:00