Fix story viewer after attach choose dialog.
This commit is contained in:
parent
75f542747d
commit
150957abcd
|
@ -371,6 +371,9 @@ bool GetDefault(
|
||||||
? parent->window()
|
? parent->window()
|
||||||
: Core::App().getFileDialogParent();
|
: Core::App().getFileDialogParent();
|
||||||
Core::App().notifyFileDialogShown(true);
|
Core::App().notifyFileDialogShown(true);
|
||||||
|
const auto guard = gsl::finally([] {
|
||||||
|
Core::App().notifyFileDialogShown(false);
|
||||||
|
});
|
||||||
if (type == Type::ReadFiles) {
|
if (type == Type::ReadFiles) {
|
||||||
files = QFileDialog::getOpenFileNames(resolvedParent, caption, startFile, filter);
|
files = QFileDialog::getOpenFileNames(resolvedParent, caption, startFile, filter);
|
||||||
QString path = files.isEmpty() ? QString() : QFileInfo(files.back()).absoluteDir().absolutePath();
|
QString path = files.isEmpty() ? QString() : QFileInfo(files.back()).absoluteDir().absolutePath();
|
||||||
|
@ -386,7 +389,6 @@ bool GetDefault(
|
||||||
} else {
|
} else {
|
||||||
file = QFileDialog::getOpenFileName(resolvedParent, caption, startFile, filter);
|
file = QFileDialog::getOpenFileName(resolvedParent, caption, startFile, filter);
|
||||||
}
|
}
|
||||||
Core::App().notifyFileDialogShown(false);
|
|
||||||
|
|
||||||
if (file.isEmpty()) {
|
if (file.isEmpty()) {
|
||||||
files = QStringList();
|
files = QStringList();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user