/CHANGELOG.textile

http://github.com/robertpenner/as3-signals · Textile · 119 lines · 96 code · 23 blank · 0 comment · 0 complexity · eebeaf186eb79fa62fcd13d6ee9c509b MD5 · raw file

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