[vlc-commits] [Git][videolan/vlc][master] qml/VideoAll(s): Fix keyboard navigation when VideoDisplayRecentVideos is empty

Hugo Beauzée-Luyssen (@chouquette) gitlab at videolan.org
Fri Feb 4 08:57:50 UTC 2022



Hugo Beauzée-Luyssen pushed to branch master at VideoLAN / VLC


Commits:
0febdd3f by Benjamin Arnaud at 2022-02-04T08:29:58+00:00
qml/VideoAll(s): Fix keyboard navigation when VideoDisplayRecentVideos is empty

- - - - -


2 changed files:

- modules/gui/qt/medialibrary/qml/VideoAll.qml
- modules/gui/qt/medialibrary/qml/VideoAllSubDisplay.qml


Changes:

=====================================
modules/gui/qt/medialibrary/qml/VideoAll.qml
=====================================
@@ -140,7 +140,9 @@ FocusScope {
 
     function _onNavigationUp() {
         // NOTE: We are calling the header focus function when we have one.
-        if (headerItem && (typeof headerItem.setCurrentItemFocus === "function"))
+        if (headerItem && headerItem.visible
+            &&
+            (typeof headerItem.setCurrentItemFocus === "function"))
             headerItem.setCurrentItemFocus(Qt.TabFocusReason)
         else
             Navigation.defaultNavigationUp()


=====================================
modules/gui/qt/medialibrary/qml/VideoAllSubDisplay.qml
=====================================
@@ -174,7 +174,7 @@ VideoAll {
 
         // NOTE: We want the header to be visible when we have at least one media visible.
         //       Otherwise it overlaps the default caption.
-        visible: (root.model.count)
+        visible: (root.model.count && modelRecent.count)
 
         function setCurrentItemFocus(reason) {
             var item = loader.item;



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/0febdd3f363055a327ba824d95bedf394a952025

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/0febdd3f363055a327ba824d95bedf394a952025
You're receiving this email because of your account on code.videolan.org.




More information about the vlc-commits mailing list