From: vsr Date: Fri, 14 Apr 2006 13:56:41 +0000 (+0000) Subject: Fix a bug: disable adding of the action to the same toolbar several times X-Git-Tag: T3_2_0b1_pre1~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d7b3ec3cf625651eebb9684bfca9d4cf28261afe;p=modules%2Fgui.git Fix a bug: disable adding of the action to the same toolbar several times --- diff --git a/src/Qtx/QtxActionToolMgr.cxx b/src/Qtx/QtxActionToolMgr.cxx index b9ff56c8f..0856fa560 100644 --- a/src/Qtx/QtxActionToolMgr.cxx +++ b/src/Qtx/QtxActionToolMgr.cxx @@ -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;