@microsoft/live-share-media 1.0.0-preview.1 → 1.0.0-preview.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.
- package/README.md +1 -1
- package/bin/IMediaPlayer.d.ts.map +1 -1
- package/bin/LiveMediaSession.d.ts +7 -7
- package/bin/LiveMediaSession.d.ts.map +1 -1
- package/bin/LiveMediaSession.js +28 -17
- package/bin/LiveMediaSession.js.map +1 -1
- package/bin/LiveMediaSessionCoordinator.d.ts +2 -2
- package/bin/LiveMediaSessionCoordinator.d.ts.map +1 -1
- package/bin/LiveMediaSessionCoordinator.js +34 -22
- package/bin/LiveMediaSessionCoordinator.js.map +1 -1
- package/bin/LiveMediaSessionCoordinatorSuspension.d.ts +1 -1
- package/bin/LiveMediaSessionCoordinatorSuspension.d.ts.map +1 -1
- package/bin/LiveMediaSessionCoordinatorSuspension.js.map +1 -1
- package/bin/MediaPlayerSynchronizer.d.ts +7 -7
- package/bin/MediaPlayerSynchronizer.d.ts.map +1 -1
- package/bin/MediaPlayerSynchronizer.js +121 -69
- package/bin/MediaPlayerSynchronizer.js.map +1 -1
- package/bin/MediaSessionActionThrottler.d.ts +1 -1
- package/bin/MediaSessionActionThrottler.d.ts.map +1 -1
- package/bin/MediaSessionActionThrottler.js.map +1 -1
- package/bin/MediaSessionExtensions.d.ts.map +1 -1
- package/bin/RepeatedActionThrottler.d.ts +2 -2
- package/bin/RepeatedActionThrottler.d.ts.map +1 -1
- package/bin/RepeatedActionThrottler.js +9 -3
- package/bin/RepeatedActionThrottler.js.map +1 -1
- package/bin/VolumeManager.d.ts +1 -1
- package/bin/VolumeManager.d.ts.map +1 -1
- package/bin/VolumeManager.js +4 -2
- package/bin/VolumeManager.js.map +1 -1
- package/bin/index.d.ts +9 -9
- package/bin/index.d.ts.map +1 -1
- package/bin/index.js.map +1 -1
- package/bin/internals/GroupCoordinatorState.d.ts +8 -8
- package/bin/internals/GroupCoordinatorState.d.ts.map +1 -1
- package/bin/internals/GroupCoordinatorState.js +91 -53
- package/bin/internals/GroupCoordinatorState.js.map +1 -1
- package/bin/internals/GroupPlaybackPosition.d.ts +3 -3
- package/bin/internals/GroupPlaybackPosition.d.ts.map +1 -1
- package/bin/internals/GroupPlaybackPosition.js +22 -13
- package/bin/internals/GroupPlaybackPosition.js.map +1 -1
- package/bin/internals/GroupPlaybackTrack.d.ts +4 -4
- package/bin/internals/GroupPlaybackTrack.d.ts.map +1 -1
- package/bin/internals/GroupPlaybackTrack.js +14 -4
- package/bin/internals/GroupPlaybackTrack.js.map +1 -1
- package/bin/internals/GroupPlaybackTrackData.d.ts +3 -3
- package/bin/internals/GroupPlaybackTrackData.d.ts.map +1 -1
- package/bin/internals/GroupPlaybackTrackData.js +8 -4
- package/bin/internals/GroupPlaybackTrackData.js.map +1 -1
- package/bin/internals/GroupTransportState.d.ts +5 -5
- package/bin/internals/GroupTransportState.d.ts.map +1 -1
- package/bin/internals/GroupTransportState.js +27 -12
- package/bin/internals/GroupTransportState.js.map +1 -1
- package/bin/internals/consts.d.ts.map +1 -1
- package/bin/internals/consts.js +54 -54
- package/bin/internals/consts.js.map +1 -1
- package/bin/internals/index.d.ts +6 -6
- package/package.json +3 -3
- package/src/IMediaPlayer.ts +10 -2
- package/src/LiveMediaSession.ts +133 -71
- package/src/LiveMediaSessionCoordinator.ts +302 -142
- package/src/LiveMediaSessionCoordinatorSuspension.ts +13 -5
- package/src/MediaPlayerSynchronizer.ts +317 -146
- package/src/MediaSessionActionThrottler.ts +5 -3
- package/src/MediaSessionExtensions.ts +15 -5
- package/src/RepeatedActionThrottler.ts +27 -9
- package/src/VolumeManager.ts +24 -12
- package/src/index.ts +9 -10
- package/src/internals/GroupCoordinatorState.ts +274 -114
- package/src/internals/GroupPlaybackPosition.ts +61 -27
- package/src/internals/GroupPlaybackTrack.ts +51 -22
- package/src/internals/GroupPlaybackTrackData.ts +24 -16
- package/src/internals/GroupTransportState.ts +53 -23
- package/src/internals/consts.ts +73 -55
- package/src/internals/index.ts +6 -6
- package/src/test/GroupPlaybackPosition.spec.ts +371 -111
- package/src/test/GroupPlaybackTrack.spec.ts +91 -35
- package/src/test/SharedMediaSession.spec.ts +64 -28
- package/src/test/SharedMediaSessionCoordinator.spec.ts +86 -46
- package/src/test/VolumeManager.spec.ts +38 -31
- package/tsconfig.json +1 -0
- package/bin/EphemeralMediaSession.d.ts +0 -102
- package/bin/EphemeralMediaSession.d.ts.map +0 -1
- package/bin/EphemeralMediaSession.js +0 -226
- package/bin/EphemeralMediaSession.js.map +0 -1
- package/bin/EphemeralMediaSessionCoordinator.d.ts +0 -228
- package/bin/EphemeralMediaSessionCoordinator.d.ts.map +0 -1
- package/bin/EphemeralMediaSessionCoordinator.js +0 -396
- package/bin/EphemeralMediaSessionCoordinator.js.map +0 -1
- package/bin/EphemeralMediaSessionCoordinatorSuspension.d.ts +0 -20
- package/bin/EphemeralMediaSessionCoordinatorSuspension.d.ts.map +0 -1
- package/bin/EphemeralMediaSessionCoordinatorSuspension.js +0 -28
- package/bin/EphemeralMediaSessionCoordinatorSuspension.js.map +0 -1
- package/bin/VolumeLimiter.d.ts +0 -70
- package/bin/VolumeLimiter.d.ts.map +0 -1
- package/bin/VolumeLimiter.js +0 -170
- package/bin/VolumeLimiter.js.map +0 -1
package/src/internals/consts.ts
CHANGED
|
@@ -10,67 +10,85 @@
|
|
|
10
10
|
*/
|
|
11
11
|
export const TelemetryEvents = {
|
|
12
12
|
MediaPlayerSynchronizer: {
|
|
13
|
-
SynchronizationStarted:
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
13
|
+
SynchronizationStarted:
|
|
14
|
+
"MediaPlayerSynchronizer:SynchronizationStarted",
|
|
15
|
+
PlayerEvent: "MediaPlayerSynchronizer:PlayerEvent",
|
|
16
|
+
PlayAction: "MediaPlayerSynchronizer:PlayAction",
|
|
17
|
+
PauseAction: "MediaPlayerSynchronizer:PauseAction",
|
|
18
|
+
SeekToAction: "MediaPlayerSynchronizer:SeekToAction",
|
|
19
|
+
CatchupAction: "MediaPlayerSynchronizer:CatchupAction",
|
|
20
|
+
SetTrackAction: "MediaPlayerSynchronizer:SetTrackAction",
|
|
21
|
+
DataChangeAction: "MediaPlayerSynchronizer:DataChangeAction",
|
|
22
|
+
UserTappedVideoToPlay: transmit(
|
|
23
|
+
"MediaPlayerSynchronizer:UserTappedVideoToPlay"
|
|
24
|
+
),
|
|
25
|
+
PlaybackRateChangeBlocked:
|
|
26
|
+
"MediaPlayerSynchronizer:PlaybackRateChangeBlocked",
|
|
27
|
+
PlayerBlockedOperation: transmit(
|
|
28
|
+
"MediaPlayerSynchronizer:PlayerBlockedOperation"
|
|
29
|
+
),
|
|
30
|
+
SeekingPlayerToStartPosition:
|
|
31
|
+
"MediaPlayerSynchronizer:SeekingPlayerToStartPosition",
|
|
32
|
+
BeginSeekCalled: "MediaPlayerSynchronizer:BeginSeekCalled",
|
|
33
|
+
EndSeekCalled: "MediaPlayerSynchronizer:EndSeekCalled",
|
|
34
|
+
PlayCalled: "MediaPlayerSynchronizer:PlayCalled",
|
|
35
|
+
PauseCalled: "MediaPlayerSynchronizer:PauseCalled",
|
|
36
|
+
SeekToCalled: "MediaPlayerSynchronizer:SeekToCalled",
|
|
37
|
+
SetTrackCalled: "MediaPlayerSynchronizer:SetTrackCalled",
|
|
38
|
+
SetTrackDataCalled: "MediaPlayerSynchronizer:SetTrackDataCalled",
|
|
32
39
|
},
|
|
33
40
|
MediaSession: {
|
|
34
|
-
PlayAction: transmit(
|
|
35
|
-
PauseAction: transmit(
|
|
36
|
-
SeekToAction: transmit(
|
|
37
|
-
CatchUpAction: transmit(
|
|
38
|
-
SetTrackAction: transmit(
|
|
39
|
-
DataChangeAction:
|
|
40
|
-
BeginPositionUpdateTimer:
|
|
41
|
+
PlayAction: transmit("MediaSession:PlayAction"),
|
|
42
|
+
PauseAction: transmit("MediaSession:PauseAction"),
|
|
43
|
+
SeekToAction: transmit("MediaSession:SeekToAction"),
|
|
44
|
+
CatchUpAction: transmit("MediaSession:CatchUpAction"),
|
|
45
|
+
SetTrackAction: transmit("MediaSession:SetTrackAction"),
|
|
46
|
+
DataChangeAction: "MediaSession:DataChangeAction",
|
|
47
|
+
BeginPositionUpdateTimer: "MediaSession:BeginPositionUpdateTimer",
|
|
41
48
|
},
|
|
42
49
|
SessionCoordinator: {
|
|
43
|
-
PlayCalled: transmit(
|
|
44
|
-
PauseCalled: transmit(
|
|
45
|
-
SeekToCalled: transmit(
|
|
46
|
-
SetTrackCalled: transmit(
|
|
47
|
-
SetTrackDataCalled:
|
|
48
|
-
BeginSuspension:
|
|
49
|
-
BeginSuspensionAndWait: transmit(
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
50
|
+
PlayCalled: transmit("SessionCoordinator:PlayCalled"),
|
|
51
|
+
PauseCalled: transmit("SessionCoordinator:PauseCalled"),
|
|
52
|
+
SeekToCalled: transmit("SessionCoordinator:SeekToCalled"),
|
|
53
|
+
SetTrackCalled: transmit("SessionCoordinator:SetTrackCalled"),
|
|
54
|
+
SetTrackDataCalled: "SessionCoordinator:SetTrackDataCalled",
|
|
55
|
+
BeginSuspension: "SessionCoordinator:BeginSuspension",
|
|
56
|
+
BeginSuspensionAndWait: transmit(
|
|
57
|
+
"SessionCoordinator:BeginSuspensionAndWait"
|
|
58
|
+
),
|
|
59
|
+
EndSuspension: "SessionCoordinator:EndSuspension",
|
|
60
|
+
EndSuspensionAndWait: transmit(
|
|
61
|
+
"SessionCoordinator:EndSuspensionAndWait"
|
|
62
|
+
),
|
|
63
|
+
RemoteJoinReceived: "SessionCoordinator:RemoteJoinReceived",
|
|
64
|
+
RemoteSetTrackReceived: transmit(
|
|
65
|
+
"SessionCoordinator:RemoteSetTrackReceived"
|
|
66
|
+
),
|
|
67
|
+
RemoteSetTrackDataReceived: transmit(
|
|
68
|
+
"SessionCoordinator:RemoteSetTrackDataReceived"
|
|
69
|
+
),
|
|
70
|
+
RemotePlayReceived: transmit("SessionCoordinator:RemotePlayReceived"),
|
|
71
|
+
RemotePauseReceived: transmit("SessionCoordinator:RemotePauseReceived"),
|
|
72
|
+
RemoteSeekToReceived: transmit(
|
|
73
|
+
"SessionCoordinator:RemoteSeekToReceived"
|
|
74
|
+
),
|
|
58
75
|
},
|
|
59
76
|
GroupCoordinator: {
|
|
60
|
-
TrackChanged:
|
|
61
|
-
TrackChangeDelayed:
|
|
62
|
-
TrackDataChanged:
|
|
63
|
-
TrackDataChangeDelayed:
|
|
64
|
-
TransportStateChanged:
|
|
65
|
-
TransportStateChangeDelayed:
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
77
|
+
TrackChanged: "GroupCoordinator:TrackChanged",
|
|
78
|
+
TrackChangeDelayed: "GroupCoordinator:TrackChangeDelayed",
|
|
79
|
+
TrackDataChanged: "GroupCoordinator:TrackDataChanged",
|
|
80
|
+
TrackDataChangeDelayed: "GroupCoordinator:TrackDataChangeDelayed",
|
|
81
|
+
TransportStateChanged: "GroupCoordinator:TransportStateChanged",
|
|
82
|
+
TransportStateChangeDelayed:
|
|
83
|
+
"GroupCoordinator:TransportStateChangeDelayed",
|
|
84
|
+
BeginSoftSuspension: "GroupCoordinator:BeginSoftSuspension",
|
|
85
|
+
CheckingForSyncIssues: "GroupCoordinator:CheckingForSyncIssues",
|
|
86
|
+
TrackOutOfSync: transmit("GroupCoordinator:TrackOutOfSync"),
|
|
87
|
+
TrackDataOutOfSync: transmit("GroupCoordinator:TrackDataOutOfSync"),
|
|
88
|
+
TransportOutOfSync: transmit("GroupCoordinator:TransportOutOfSync"),
|
|
89
|
+
PositionOutOfSync: transmit("GroupCoordinator:PositionOutOfSync"),
|
|
90
|
+
},
|
|
91
|
+
};
|
|
74
92
|
|
|
75
93
|
/**
|
|
76
94
|
* @hidden
|
package/src/internals/index.ts
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* Licensed under the Microsoft Live Share SDK License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
export * from
|
|
7
|
-
export * from
|
|
8
|
-
export * from
|
|
9
|
-
export * from
|
|
10
|
-
export * from
|
|
11
|
-
export * from
|
|
6
|
+
export * from "./consts";
|
|
7
|
+
export * from "./GroupCoordinatorState";
|
|
8
|
+
export * from "./GroupPlaybackPosition";
|
|
9
|
+
export * from "./GroupPlaybackTrack";
|
|
10
|
+
export * from "./GroupPlaybackTrackData";
|
|
11
|
+
export * from "./GroupTransportState";
|