Skip to content

Commit 3903f36

Browse files
committed
Use wait cursor when loading forms
1 parent b1a2bef commit 3903f36

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/gui/editorwidgets/qgsrelationreferencewidget.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -362,6 +362,7 @@ void QgsRelationReferenceWidget::init()
362362
{
363363
if ( !mReadOnlySelector && mComboBox->count() == 0 && mReferencedLayer )
364364
{
365+
QApplication::setOverrideCursor( Qt::WaitCursor );
365366
if ( mAllowNull )
366367
{
367368
const QString nullValue = QSettings().value( "qgis/nullValue", "NULL" ).toString();
@@ -393,6 +394,7 @@ void QgsRelationReferenceWidget::init()
393394

394395
// Only connect after iterating, to have only one iterator on the referenced table at once
395396
connect( mComboBox, SIGNAL( activated( int ) ), this, SLOT( comboReferenceChanged( int ) ) );
397+
QApplication::restoreOverrideCursor();
396398
}
397399
}
398400

src/gui/qgsattributeform.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,7 @@ void QgsAttributeForm::synchronizeEnabledState()
308308

309309
void QgsAttributeForm::init()
310310
{
311+
QApplication::setOverrideCursor( QCursor( Qt::WaitCursor ) );
311312
QWidget* formWidget = 0;
312313

313314
qDeleteAll( mWidgets );
@@ -458,6 +459,7 @@ void QgsAttributeForm::init()
458459
{
459460
iface->initForm();
460461
}
462+
QApplication::restoreOverrideCursor();
461463
}
462464

463465
void QgsAttributeForm::cleanPython()

0 commit comments

Comments
 (0)