From: eap Date: Mon, 29 Jul 2013 12:21:40 +0000 (+0000) Subject: 0021941: [CEA 699] Use for Auto Color method on mesh group the same X-Git-Tag: V7_3_0a1~241 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=c979ba741c97173589b9dc3860bd2c049072f392;p=modules%2Fsmesh.git 0021941: [CEA 699] Use for Auto Color method on mesh group the same algorithm that this one in GEOM which define colors (note 15888) In AutoColor(), pass a generated color to a group --- diff --git a/src/SMESHGUI/SMESHGUI.cxx b/src/SMESHGUI/SMESHGUI.cxx index 120e2c803..ee7675db7 100644 --- a/src/SMESHGUI/SMESHGUI.cxx +++ b/src/SMESHGUI/SMESHGUI.cxx @@ -923,7 +923,8 @@ } } - void AutoColor(){ + void AutoColor() + { SALOME_ListIO selected; SalomeApp_Application* app = dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication() ); if( !app ) @@ -946,6 +947,8 @@ if( aMainObject->_is_nil() ) return; + SUIT_OverrideCursor wc; + aMainObject->SetAutoColor( true ); // mesh groups are re-colored here QList aReservedColors; @@ -962,6 +965,7 @@ SALOMEDS::Color aColor = SMESHGUI::getUniqueColor( aReservedColors ); aReservedColors.append( aColor ); #endif // SIMPLE_AUTOCOLOR + aGroupObject->SetColor( aColor ); _PTR(SObject) aGroupSObject = SMESH::FindSObject(aGroupObject); if (aGroupSObject) {