mirror of
https://github.com/kiwix/kiwix-desktop.git
synced 2025-09-24 04:32:15 -04:00
Pass the mainWindow as parent for the fileOpenDialog.
This commit is contained in:
parent
f07b074ab6
commit
6ee087c876
@ -20,6 +20,7 @@ public:
|
|||||||
KiwixSchemeHandler* getSchemeHandler() { return &schemeHandler; }
|
KiwixSchemeHandler* getSchemeHandler() { return &schemeHandler; }
|
||||||
KiwixRequestInterceptor* getRequestInterceptor() { return &requestIntercetor; }
|
KiwixRequestInterceptor* getRequestInterceptor() { return &requestIntercetor; }
|
||||||
Library* getLibrary() { return &library; }
|
Library* getLibrary() { return &library; }
|
||||||
|
MainWindow* getMainWindow() { return mainWindow; }
|
||||||
private:
|
private:
|
||||||
Library library;
|
Library library;
|
||||||
MainWindow* mainWindow;
|
MainWindow* mainWindow;
|
||||||
|
2
main.cpp
2
main.cpp
@ -16,7 +16,7 @@ int main(int argc, char *argv[])
|
|||||||
QString zimfile;
|
QString zimfile;
|
||||||
auto positionalArguments = parser.positionalArguments();
|
auto positionalArguments = parser.positionalArguments();
|
||||||
if (positionalArguments.size() < 1){
|
if (positionalArguments.size() < 1){
|
||||||
zimfile = QFileDialog::getOpenFileName(nullptr,
|
zimfile = QFileDialog::getOpenFileName(a.getMainWindow(),
|
||||||
"Open Zim",
|
"Open Zim",
|
||||||
QString(),
|
QString(),
|
||||||
"ZimFile (*.zim*)");
|
"ZimFile (*.zim*)");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user