@raydiant/playlist-window-manager 0.0.0-test-1 → 0.0.0-test-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.
|
@@ -659,6 +659,7 @@ var PlaylistWindowManager = /** @class */ (function (_super) {
|
|
|
659
659
|
var presentation = this.state.getPresentation(presentationId);
|
|
660
660
|
var applicationVersion = this.state.getApplicationVersion(presentation.applicationDeploymentId);
|
|
661
661
|
var windowId = (0, uuid_1.v4)();
|
|
662
|
+
logger.info("playlist-window-manager/src/PlaylistWindowManager.ts createWindow1 ".concat(JSON.stringify(this.bounds)));
|
|
662
663
|
return new PresentationWindow_1.default({
|
|
663
664
|
windowManager: this,
|
|
664
665
|
renderer: this.renderer,
|
|
@@ -683,7 +684,7 @@ var PlaylistWindowManager = /** @class */ (function (_super) {
|
|
|
683
684
|
ruleEngineState: this.ruleEngine.state,
|
|
684
685
|
globalRule: this.ruleEngine.globalRule,
|
|
685
686
|
isPreview: isPreview,
|
|
686
|
-
workerState: this.workerState
|
|
687
|
+
workerState: this.workerState,
|
|
687
688
|
});
|
|
688
689
|
};
|
|
689
690
|
PlaylistWindowManager.prototype.loadCurrentWindow = function () {
|
|
@@ -998,12 +999,12 @@ var PlaylistWindowManager = /** @class */ (function (_super) {
|
|
|
998
999
|
};
|
|
999
1000
|
PlaylistWindowManager.prototype.emitCurrentWindowErrorEvent = function (event, error) {
|
|
1000
1001
|
return this.emitCurrentWindowEvent(event, {
|
|
1001
|
-
errorMessage: this.getErrorMessage(error)
|
|
1002
|
+
errorMessage: this.getErrorMessage(error),
|
|
1002
1003
|
});
|
|
1003
1004
|
};
|
|
1004
1005
|
PlaylistWindowManager.prototype.emitNextWindowErrorEvent = function (event, error) {
|
|
1005
1006
|
return this.emitNextWindowEvent(event, {
|
|
1006
|
-
errorMessage: this.getErrorMessage(error)
|
|
1007
|
+
errorMessage: this.getErrorMessage(error),
|
|
1007
1008
|
});
|
|
1008
1009
|
};
|
|
1009
1010
|
PlaylistWindowManager.prototype.getErrorMessage = function (error) {
|
|
@@ -818,8 +818,9 @@ var PresentationWindow = /** @class */ (function () {
|
|
|
818
818
|
didBoundsChange = prevBounds
|
|
819
819
|
? !(0, fast_deep_equal_1.default)(bounds, prevBounds)
|
|
820
820
|
: true;
|
|
821
|
+
this.logInfo("playlist-window-manager/src/PresentationWindow.ts openChildWindow1: ".concat(JSON.stringify(prevBounds)));
|
|
821
822
|
if (didBoundsChange) {
|
|
822
|
-
this.logInfo("playlist-window-manager/src/PresentationWindow.ts
|
|
823
|
+
this.logInfo("playlist-window-manager/src/PresentationWindow.ts openChildWindow2: ".concat(JSON.stringify(bounds)));
|
|
823
824
|
windowManager.updateBounds(bounds);
|
|
824
825
|
}
|
|
825
826
|
didForceMuteChange = forceMute !== prevForceMute;
|
|
@@ -839,7 +840,7 @@ var PresentationWindow = /** @class */ (function () {
|
|
|
839
840
|
}
|
|
840
841
|
return [3 /*break*/, 3];
|
|
841
842
|
case 1:
|
|
842
|
-
this.logInfo("playlist-window-manager/src/PresentationWindow.ts
|
|
843
|
+
this.logInfo("playlist-window-manager/src/PresentationWindow.ts openChildWindow3: ".concat(JSON.stringify(bounds)));
|
|
843
844
|
windowManager = new PlaylistWindowManager_1.default({
|
|
844
845
|
parentWindowId: windowId,
|
|
845
846
|
windowName: windowName,
|
package/package.json
CHANGED
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
Theme,
|
|
9
9
|
Logger,
|
|
10
10
|
WorkerState,
|
|
11
|
-
AnalyticsEvent
|
|
11
|
+
AnalyticsEvent,
|
|
12
12
|
} from './types';
|
|
13
13
|
import PresentationWindow from './PresentationWindow';
|
|
14
14
|
import PlaylistWindowManagerState from './PlaylistWindowManagerState';
|
|
@@ -84,12 +84,12 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
84
84
|
private overrideNextPresentation: RE.NextPresentationID | null = null;
|
|
85
85
|
private currentWindow: PresentationWindow | null = null;
|
|
86
86
|
private nextWindow: PresentationWindow | null = null;
|
|
87
|
-
private hasPendingInterrupt
|
|
87
|
+
private hasPendingInterrupt = false;
|
|
88
88
|
private ruleEngine: RE.RuleEngine | null = null;
|
|
89
89
|
private state: PlaylistWindowManagerState | null = null;
|
|
90
90
|
private renderer: PresentationWindowRenderer | null = null;
|
|
91
|
-
private restartCurrentWindowOnEnd
|
|
92
|
-
private shouldHardRestart
|
|
91
|
+
private restartCurrentWindowOnEnd = false;
|
|
92
|
+
private shouldHardRestart = false;
|
|
93
93
|
private currentWindowError: null | Error = null;
|
|
94
94
|
private interruptCheckTimeout: ReturnType<typeof setTimeout> | null = null;
|
|
95
95
|
private currentPresentationCompleteTimeout: ReturnType<
|
|
@@ -98,8 +98,8 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
98
98
|
private lastCompleteAt: Date | null = null;
|
|
99
99
|
private bounds?: WindowBounds;
|
|
100
100
|
private themeOverride?: Theme;
|
|
101
|
-
private forceMute
|
|
102
|
-
private isFocused
|
|
101
|
+
private forceMute = false;
|
|
102
|
+
private isFocused = false;
|
|
103
103
|
|
|
104
104
|
private workerState: WorkerState = {};
|
|
105
105
|
|
|
@@ -397,7 +397,7 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
397
397
|
}
|
|
398
398
|
}
|
|
399
399
|
|
|
400
|
-
public async show(isFocused
|
|
400
|
+
public async show(isFocused = true) {
|
|
401
401
|
if (this.currentWindow) {
|
|
402
402
|
// Save the focused state so we know if preloaded windows should be
|
|
403
403
|
// focused when swapped for the current.
|
|
@@ -450,7 +450,7 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
450
450
|
logger,
|
|
451
451
|
windowName,
|
|
452
452
|
parentWindowId,
|
|
453
|
-
isPreview
|
|
453
|
+
isPreview,
|
|
454
454
|
} = this.options;
|
|
455
455
|
|
|
456
456
|
if (!this.ruleEngine) {
|
|
@@ -480,6 +480,12 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
480
480
|
|
|
481
481
|
const windowId = uuidv4();
|
|
482
482
|
|
|
483
|
+
logger.info(
|
|
484
|
+
`playlist-window-manager/src/PlaylistWindowManager.ts createWindow1 ${JSON.stringify(
|
|
485
|
+
this.bounds
|
|
486
|
+
)}`
|
|
487
|
+
);
|
|
488
|
+
|
|
483
489
|
return new PresentationWindow({
|
|
484
490
|
windowManager: this,
|
|
485
491
|
renderer: this.renderer,
|
|
@@ -504,7 +510,7 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
504
510
|
ruleEngineState: this.ruleEngine.state,
|
|
505
511
|
globalRule: this.ruleEngine.globalRule,
|
|
506
512
|
isPreview,
|
|
507
|
-
workerState: this.workerState
|
|
513
|
+
workerState: this.workerState,
|
|
508
514
|
});
|
|
509
515
|
}
|
|
510
516
|
|
|
@@ -1006,7 +1012,7 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
1006
1012
|
if (window) {
|
|
1007
1013
|
this.emit(event, {
|
|
1008
1014
|
...window.metadata(),
|
|
1009
|
-
data
|
|
1015
|
+
data,
|
|
1010
1016
|
});
|
|
1011
1017
|
} else {
|
|
1012
1018
|
logger.warn(`Attempted to emit ${label} window event but window not set`);
|
|
@@ -1023,13 +1029,13 @@ export default class PlaylistWindowManager extends EventEmitter {
|
|
|
1023
1029
|
|
|
1024
1030
|
private emitCurrentWindowErrorEvent(event: string, error: any) {
|
|
1025
1031
|
return this.emitCurrentWindowEvent(event, {
|
|
1026
|
-
errorMessage: this.getErrorMessage(error)
|
|
1032
|
+
errorMessage: this.getErrorMessage(error),
|
|
1027
1033
|
});
|
|
1028
1034
|
}
|
|
1029
1035
|
|
|
1030
1036
|
private emitNextWindowErrorEvent(event: string, error: any) {
|
|
1031
1037
|
return this.emitNextWindowEvent(event, {
|
|
1032
|
-
errorMessage: this.getErrorMessage(error)
|
|
1038
|
+
errorMessage: this.getErrorMessage(error),
|
|
1033
1039
|
});
|
|
1034
1040
|
}
|
|
1035
1041
|
|
|
@@ -666,9 +666,15 @@ export default class PresentationWindow {
|
|
|
666
666
|
? !deepEqual(bounds, prevBounds)
|
|
667
667
|
: true;
|
|
668
668
|
|
|
669
|
+
this.logInfo(
|
|
670
|
+
`playlist-window-manager/src/PresentationWindow.ts openChildWindow1: ${JSON.stringify(
|
|
671
|
+
prevBounds
|
|
672
|
+
)}`
|
|
673
|
+
);
|
|
674
|
+
|
|
669
675
|
if (didBoundsChange) {
|
|
670
676
|
this.logInfo(
|
|
671
|
-
`playlist-window-manager/src/PresentationWindow.ts
|
|
677
|
+
`playlist-window-manager/src/PresentationWindow.ts openChildWindow2: ${JSON.stringify(
|
|
672
678
|
bounds
|
|
673
679
|
)}`
|
|
674
680
|
);
|
|
@@ -699,7 +705,7 @@ export default class PresentationWindow {
|
|
|
699
705
|
}
|
|
700
706
|
} else {
|
|
701
707
|
this.logInfo(
|
|
702
|
-
`playlist-window-manager/src/PresentationWindow.ts
|
|
708
|
+
`playlist-window-manager/src/PresentationWindow.ts openChildWindow3: ${JSON.stringify(
|
|
703
709
|
bounds
|
|
704
710
|
)}`
|
|
705
711
|
);
|