From 07d8f0ef39f428cb3c23dedc290520d51e7788b0 Mon Sep 17 00:00:00 2001 From: ouv Date: Wed, 4 May 2011 10:45:10 +0000 Subject: [PATCH] Bug IPAL22462: TC6.3.0: run button is disabled after creation of animated series --- src/LightApp/LightApp_Application.cxx | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/src/LightApp/LightApp_Application.cxx b/src/LightApp/LightApp_Application.cxx index cf22f0702..03c32471b 100644 --- a/src/LightApp/LightApp_Application.cxx +++ b/src/LightApp/LightApp_Application.cxx @@ -3619,10 +3619,26 @@ QString LightApp_Application::browseObjects( const QStringList& theEntryList, // always select the last object if( anObject && !anEntry.isEmpty() ) { - SUIT_DataOwnerPtrList aList; - aList.append( new LightApp_DataOwner( anEntry ) ); - selectionMgr()->setSelected( aList ); - aResult = anEntry; + QList aSelectorList; + selectionMgr()->selectors( "ObjectBrowser", aSelectorList ); + if( !aSelectorList.isEmpty() ) + { + if( LightApp_OBSelector* aSelector = dynamic_cast( aSelectorList.first() ) ) + { + bool anIsAutoBlock = aSelector->autoBlock(); + + // temporarily disable auto block, to emit LightApp_SelectionMgr::currentSelectionChanged() signal + aSelector->setAutoBlock( false ); + + SUIT_DataOwnerPtrList aList; + aList.append( new LightApp_DataOwner( anEntry ) ); + selectionMgr()->setSelected( aList ); + aResult = anEntry; + + // restore auto block flag + aSelector->setAutoBlock( anIsAutoBlock ); + } + } } return aResult; -- 2.39.2