[vlc-commits] Update bookmark list before showing dialog.

Eugen Geist git at videolan.org
Fri Mar 20 16:01:17 CET 2015


vlc | branch: master | Eugen Geist <eugen.geist at gmail.com> | Thu Mar 19 16:57:05 2015 +0000| [b506e7db2cbd3cf8c7742efc59a6994fd2719477] | committer: Jean-Baptiste Kempf

Update bookmark list before showing dialog.

Fixes #2100.

Override toggleVisible of BookmarkDialog to call update before using toggleVisible of QVLCFrame

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b506e7db2cbd3cf8c7742efc59a6994fd2719477
---

 modules/gui/qt4/dialogs/bookmarks.cpp |   11 +++++++++++
 modules/gui/qt4/dialogs/bookmarks.hpp |    2 ++
 2 files changed, 13 insertions(+)

diff --git a/modules/gui/qt4/dialogs/bookmarks.cpp b/modules/gui/qt4/dialogs/bookmarks.cpp
index 18558db..bfea0eb 100644
--- a/modules/gui/qt4/dialogs/bookmarks.cpp
+++ b/modules/gui/qt4/dialogs/bookmarks.cpp
@@ -278,3 +278,14 @@ void BookmarksDialog::activateItem( QModelIndex index )
 
     input_Control( p_input, INPUT_SET_BOOKMARK, index.row() );
 }
+
+void BookmarksDialog::toggleVisible()
+{
+    /* Update, to show existing bookmarks in case a new playlist
+       was opened */
+    if( !isVisible() )
+    {
+        update();
+    }
+    QVLCFrame::toggleVisible();
+}
diff --git a/modules/gui/qt4/dialogs/bookmarks.hpp b/modules/gui/qt4/dialogs/bookmarks.hpp
index ad81bc2..17c7bde 100644
--- a/modules/gui/qt4/dialogs/bookmarks.hpp
+++ b/modules/gui/qt4/dialogs/bookmarks.hpp
@@ -35,6 +35,8 @@ class QPushButton;
 class BookmarksDialog : public QVLCFrame, public Singleton<BookmarksDialog>
 {
     Q_OBJECT
+public:
+    void toggleVisible();
 private:
     BookmarksDialog( intf_thread_t * );
     virtual ~BookmarksDialog();



More information about the vlc-commits mailing list