@checksub_team/peaks_timeline 1.13.0 → 1.13.2
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/package.json +1 -1
- package/peaks.js +5 -3
- package/src/sources-layer.js +5 -3
package/package.json
CHANGED
package/peaks.js
CHANGED
|
@@ -19920,7 +19920,7 @@ module.exports = function (SourceGroup, Lines, DataRetriever, Utils, Invoker, Ko
|
|
|
19920
19920
|
var frameStartTime = self._view.pixelsToTime(frameOffset);
|
|
19921
19921
|
var frameEndTime = self._view.pixelsToTime(frameOffset + width);
|
|
19922
19922
|
sources.forEach(function (source) {
|
|
19923
|
-
self._addSourceGroup(source);
|
|
19923
|
+
self._addSourceGroup(source, source.isVisible(frameStartTime, frameEndTime));
|
|
19924
19924
|
});
|
|
19925
19925
|
this._view.updateTimelineLength();
|
|
19926
19926
|
this.updateSources(frameStartTime, frameEndTime);
|
|
@@ -19982,11 +19982,13 @@ module.exports = function (SourceGroup, Lines, DataRetriever, Utils, Invoker, Ko
|
|
|
19982
19982
|
SourcesLayer.prototype._createSourceGroup = function (source) {
|
|
19983
19983
|
return new SourceGroup(source, this._peaks, this, this._view);
|
|
19984
19984
|
};
|
|
19985
|
-
SourcesLayer.prototype._addSourceGroup = function (source) {
|
|
19985
|
+
SourcesLayer.prototype._addSourceGroup = function (source, startDataRetrieval = true) {
|
|
19986
19986
|
var sourceGroup = this._createSourceGroup(source);
|
|
19987
19987
|
this._sourcesGroup[source.id] = sourceGroup;
|
|
19988
19988
|
this._lines.addSourceGroup(sourceGroup, source.position);
|
|
19989
|
-
|
|
19989
|
+
if (startDataRetrieval) {
|
|
19990
|
+
this._dataRetriever.retrieveData(source);
|
|
19991
|
+
}
|
|
19990
19992
|
return sourceGroup;
|
|
19991
19993
|
};
|
|
19992
19994
|
SourcesLayer.prototype.setIndicators = function (source) {
|
package/src/sources-layer.js
CHANGED
|
@@ -185,7 +185,7 @@ define([
|
|
|
185
185
|
var frameEndTime = self._view.pixelsToTime(frameOffset + width);
|
|
186
186
|
|
|
187
187
|
sources.forEach(function(source) {
|
|
188
|
-
self._addSourceGroup(source);
|
|
188
|
+
self._addSourceGroup(source, source.isVisible(frameStartTime, frameEndTime));
|
|
189
189
|
});
|
|
190
190
|
|
|
191
191
|
this._view.updateTimelineLength();
|
|
@@ -282,14 +282,16 @@ define([
|
|
|
282
282
|
* @returns {Konva.Group}
|
|
283
283
|
*/
|
|
284
284
|
|
|
285
|
-
SourcesLayer.prototype._addSourceGroup = function(source) {
|
|
285
|
+
SourcesLayer.prototype._addSourceGroup = function(source, startDataRetrieval = true) {
|
|
286
286
|
var sourceGroup = this._createSourceGroup(source);
|
|
287
287
|
|
|
288
288
|
this._sourcesGroup[source.id] = sourceGroup;
|
|
289
289
|
this._lines.addSourceGroup(sourceGroup, source.position);
|
|
290
290
|
|
|
291
291
|
// After creating and referencing the new group, we can start data retrieval
|
|
292
|
-
|
|
292
|
+
if (startDataRetrieval) {
|
|
293
|
+
this._dataRetriever.retrieveData(source);
|
|
294
|
+
}
|
|
293
295
|
|
|
294
296
|
return sourceGroup;
|
|
295
297
|
};
|