mobility-toolbox-js 1.7.8-beta.4 → 1.7.8-beta.7
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.
package/api/tralis/TralisAPI.js
CHANGED
|
@@ -183,7 +183,7 @@ class WebSocketConnector {
|
|
|
183
183
|
source += params.args ? ` ${params.args}` : '';
|
|
184
184
|
|
|
185
185
|
// Buffer channel message return a list of other channels to propagate to proper callbacks.
|
|
186
|
-
const contents =
|
|
186
|
+
const contents = data.source === 'buffer' ? data.content : [data];
|
|
187
187
|
contents.forEach((content) => {
|
|
188
188
|
// Because of backend optimization, the last content is null.
|
|
189
189
|
if (
|
|
@@ -440,7 +440,9 @@ const TrackerLayerMixin = (Base) =>
|
|
|
440
440
|
this.stop();
|
|
441
441
|
unByKey(this.visibilityRef);
|
|
442
442
|
if (this.tracker) {
|
|
443
|
-
this.
|
|
443
|
+
const { canvas } = this.tracker;
|
|
444
|
+
const context = canvas.getContext('2d');
|
|
445
|
+
context.clearRect(0, 0, canvas.width, canvas.height);
|
|
444
446
|
this.tracker = null;
|
|
445
447
|
}
|
|
446
448
|
super.terminate();
|