diff options
| author | Claus Vium <cvium@users.noreply.github.com> | 2020-12-11 09:57:14 +0100 |
|---|---|---|
| committer | Joshua M. Boniface <joshua@boniface.me> | 2020-12-13 20:34:32 -0500 |
| commit | e70a6d41f48b964a82f325244b57aaf86a51af85 (patch) | |
| tree | 674224e539e542c0659004a1c004361d1be62add /Emby.Server.Implementations/Session/SessionManager.cs | |
| parent | 9d4417eee300f3aaceead992c996cf2f58fc0a0d (diff) | |
Merge pull request #4710 from OancaAndrei/syncplay-fix-session-restore
Restore sessions in SyncPlay groups upon reconnection
(cherry picked from commit a57e465de9c34c15fb6981b752bb5ad4121a2ab5)
Signed-off-by: Joshua M. Boniface <joshua@boniface.me>
Diffstat (limited to 'Emby.Server.Implementations/Session/SessionManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Session/SessionManager.cs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Emby.Server.Implementations/Session/SessionManager.cs b/Emby.Server.Implementations/Session/SessionManager.cs index b3965fcca..885f65c64 100644 --- a/Emby.Server.Implementations/Session/SessionManager.cs +++ b/Emby.Server.Implementations/Session/SessionManager.cs @@ -128,6 +128,9 @@ namespace Emby.Server.Implementations.Session /// <inheritdoc /> public event EventHandler<SessionEventArgs> SessionActivity; + /// <inheritdoc /> + public event EventHandler<SessionEventArgs> SessionControllerConnected; + /// <summary> /// Gets all connections. /// </summary> @@ -313,6 +316,19 @@ namespace Emby.Server.Implementations.Session } /// <inheritdoc /> + public void OnSessionControllerConnected(SessionInfo info) + { + EventHelper.QueueEventIfNotNull( + SessionControllerConnected, + this, + new SessionEventArgs + { + SessionInfo = info + }, + _logger); + } + + /// <inheritdoc /> public void CloseIfNeeded(SessionInfo session) { if (!session.SessionControllers.Any(i => i.IsSessionActive)) |
