s/KeyLayer/LayerName/g

This commit is contained in:
Sam Rang
2016-04-16 21:12:05 -05:00
parent 2dc51f3d72
commit 38238f4d5a
@@ -1,4 +1,4 @@
enum KeyLayer { enum LayerName {
mod, mod,
fn, fn,
mouse mouse
@@ -10,12 +10,12 @@ class SwitchLayerAction extends KeyAction {
isLayerToggleable: boolean; isLayerToggleable: boolean;
// @assertEnum(KeyLayer) // @assertEnum(LayerName)
private layer: KeyLayer; private layer: LayerName;
_fromJsObject(jsObject: any): SwitchLayerAction { _fromJsObject(jsObject: any): SwitchLayerAction {
this.assertKeyActionType(jsObject); this.assertKeyActionType(jsObject);
this.layer = KeyLayer[<string> jsObject.layer]; this.layer = LayerName[<string> jsObject.layer];
this.isLayerToggleable = jsObject.toggle; this.isLayerToggleable = jsObject.toggle;
return this; return this;
} }
@@ -31,7 +31,7 @@ class SwitchLayerAction extends KeyAction {
_toJsObject(): any { _toJsObject(): any {
return { return {
keyActionType: keyActionType.SwitchLayerAction, keyActionType: keyActionType.SwitchLayerAction,
layer: KeyLayer[this.layer], layer: LayerName[this.layer],
toggle: this.isLayerToggleable toggle: this.isLayerToggleable
}; };
} }