[vlc-devel] commit: win32: Add recent files to jump lists (Geoffroy Couprie )

git version control git at videolan.org
Wed Jun 17 01:00:43 CEST 2009


vlc | branch: 1.0-bugfix | Geoffroy Couprie <geal at videolan.org> | Tue May 19 20:32:15 2009 +0200| [cb1965d62702cbf82a7c85c79f105126e76e3906] | committer: Jean-Baptiste Kempf 

win32: Add recent files to jump lists
(cherry picked from commit 8796e33a5ae150d629c2cfc5451658de134d923f)

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

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

 modules/gui/qt4/recents.cpp |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/modules/gui/qt4/recents.cpp b/modules/gui/qt4/recents.cpp
index 82a20e1..bb6768e 100644
--- a/modules/gui/qt4/recents.cpp
+++ b/modules/gui/qt4/recents.cpp
@@ -33,6 +33,10 @@
 #include <QRegExp>
 #include <QSignalMapper>
 
+#ifdef WIN32
+#include <shlobj.h>
+#endif
+
 RecentsMRL* RecentsMRL::instance = NULL;
 
 RecentsMRL::RecentsMRL( intf_thread_t *_p_intf ) : p_intf( _p_intf )
@@ -66,7 +70,9 @@ void RecentsMRL::addRecent( const QString &mrl )
 {
     if ( !isActive || ( filter && filter->indexIn( mrl ) >= 0 ) )
         return;
-
+#ifdef WIN32
+    SHAddToRecentDocs( 0x00000002 , qtu( mrl ) );
+#endif
     msg_Dbg( p_intf, "Adding a new MRL to recent ones: %s", qtu( mrl ) );
     int i_index = stack->indexOf( mrl );
     if( 0 <= i_index )
@@ -82,6 +88,7 @@ void RecentsMRL::addRecent( const QString &mrl )
     }
     QVLCMenu::updateRecents( p_intf );
     save();
+
 }
 
 void RecentsMRL::clear()




More information about the vlc-devel mailing list