refactor: Layers/Keyboard component (#82)

This commit is contained in:
Nejc Zdovc
2016-08-28 00:59:19 +02:00
committed by József Farkas
parent 9dfc02214d
commit e54d63e1c5
20 changed files with 427 additions and 271 deletions

View File

@@ -1,10 +1,12 @@
import {Serializable} from '../Serializable';
import {Modules} from './Modules';
import {UhkBuffer} from '../UhkBuffer';
import { Serializable } from '../Serializable';
import { Modules } from './Modules';
import { UhkBuffer } from '../UhkBuffer';
import { AnimationKeyboard } from '../../src/components/svg/wrap';
export class Layer extends Serializable<Layer> {
modules: Modules;
animation: AnimationKeyboard = 'none';
_fromJsObject(jsObject: any): Layer {
this.modules = new Modules().fromJsObject(jsObject.modules);

View File

@@ -785,6 +785,25 @@
]
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "scroll",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": [
{
"keyActionType": "keystroke",
"scancode": 111
}
]
}
]
}
]
},
@@ -830,6 +849,63 @@
]
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "scroll",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": [
{
"keyActionType": "keystroke",
"scancode": 111
}
]
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "scroll",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": [
{
"keyActionType": "keystroke",
"scancode": 111
}
]
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "scroll",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": [
{
"keyActionType": "keystroke",
"scancode": 111
}
]
}
]
}
]
},
@@ -839,6 +915,48 @@
"abbreviation": "DVR",
"name": "DVR",
"layers": [
{
"modules": [
{
"id": 0,
"pointerRole": "move",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": []
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "move",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": []
}
]
},
{
"modules": [
{
"id": 0,
"pointerRole": "move",
"keyActions": []
},
{
"id": 1,
"pointerRole": "move",
"keyActions": []
}
]
},
{
"modules": [
{