PageRenderTime 17ms CodeModel.GetById 10ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/CHANGELOG.textile

http://github.com/robertpenner/as3-signals
Unknown | 119 lines | 96 code | 23 blank | 0 comment | 0 complexity | eebeaf186eb79fa62fcd13d6ee9c509b MD5 | raw file
  1h2. AS3 Signals Changelog:
  2
  3h3. v0.9 - NeufGun
  4
  5h4. API Additions
  6* ISlot: listener registration object with many features.
  7** A slot stores values of *once* and *priority*, replacing the untyped "listener box" objects.
  8** A slot can *remove()* its listener from the signal.
  9** Has *enabled* toggle to temporarily disconnect the listener without removing it.
 10** The slot's *listener* can be changed on the fly.
 11** Has optional array of *params* which are appended to the signal's dispatched values before reaching the listener. Similar to delegates that store extra args.
 12* IOnceSignal: has *addOnce()* but not *add()*. Useful for completion signals that discard all listeners on dispatch. Idea by @alecmce.
 13* MonoSignal: can have only one listener. Useful for callbacks and SignalCommandMap request signals. Originally implemented as SingleSignal by @stickupkid.
 14* PrioritySignal: like DeluxeSignal without bubbling (thanks @neilmanuell).
 15* Native Signal Sets: 
 16** @jonopus developed an easy way to snap on NativeSignals to Sprite, Timer, etc. See *org.osflash.signals.natives.sets* package.
 17** Created SignalSprite, SignalTimer, etc. as example base classes. See *org.osflash.signals.natives.base* package.
 18
 19h4. API Changes
 20* Removed ISignalOwner, INativeSignalOwner and IDispatcher. They became annoying, e.g. casting ISignal to Signal just to dispatch. Moved their methods into ISignal.
 21* *add()*, *addOnce()* and *remove()* now return ISlot.  
 22
 23h4. Implementation Changes
 24* add() no longer checks listener.length because ...varargs listeners cannot be detected.
 25* Dispatching
 26** @joa created a new, faster dispatching engine (SlotList) using an immutable recursive linked list (inspired by Scala). The list is like a snake which gets eaten by a snake, which gets eaten by a larger snake, and so on.
 27** NOTE: Listeners are now called in reverse order, for best performance. If precise order is needed, use an IPrioritySignal. 
 28* Enhanced MXML friendliness (ArrayElementType, better examples). 
 29* More inheritance between signals to reduce code duplication.
 30
 31h4. Fixes
 32* DeluxeSignal: now handles subclass super() calls properly (thanks @stickupkid).
 33* NativeRelaySignal: better checks for null (thanks @stickupkid).
 34
 35h4. Tests
 36* Increased test coverage significantly. Many tests from @stickupkid.
 37* Refactored duplicated test code into base classes, e.g. ISignalTestBase. This greatly increased coverage across various implementations.
 38	
 39h4. Build
 40* Build now has a "package" target to zip SWC and source together.
 41* Build now has a "clean" target to remove generated folders.
 42* Flash Player executes on Linux (thanks @joa).
 43
 44h3. v0.8 - Maximilian - 2010-11-14
 45
 46h4. API Changes
 47* Signals are now MXML-friendly! Example:
 48<code>
 49  <signals:Signal id="nameChanged">{[String, uint]}</signals:Signal>
 50</code>
 51** Constructors are now nullable.
 52** valueClasses and eventClass are now writable.
 53** Exceptions: NativeMappedSignal and NativeRelaySignal are not yet MXML-friendly.
 54* Renamed IDeluxeSignal to IPrioritySignal, a more functional name.
 55* New interfaces to grant access to methods that affect all listeners:
 56** ISignalOwner: extends ISignal, IDispatcher, adds removeAll().
 57** INativeSignalOwner: extends IPrioritySignal, INativeDispatcher, adds removeAll().
 58** These 2 interfaces cannot be merged because dispatch(event:Event) conflicts with dispatch(...valueObjects).
 59** Thanks to "Brian Heylin":http://github.com/brianheylin for getting the ball rolling.
 60
 61h4. Fixes
 62* "#24 - Changing NativeSignal.target wasn't removing listeners from target.":http://github.com/robertpenner/as3-signals/issues/closed#issue/24
 63* "#32 - FIX: Setting NativeSignal.eventClass to null and dispatching causes null exception.":http://github.com/robertpenner/as3-signals/issues/closed#issue/32
 64
 65h4. Build
 66* Added continuous integration and unit test execution Ant targets: "ci" and "test".
 67* Updated AsUnit 4 SWC: test failure call stack is more concise and readable.
 68* Removed build-asunit.xml as its functionality has been merged into build.xml.
 69
 70
 71h3. v0.7 - Bubblap - 2010-05-27
 72
 73h4. API Changes
 74* Added NativeMappedSignal class from "Brian Heylin":http://github.com/brianheylin, with great "test coverage":http://github.com/brianheylin/as3-signals/tree/master/tests/org/osflash/signals/natives/.
 75** Addresses "#16 - Add ability to map native events to signals":http://github.com/robertpenner/as3-signals/issues/closed#issue/16
 76* DeluxeSignal has a simpler way to continue bubbling without re-dispatching the event.
 77** IBubbleEventHandler.onEventBubbled() now returns true/false to continue/cancel bubbling.
 78** Thanks to "secoif":http://github.com/secoif for the original code and "dehash":http://www.dehash.com/?p=241h for helping with the merge.
 79* ISignal and IDeluxeSignal: add(), addOnce() and remove() now return the listener.
 80** Thanks to "sammyt":http://github.com/sammyt for the contribution with unit tests.
 81
 82h4. Fixes
 83* Improved error message for Signal.dispatch() with too few arguments.
 84
 85h4. Test Changes
 86* The test suite is migrated to a newer version of AsUnit 4.
 87** Tests now receive an IAsync using [Inject]. No more Asyncleton!
 88** The migration pattern can be seen in "commit f6878.":http://github.com/robertpenner/as3-signals/commit/f6878dbbff95e0bd7832cc2d1cc2e7d55fb18098
 89** AllTestsRunner uses a "new composition pattern":http://github.com/robertpenner/as3-signals/commit/866a99570152b7399aa34839fd5c30789db67f3c instead of inheritance.
 90** Many thanks to "Luke Bayes":http://github.com/lukebayes and the "Bay Area Computer Club":http://github.com/bayareacomputerclub.
 91* Added more tests for argument dispatching and consolidated in SignalDispatchArgsTest.
 92
 93h3. v0.6 - GreenDay - 2010-03-17
 94
 95h4. API Changes
 96* "#15 - IDeluxeSignal and NativeSignal now have valueClasses property":http://github.com/robertpenner/as3-signals/issues/closed#issue/15
 97
 98h4. Fixes
 99* "#14 - NativeSignal.addOnce() can't be reused after native event dispatched":http://github.com/robertpenner/as3-signals/issues/closed#issue/14
100
101h4. Implementation Changes
102* Optimized listeners array cloning to use slice(), which is faster than concat().
103* Optimized dispatch() by moving the cloning of listeners to add(), addOnce(), and remove().
104* Signal.removeAll() now uses remove() on every listener, instead of fast array clearing. This is intended to avoid possible issues with subclass overrides (as happened before with NativeRelaySignal.remove()).
105* Renamed createListenerRelationship() to registerListener().
106* Consolidated add() and addOnce() logic in registerListener().
107* Removed onceListeners Dictionary from DeluxeSignal and NativeSignal.
108* DeluxeSignal and NativeSignal are now more unified in their "once listeners" internal implementations.
109* Removed an extra semicolon which made FDT cry (thanks "vitch":http://github.com/vitch).
110
111h4. Test Changes
112* Removed async [Test] metadata because AsUnit 4 no longer uses it.
113* Updated the AsUnit 4 SWC to newer version which avoids slowdown of Timers in Flash Player 10.1.
114* Added tests for ambiguous relationships in Signal.
115* Added tests for adding a listener during a dispatch().
116
117h3. v0.5 - GlassHalfFull - 2010-02-08
118
119* Added versioning to the Ant build, starting at 0.5.