-
Notifications
You must be signed in to change notification settings - Fork 556
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This fixes a bundle of bugs related to calling `Craft.stop()` and then `Crafty.init()`. - Clear global bound events on stop (regression caused by the new callback methods) - Add a `Crafty._preBind` method for internal use -- anything registered here will be bound when `Crafty.init()` is called (unless we did a soft stop). This works around a problem where we bound some events only once, when crafty.js was loaded. (Currently used in inputs.js and viewport.js) - Make sure that "CraftyStop" is triggered *before* we remove all event handlers! (This was messing up cleanup of dom event handlers, which in turn messed up registering new ones.) - Delete references to previously created graphics layers - Have graphics layers set their initial values in their init functions Some of these are really work arounds for how we initialize graphics layers, the viewport, etc. I think if we switch these to using the new systems idiom we can remove a lot of the changes above. (Definitely the "prebind" hack.)
- Loading branch information
Showing
7 changed files
with
71 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters