back ported some qt6 recent file handling.
This commit is contained in:
@ -1558,7 +1558,7 @@ void PTextEdit::fileClose(const bool check)
|
||||
int result = QMessageBox::warning(this, "**WARNING**",
|
||||
"Do you really want to close this file.\nChanges will be lost",
|
||||
"Close", "Cancel");
|
||||
if (result == 1) // Cancel
|
||||
if (result == QMessageBox::Cancel) // Cancel
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1588,7 +1588,7 @@ void PTextEdit::fileCloseAll()
|
||||
int result = QMessageBox::warning(this, "**WARNING**",
|
||||
"Do you really want to close all files.\nChanges of unsaved files will be lost",
|
||||
"Close", "Cancel");
|
||||
if (result == 1) // Cancel
|
||||
if (result == QMessageBox::Cancel) // Cancel
|
||||
return;
|
||||
break;
|
||||
}
|
||||
@ -1625,7 +1625,7 @@ void PTextEdit::fileCloseAllOthers()
|
||||
int result = QMessageBox::warning(this, "**WARNING**",
|
||||
"Do you really want to close all files.\nChanges of unsaved files will be lost",
|
||||
"Close", "Cancel");
|
||||
if (result == 1) // Cancel
|
||||
if (result == QMessageBox::Cancel) // Cancel
|
||||
return;
|
||||
break;
|
||||
}
|
||||
@ -1668,12 +1668,14 @@ void PTextEdit::fileExit()
|
||||
int result = QMessageBox::warning(this, "**WARNING**",
|
||||
"Do you really want to exit from the applcation.\nChanges will be lost",
|
||||
"Exit", "Cancel");
|
||||
if (result == 1) // Cancel
|
||||
if (result == QMessageBox::Cancel) // Cancel
|
||||
return;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
fAdmin->saveRecentFiles();
|
||||
|
||||
qApp->quit();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user