Skip to content

Commit b0084e5

Browse files

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed
 

‎src/core/qgshttptransaction.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,17 +138,20 @@ bool QgsHttpTransaction::getSynchronously(QByteArray &respondedContent, int redi
138138
QgsDebugMsg("QgsHttpTransaction::getSynchronously: Starting get with id " + QString::number(httpid) + ".");
139139
QgsDebugMsg("QgsHttpTransaction::getSynchronously: Setting httpactive = TRUE");
140140

141+
// let the user know we're going to possibly be taking a while
142+
QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
143+
141144
httpactive = TRUE;
142145

143146
// A little trick to make this function blocking
144147
while ( httpactive )
145148
{
146149
// Do something else, maybe even network processing events
147-
qApp->processEvents();
148-
149-
// TODO: Implement a network timeout
150+
qApp->processEvents(QEventLoop::ExcludeUserInputEvents);
150151
}
151152

153+
QApplication::restoreOverrideCursor();
154+
152155
#ifdef QGISDEBUG
153156
QgsDebugMsg("QgsHttpTransaction::getSynchronously: Response received.");
154157

0 commit comments

Comments
 (0)
Please sign in to comment.