Alexander Ljungberg
8edee4e755
Fix accidental globals, cleanup.
2010-12-15 16:02:50 +01:00
Daniel Stolzenberg
29ed8f3116
fixed issues with "CPKeyValueObservingOptionPrior" and "CPKeyValueObservingOptionOld" on dependent keys caused by improper wrapped observation messages
2010-12-09 14:56:55 +01:00
Daniel Stolzenberg
4a142b5c02
implemented missing features of KVO for unordered to-many relationships in CPKeyValueCoding.j
2010-10-27 19:08:34 +02:00
Daniel Stolzenberg
6483ea233c
imported new implementation for unordered to-many relationships in CPKeyValueObserving.j/CPSet+KVO.j
2010-10-26 14:23:24 +02:00
Daniel Stolzenberg
895ed4f6ff
implemented missing replacement methods for accessor patterns in CPKeyValueObserving.j
2010-10-26 14:20:54 +02:00
Daniel Stolzenberg
5ff7e66981
implemented "will/didChangeValueForKey:withSetMutation:usingObjects:" in _CPKVOModelSubclass in CPKeyValueObserving.j
2010-10-26 14:17:39 +02:00
Daniel Stolzenberg
a2ff814796
added missing accessor patterns in "_replaceSetterForKey:" in CPKeyValueObserving.j
2010-10-26 14:13:21 +02:00
Daniel Stolzenberg
c1e42a2f3e
refactored duplicated method copying implementation
2010-10-26 14:11:47 +02:00
Daniel Stolzenberg
9e1c07b195
added "CPKeyValueSetMutationKind" definitions to CPKeyValueObserving.j
2010-10-26 14:08:56 +02:00
Daniel Stolzenberg
c71c732fc0
added "will/didChangeValueForKey:withSetMutation:usingObjects:" stubs to CPObject in CPKeyValueObserving.j
2010-10-26 14:06:56 +02:00
Klaas Pieter Annema
5074938437
implement KVO dependent key path support
2010-10-07 21:17:28 +02:00
Brian Donovan
0ce115bc9c
Ensure observeValueForKeyPath:ofObject:change:context is called consistently.
...
During the "normal" callback for new and old values, the ofObject:
parameter passed to the observer is the original receiver of the
addObserver:forKeyPath:options:context: call, but that isn't the case
with the call caused by the CPKeyValueObservingOptionInitial option.
This commit uses _targetObject, the receiver of the addObserver:...
call, rather than self, the _CPKVOProxy.
2010-10-05 07:45:43 -07:00
Alexander Ljungberg
febdf4092e
New implementation of change notifications from CPArrayController.
...
It is crucial that we send notification only before and after complete changes. In the middle notifications might cause observers to see or react to inconsistent data (e.g. selection indexes pointing to rows no longer present). Added some unit tests - more might be needed in the future. Fixed: before and after values when observing array controller key paths during content changes or rearranges were wrong. Fixed: the array controller sent out multiple redundant change notifications.
2010-08-23 18:53:29 -04:00
Klaas Pieter Annema and Ross Boucher
ff8e5ae42e
save _replacedKeys on the class in stead of the object instance
...
reviewed: Ross
2010-07-26 22:48:39 -07:00
Alexander Ljungberg and Ross Boucher
5c5412db67
Make didChangeValueForKey work even if willChangeValueForKey was not called.
2010-06-11 14:08:07 -07:00
Scott Kyle and Randall Luecke
1899250a53
Semicolons are nice...
2010-06-10 16:42:28 -05:00
Alexander Ljungberg
5ff8ddf5f3
Fewer bindings debug log messages.
2010-05-26 19:44:14 -04:00
Alexander Ljungberg
ed2c65dd6f
Merge branch 'master' of git://github.com/280north/cappuccino into bindings-merge
...
Conflicts:
AppKit/CPTableView.j
Foundation/CPArray+KVO.j
Foundation/CPArray.j
2010-05-26 19:05:04 -04:00
Stephen Ierodiaconou and Ross Boucher
b98f0b1427
Apply style rules to Foundation
2010-05-26 08:53:05 -07:00
Ross Boucher
be26ab9201
CPDictionary is now KVO compliant.
2010-05-24 10:09:39 -07:00
Ross Boucher
542e491bb4
whitespace cleanup.
2010-05-06 11:26:56 -07:00
Klaas Pieter Annema and Ross Boucher
9c9eb519df
call willChange* and didChange* methods on the actual classes
2010-05-06 11:23:49 -07:00
Klaas Pieter Annema
6f0ca9d94c
Merge branch 'master' into bindings
...
Conflicts:
AppKit/CPTableView.j
AppKit/_CPCornerView.j
Foundation/CPArray.j
Foundation/CPKeyValueCoding.j
Foundation/CPKeyValueObserving.j
2010-04-15 10:57:46 +02:00
Francisco Ryan Tolmasky I
3a35ab449b
Fixed failing KVO tests.
...
Reviewed by me.
2010-02-12 13:46:26 -08:00
Tom Robinson
9e62fdc0b8
added missing CPNull imports
2010-01-12 12:28:32 -08:00
Francisco Ryan Tolmasky I
b7d747ee17
Fixed a bug in CPTreeNode's KVO implementation.
...
Reviewed by me.
2010-01-05 15:49:16 -08:00
Francisco Ryan Tolmasky I
dd999a29fd
Added applyChange:toKeyPath: and inverseChangedDictionary to support "automatic" undo with KVO.
...
Reviewed by me.
2009-12-24 19:15:38 -08:00
Ross Boucher
a1e24a3f95
Fix a bug where keyPaths which had a component evaluating to self would send notifications containing the wrong keypath in the observation.
...
Includes test case.
2009-12-19 17:47:02 -05:00
Francisco Ryan Tolmasky I
d200df3e9c
Typo in last commit.
...
Reviewed by me.
2009-12-11 12:03:25 -08:00
Francisco Ryan Tolmasky I
eb43e416ae
Added CPProxy class to support better undo proxying in CPUndoManager.
...
Closes #370 .
Closes #371 .
Reviewed by me.
2009-12-11 11:38:26 -08:00
Ross Boucher
417b5c8b97
Merge branch 'master' into bindings
2009-09-20 18:14:17 -07:00
Ross Boucher
0ef4e9bca5
store dependent keys on the class object itself, rather than in a global map.
2009-07-26 23:56:18 -07:00
Ross Boucher
4370604165
Remove several CPDictionaries in favor of Objects, about a 15% performance gain.
2009-07-26 23:40:52 -07:00
Ross Boucher
5ce96b45bb
Slight performance improvement and memory improvement by moving the storage of KVO proxy objects.
2009-07-26 22:46:22 -07:00
Francisco Ryan Tolmasky I
4ad2c2221f
Merge branch 'master' into bindings
...
Conflicts:
AppKit/CPControl.j
AppKit/CPSlider.j
Foundation/CPArray+KVO.j
2009-07-22 16:41:58 -07:00
Francisco Ryan Tolmasky I
4865d6b20f
Fixed an issue with dependent keys in KVO only working for composed properties, and also made the "frame" key on views dependent on a view's frame origin and frame size.
...
Reviewed by me.
2009-07-20 20:37:19 -07:00
Francisco Ryan Tolmasky I
c74642b641
Replacing several instances of -hash with the new -UID method. Partial fix for http://github.com/280north/cappuccino/issues#issue/10 .
...
Reviewed by andrew.
2009-06-07 15:47:21 -07:00
Ross Boucher
c028425f14
More bindings fixes.
2009-02-09 17:35:25 -08:00
Ross Boucher
1b8aca26a3
In progress work on bindings.
2009-02-07 12:55:15 -07:00
Francisco Ryan Tolmasky I
bb135f041a
Changed CPArray_KVO.j to CPArray+KVO.j.
...
Reviewed by me.
2009-01-21 07:27:14 -08:00
Ross Boucher
6291804775
Support, fixes, and tests for KVC array operators.
2009-01-20 20:06:46 -08:00
Ross Boucher
0b05b4b7d8
Add KVC+KVO support for "To Many" keys (i.e. Arrays).
2009-01-20 18:51:10 -08:00
Ross Boucher
e859e9efc0
Add additional support for dependent keys, some performance improvements.
2009-01-19 01:42:39 -08:00
Ross Boucher
44e4af0f02
Experimental support for dependent keys. I say experimental because it slows down KVO by nearly 2x when its used.
2009-01-18 22:09:24 -08:00
Ross Boucher
9d34f3d4e6
Remove dead code, use just in time setter replacement.
...
Typo fix.
Better way to replace methods, courtesy of Francisco.
2009-01-18 16:55:15 -08:00
Francisco Ryan Tolmasky I
1a8093c314
Fix for minimizer not recognizing a var.
...
Reviewed by me.
2008-11-13 00:40:40 -08:00
Francisco Ryan Tolmasky I
5144a5a579
Added @accessor support, @import, and fixed spacing bug with @selector.
...
Reviewed by ross.
2008-10-26 00:48:49 -07:00
Ross Boucher
f228934e54
Initial conversion to Doxygen style comments.
2008-10-12 15:57:01 -07:00
Ross Boucher
ff140b8c4c
Improve KVO speed 50%, add dictionary support in KVC.
2008-09-27 11:33:36 -07:00
Ross Boucher
3834751aa3
Key Value Observing, with test cases.
2008-09-25 22:20:21 -07:00