@openglobus/og 0.18.2 → 0.18.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -20,10 +20,10 @@ class LabelWorker extends BaseWorker {
20
20
  make(data) {
21
21
  let label = data.label, handler = data.handler;
22
22
  if (handler._entityCollection) {
23
- if (this._workerQueue.length) {
24
- let w = this._workerQueue.pop();
25
- let labelData = label.serializeWorkerData(this._sourceId);
26
- if (labelData) {
23
+ let labelData = label.serializeWorkerData(this._sourceId);
24
+ if (labelData) {
25
+ if (this._workerQueue.length) {
26
+ let w = this._workerQueue.pop();
27
27
  this._source.set(this._sourceId, data);
28
28
  label._lockId = this._sourceId;
29
29
  this._sourceId++;
@@ -33,9 +33,9 @@ class LabelWorker extends BaseWorker {
33
33
  labelData.buffer,
34
34
  ]);
35
35
  }
36
- }
37
- else {
38
- this._pendingQueue.push(data);
36
+ else {
37
+ this._pendingQueue.push(data);
38
+ }
39
39
  }
40
40
  }
41
41
  }
@@ -116,6 +116,8 @@ class KeyboardHandler {
116
116
  return this._currentlyPressedKeys[keyCode];
117
117
  }
118
118
  handleKeyDown() {
119
+ // If you want to get a key code just uncomment and check console
120
+ //console.log(this._event!.keyCode);
119
121
  this._anykeyCallback && this._anykeyCallback.callback.call(this._anykeyCallback.sender, this._event);
120
122
  this._currentlyPressedKeys[this._event.keyCode] = true;
121
123
  for (let ch in this._charkeysCallbacks) {
@@ -1,4 +1,7 @@
1
1
  export const input = {
2
+ MB_LEFT: 0,
3
+ MB_RIGHT: 2,
4
+ MB_MIDDLE: 1,
2
5
  KEY_CTRL: 17,
3
6
  KEY_ALT: 18,
4
7
  KEY_SHIFT: 16,
@@ -34,9 +37,11 @@ export const input = {
34
37
  KEY_F1: 112,
35
38
  KEY_MINUS: 173,
36
39
  KEY_APOSTROPHE: 192,
37
- MB_LEFT: 0,
38
- MB_RIGHT: 2,
39
- MB_MIDDLE: 1,
40
40
  KEY_BACK_SLASH: 220,
41
+ KEY_MORE: 190,
42
+ KEY_SLASH: 191,
43
+ KEY_LESS: 188,
44
+ KEY_LEFT_SQUARE_BRACKET: 219,
45
+ KEY_RIGHT_SQUARE_BRACKET: 221,
41
46
  KEY_SINGLE_QUOTE: 222
42
47
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openglobus/og",
3
- "version": "0.18.2",
3
+ "version": "0.18.3",
4
4
  "description": "[openglobus](https://www.openglobus.org/) is a javascript/typescript library designed to display interactive 3d maps and planets with map tiles, imagery and vector data, markers, and 3D objects. It uses the WebGL technology, open source, and completely free.",
5
5
  "directories": {
6
6
  "example": "./sandbox"