[vlc-devel] commit: QT4 menus : remove previous signal-slot connection(s) if any ( correct trac #2818) (Erwan Tulou )
git version control
git at videolan.org
Fri Jun 5 16:26:43 CEST 2009
vlc | branch: master | Erwan Tulou <brezhoneg1 at yahoo.fr> | Fri Jun 5 09:55:09 2009 +0200| [30e16170c6f1ef56338f80f5bdb53dfbff983383] | committer: Rémi Denis-Courmont
QT4 menus : remove previous signal-slot connection(s) if any (correct trac #2818)
Signed-off-by: Rémi Denis-Courmont <remi at remlab.net>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=30e16170c6f1ef56338f80f5bdb53dfbff983383
---
modules/gui/qt4/menus.cpp | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/modules/gui/qt4/menus.cpp b/modules/gui/qt4/menus.cpp
index 387f5b8..4df26cf 100644
--- a/modules/gui/qt4/menus.cpp
+++ b/modules/gui/qt4/menus.cpp
@@ -1386,6 +1386,10 @@ void QVLCMenu::CreateAndConnect( QMenu *menu, const char *psz_var,
MenuItemData *itemData = new MenuItemData( THEDP->menusMapper, p_obj, i_val_type,
val, psz_var );
+
+ /* remove previous signal-slot connection(s) if any */
+ action->disconnect( );
+
CONNECT( action, triggered(), THEDP->menusMapper, map() );
THEDP->menusMapper->setMapping( action, itemData );
More information about the vlc-devel
mailing list