diff options
Diffstat (limited to 'src/media-player-list-greeter.vala')
-rw-r--r-- | src/media-player-list-greeter.vala | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/media-player-list-greeter.vala b/src/media-player-list-greeter.vala index 101211d..541fe3e 100644 --- a/src/media-player-list-greeter.vala +++ b/src/media-player-list-greeter.vala @@ -73,15 +73,7 @@ public class MediaPlayerListGreeter : MediaPlayerList { } if (selected_user != null && !players.contains(selected_user)) { - var newplayer = new MediaPlayerUser(selected_user); - newplayer.notify["is-running"].connect((obj, prop) => { - MediaPlayerUser? player = obj as MediaPlayerUser; - if (player == null) return; - if (player.is_running && player.id == this.selected_user) - this.player_added(player); - }); - - players.insert(selected_user, newplayer); + players.insert(selected_user, new MediaPlayerUser(selected_user)); } if (old_user != null) { @@ -92,7 +84,7 @@ public class MediaPlayerListGreeter : MediaPlayerList { if (selected_user != null) { var new_player = players.lookup(selected_user); - if (new_player.is_running) + if (new_player != null) player_added(new_player); } } |