summaryrefslogtreecommitdiff
path: root/src/dgedit.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/dgedit.cc')
-rw-r--r--src/dgedit.cc19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/dgedit.cc b/src/dgedit.cc
index 3984f5a..218c73e 100644
--- a/src/dgedit.cc
+++ b/src/dgedit.cc
@@ -30,15 +30,30 @@
#include "settings.h"
#include "localehandler.h"
+extern Q_CORE_EXPORT QBasicAtomicInt qt_qhash_seed;
+
int main(int argc, char *argv[])
{
QApplication app(argc, argv);
+ // Ugly hack to ensure the xml attribute order is the same each time a save
+ // or export is performed.
+ qt_qhash_seed.store(0);
+
LocaleHandler locale(app);
Settings settings;
- MainWindow wnd(settings);
- wnd.show();
+ MainWindow mainwindow(settings);
+ mainwindow.show();
+
+ if(argc > 1)
+ {
+ QFile file(argv[1]);
+ if(file.exists())
+ {
+ mainwindow.loadProject(argv[1]);
+ }
+ }
return app.exec();
}