Changeset 244c614c6b in tspsg for src/mainwindow.cpp
- Timestamp:
- Aug 30, 2009, 11:02:07 PM (15 years ago)
- Branches:
- 0.1.3.145-beta1-symbian, 0.1.4.170-beta2-bb10, appveyor, imgbot, master, readme
- Children:
- 9cf98b9bd6
- Parents:
- 5a81a64d74
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mainwindow.cpp
r5a81a64d74 r244c614c6b 242 242 if (files.empty()) 243 243 return; 244 QApplication::setOverrideCursor(QCursor(Qt::WaitCursor)); 245 if (!tspmodel->loadTask(files.first())) { 246 QApplication::restoreOverrideCursor(); 247 return; 248 } 244 if (!tspmodel->loadTask(files.first())) 245 return; 249 246 setFileName(files.first()); 250 247 tabWidget->setCurrentIndex(0); … … 252 249 solutionText->clear(); 253 250 enableSolutionActions(false); 254 QApplication::restoreOverrideCursor();255 251 } 256 252 … … 259 255 if ((fileName == trUtf8("Untitled") + ".tspt") || (!fileName.endsWith(".tspt",Qt::CaseInsensitive))) 260 256 saveTask(); 261 else { 262 QApplication::setOverrideCursor(QCursor(Qt::WaitCursor)); 257 else 263 258 if (tspmodel->saveTask(fileName)) 264 259 setWindowModified(false); 265 QApplication::restoreOverrideCursor();266 }267 260 } 268 261 … … 347 340 if (files.empty()) 348 341 return false; 349 QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));350 342 if (tspmodel->saveTask(files.first())) { 351 343 setFileName(files.first()); 352 344 setWindowModified(false); 353 QApplication::restoreOverrideCursor();354 345 return true; 355 346 } 356 QApplication::restoreOverrideCursor();357 347 return false; 358 348 }
Note: See TracChangeset
for help on using the changeset viewer.