mirror of
https://github.com/piskelapp/piskel.git
synced 2023-08-10 21:12:52 +03:00
feature : add keyboard shortcuts : Events cleanup
+ Removed unused events
This commit is contained in:
parent
eb559eee0c
commit
5d83a39cf0
19
js/Events.js
19
js/Events.js
@ -15,22 +15,6 @@ var Events = {
|
|||||||
*/
|
*/
|
||||||
LOCALSTORAGE_REQUEST: "LOCALSTORAGE_REQUEST",
|
LOCALSTORAGE_REQUEST: "LOCALSTORAGE_REQUEST",
|
||||||
|
|
||||||
CANVAS_RIGHT_CLICKED: "CANVAS_RIGHT_CLICKED",
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Event to request a refresh of the display.
|
|
||||||
* A bit overkill but, it's just workaround in our current drawing system.
|
|
||||||
* TODO: Remove or rework when redraw system is refactored.
|
|
||||||
*/
|
|
||||||
REFRESH: "REFRESH",
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Temporary event to bind the redraw of right preview film to the canvas.
|
|
||||||
* This redraw should be driven by model updates.
|
|
||||||
* TODO(vincz): Remove.
|
|
||||||
*/
|
|
||||||
REDRAW_PREVIEWFILM: "REDRAW_PREVIEWFILM",
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Fired each time a user setting change.
|
* Fired each time a user setting change.
|
||||||
* The payload will be:
|
* The payload will be:
|
||||||
@ -39,7 +23,6 @@ var Events = {
|
|||||||
*/
|
*/
|
||||||
USER_SETTINGS_CHANGED: "USER_SETTINGS_CHANGED",
|
USER_SETTINGS_CHANGED: "USER_SETTINGS_CHANGED",
|
||||||
|
|
||||||
/* Listened to by SettingsController */
|
|
||||||
CLOSE_SETTINGS_DRAWER : "CLOSE_SETTINGS_DRAWER",
|
CLOSE_SETTINGS_DRAWER : "CLOSE_SETTINGS_DRAWER",
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -50,8 +33,6 @@ var Events = {
|
|||||||
|
|
||||||
FRAME_SIZE_CHANGED : "FRAME_SIZE_CHANGED",
|
FRAME_SIZE_CHANGED : "FRAME_SIZE_CHANGED",
|
||||||
|
|
||||||
CURRENT_FRAME_SET: "CURRENT_FRAME_SET",
|
|
||||||
|
|
||||||
SELECTION_CREATED: "SELECTION_CREATED",
|
SELECTION_CREATED: "SELECTION_CREATED",
|
||||||
SELECTION_MOVE_REQUEST: "SELECTION_MOVE_REQUEST",
|
SELECTION_MOVE_REQUEST: "SELECTION_MOVE_REQUEST",
|
||||||
SELECTION_DISMISSED: "SELECTION_DISMISSED",
|
SELECTION_DISMISSED: "SELECTION_DISMISSED",
|
||||||
|
@ -43,7 +43,6 @@
|
|||||||
this.initMouseBehavior();
|
this.initMouseBehavior();
|
||||||
|
|
||||||
$.subscribe(Events.TOOL_SELECTED, $.proxy(function(evt, toolBehavior) {
|
$.subscribe(Events.TOOL_SELECTED, $.proxy(function(evt, toolBehavior) {
|
||||||
console.log("Tool selected: ", toolBehavior);
|
|
||||||
this.currentToolBehavior = toolBehavior;
|
this.currentToolBehavior = toolBehavior;
|
||||||
this.overlayFrame.clear();
|
this.overlayFrame.clear();
|
||||||
}, this));
|
}, this));
|
||||||
@ -107,7 +106,6 @@
|
|||||||
|
|
||||||
if(event.button == 2) { // right click
|
if(event.button == 2) { // right click
|
||||||
this.isRightClicked = true;
|
this.isRightClicked = true;
|
||||||
$.publish(Events.CANVAS_RIGHT_CLICKED);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var coords = this.getSpriteCoordinates(event);
|
var coords = this.getSpriteCoordinates(event);
|
||||||
|
Loading…
Reference in New Issue
Block a user