[vlc-commits] qml: stop media when leaving the player view if the media is paused
    Pierre Lamot 
    git at videolan.org
       
    Mon Oct 14 11:59:38 CEST 2019
    
    
  
vlc | branch: master | Pierre Lamot <pierre at videolabs.io> | Wed Sep 25 18:31:21 2019 +0200| [3b3e9c6f944796b1d934c4831be8ebc54b592594] | committer: Jean-Baptiste Kempf
qml: stop media when leaving the player view if the media is paused
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3b3e9c6f944796b1d934c4831be8ebc54b592594
---
 modules/gui/qt/qml/player/TopBar.qml | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/modules/gui/qt/qml/player/TopBar.qml b/modules/gui/qt/qml/player/TopBar.qml
index a519095309..39d061574c 100644
--- a/modules/gui/qt/qml/player/TopBar.qml
+++ b/modules/gui/qt/qml/player/TopBar.qml
@@ -66,7 +66,12 @@ Utils.NavigableFocusScope{
                     size: VLCStyle.icon_normal
                     text: VLCIcons.exit
                     color: VLCStyle.colors.playerFg
-                    onClicked: history.previous(History.Go)
+                    onClicked: {
+                        if (player.playingState === PlayerController.PLAYING_STATE_PAUSED) {
+                           mainPlaylistController.stop()
+                        }
+                        history.previous(History.Go)
+                    }
                     KeyNavigation.right: playlistBtn
                     focus: true
                 }
    
    
More information about the vlc-commits
mailing list