
13 Aug
2009
13 Aug
'09
3:57 p.m.
This is a rewrite of a patch I sent some time ago, to which there was no response, so I assume it was just forgotten. It has a cleaner interface than my previous attempt. These patches add support for storing custom state information in XState in contrib modules as an alternative to using IORefs, which adds more complexity to the user interface. As an example, users of X.A.SpawnOn, no longer have to call mkSpawner, pass that IORef to their keybindings and the manage hook, but can now just add manageSpawn to their manageHook and use the keybindings normally. The same applies to X.H.DynamicHooks. It also removes uses of unsafePerformIO in X.H.UrgencyHook which were there to avoid the described interface complexity.