#include "SalomeApp_SelectionMgr.h"
#include "SalomeApp_Study.h"
#include "SalomeApp_Tools.h"
+
#include "SUIT_Session.h"
#include "SUIT_MessageBox.h"
+#include "SUIT_OverrideCursor.h"
#include "SALOME_ListIteratorOfListIO.hxx"
try {
if ( ( !publish && !useTransaction ) || openCommand() ) {
- QApplication::setOverrideCursor( Qt::waitCursor );
+
+ SUIT_OverrideCursor wc;
+
SUIT_Session::session()->activeApplication()->putInfo( "" );
ObjectList objects;
// JFA 28.12.2004 if ( !execute( objects ) || !getOperation()->IsDone() ) {
if ( !execute( objects ) ) { // JFA 28.12.2004 // To enable warnings
- while( QApplication::overrideCursor() )
- QApplication::restoreOverrideCursor();
- abortCommand();
+ wc.suspend();
+ abortCommand();
showError();
}
else {
// JFA 28.12.2004 BEGIN // To enable warnings
if ( !getOperation()->_is_nil() ) {
if ( !getOperation()->IsDone() ) {
- while( QApplication::overrideCursor() )
- QApplication::restoreOverrideCursor();
- QString msgw = QObject::tr( getOperation()->GetErrorCode() );
+ wc.suspend();
+ QString msgw = QObject::tr( getOperation()->GetErrorCode() );
SUIT_MessageBox::warn1((QWidget*)(SUIT_Session::session()->activeApplication()->desktop()),
QObject::tr( "WRN_WARNING" ),
msgw,