]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Fix a bug: disable adding of the action to the same toolbar several times
authorvsr <vsr@opencascade.com>
Fri, 14 Apr 2006 13:56:41 +0000 (13:56 +0000)
committervsr <vsr@opencascade.com>
Fri, 14 Apr 2006 13:56:41 +0000 (13:56 +0000)
src/Qtx/QtxActionToolMgr.cxx

index b9ff56c8f74e9e2fbdb9c4d9c579e19a5d37eef6..0856fa560ea04edc2c7719cb92f04d4c71f2f4ce 100644 (file)
@@ -115,6 +115,9 @@ int QtxActionToolMgr::insert( const int id, const int tid, const int idx )
   if ( !contains( id ) || !hasToolBar( tid ) )
     return -1;
 
+  if ( containsAction( id, tid ) )
+    remove( id, tid );
+
   ToolNode node;
   node.id = id;