diff --git a/js/Events.js b/js/Events.js index da20bbe2..64985864 100644 --- a/js/Events.js +++ b/js/Events.js @@ -1,6 +1,6 @@ // TODO(grosbouddha): put under pskl namespace. var Events = { - + TOOL_SELECTED : "TOOL_SELECTED", TOOL_RELEASED : "TOOL_RELEASED", PRIMARY_COLOR_SELECTED: "PRIMARY_COLOR_SELECTED", @@ -10,7 +10,7 @@ var Events = { /** * When this event is emitted, a request is sent to the localstorage - * Service to save the current framesheet. The storage service + * Service to save the current framesheet. The storage service * may not immediately store data (internal throttling of requests). */ LOCALSTORAGE_REQUEST: "LOCALSTORAGE_REQUEST", @@ -38,12 +38,12 @@ var Events = { * 2nd argument: New value */ USER_SETTINGS_CHANGED: "USER_SETTINGS_CHANGED", - + /** * The framesheet was reseted and is now probably drastically different. * Number of frames, content of frames, color used for the palette may have changed. */ - FRAMESHEET_RESET: "FRAMESHEET_RESET", + PISKEL_RESET: "PISKEL_RESET", FRAME_SIZE_CHANGED : "FRAME_SIZE_CHANGED", @@ -52,7 +52,7 @@ var Events = { SELECTION_CREATED: "SELECTION_CREATED", SELECTION_MOVE_REQUEST: "SELECTION_MOVE_REQUEST", SELECTION_DISMISSED: "SELECTION_DISMISSED", - + SHOW_NOTIFICATION: "SHOW_NOTIFICATION", HIDE_NOTIFICATION: "HIDE_NOTIFICATION", diff --git a/js/controller/LayersController.js b/js/controller/LayersController.js index 275b674c..f7c2c875 100644 --- a/js/controller/LayersController.js +++ b/js/controller/LayersController.js @@ -12,7 +12,7 @@ this.rootEl.addEventListener('click', this.onClick_.bind(this)); - $.subscribe(Events.FRAMESHEET_RESET, this.renderLayerList_.bind(this)); + $.subscribe(Events.PISKEL_RESET, this.renderLayerList_.bind(this)); this.renderLayerList_(); }; diff --git a/js/controller/PiskelController.js b/js/controller/PiskelController.js index 90971e0d..a8816b4d 100644 --- a/js/controller/PiskelController.js +++ b/js/controller/PiskelController.js @@ -12,7 +12,7 @@ this.layerIdCounter = 1; - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); $.publish(Events.FRAME_SIZE_CHANGED); }; @@ -74,7 +74,7 @@ this.setCurrentFrameIndex(this.currentFrameIndex - 1); } - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); }; ns.PiskelController.prototype.duplicateFrameAt = function (index) { @@ -98,12 +98,12 @@ ns.PiskelController.prototype.setCurrentFrameIndex = function (index) { this.currentFrameIndex = index; - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); }; ns.PiskelController.prototype.setCurrentLayerIndex = function (index) { this.currentLayerIndex = index; - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); }; ns.PiskelController.prototype.selectLayer = function (layer) { diff --git a/js/controller/PreviewFilmController.js b/js/controller/PreviewFilmController.js index d1635bc1..1ee0ed08 100644 --- a/js/controller/PreviewFilmController.js +++ b/js/controller/PreviewFilmController.js @@ -11,8 +11,8 @@ ns.PreviewFilmController.prototype.init = function() { $.subscribe(Events.TOOL_RELEASED, this.flagForRedraw_.bind(this)); - $.subscribe(Events.FRAMESHEET_RESET, this.flagForRedraw_.bind(this)); - $.subscribe(Events.FRAMESHEET_RESET, this.refreshDPI_.bind(this)); + $.subscribe(Events.PISKEL_RESET, this.flagForRedraw_.bind(this)); + $.subscribe(Events.PISKEL_RESET, this.refreshDPI_.bind(this)); $('#preview-list-scroller').scroll(this.updateScrollerOverflows.bind(this)); this.updateScrollerOverflows(); diff --git a/js/service/HistoryService.js b/js/service/HistoryService.js index 32b024ce..4e190479 100644 --- a/js/service/HistoryService.js +++ b/js/service/HistoryService.js @@ -17,12 +17,12 @@ ns.HistoryService.prototype.undo = function () { this.piskelController.getCurrentFrame().loadPreviousState(); - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); }; ns.HistoryService.prototype.redo = function () { this.piskelController.getCurrentFrame().loadNextState(); - $.publish(Events.FRAMESHEET_RESET); + $.publish(Events.PISKEL_RESET); }; })(); \ No newline at end of file