equal
deleted
inserted
replaced
53 #include "playrecordpage.h" |
53 #include "playrecordpage.h" |
54 #include "input_ip.h" |
54 #include "input_ip.h" |
55 #include "ammoSchemeModel.h" |
55 #include "ammoSchemeModel.h" |
56 #include "bgwidget.h" |
56 #include "bgwidget.h" |
57 |
57 |
|
58 #ifdef __APPLE__ |
|
59 #include "CocoaInitializer.h" |
|
60 #include "M3Panel.h" |
58 #ifdef SPARKLE_ENABLED |
61 #ifdef SPARKLE_ENABLED |
59 #include "CocoaInitializer.h" |
|
60 #include "SparkleAutoUpdater.h" |
62 #include "SparkleAutoUpdater.h" |
|
63 #endif |
61 #endif |
64 #endif |
62 |
65 |
63 // I started handing this down to each place it touches, but it was getting ridiculous |
66 // I started handing this down to each place it touches, but it was getting ridiculous |
64 // and this one flag does not warrant a static class |
67 // and this one flag does not warrant a static class |
65 bool frontendEffects = true; |
68 bool frontendEffects = true; |
80 |
83 |
81 config = new GameUIConfig(this, cfgdir->absolutePath() + "/hedgewars.ini"); |
84 config = new GameUIConfig(this, cfgdir->absolutePath() + "/hedgewars.ini"); |
82 |
85 |
83 namegen = new HWNamegen(); |
86 namegen = new HWNamegen(); |
84 |
87 |
|
88 #ifdef __APPLE__ |
|
89 panel = new M3Panel; |
85 #ifdef SPARKLE_ENABLED |
90 #ifdef SPARKLE_ENABLED |
86 AutoUpdater* updater; |
91 AutoUpdater* updater; |
87 CocoaInitializer initializer; |
92 CocoaInitializer initializer; |
88 updater = new SparkleAutoUpdater("http://files.getdropbox.com/u/24468/appcast.xml"); //this has to change before release!!! |
93 updater = new SparkleAutoUpdater("http://files.getdropbox.com/u/24468/appcast.xml"); //this has to change before release!!! |
89 if(updater && config->isAutoUpdateEnabled()) |
94 if(updater && config->isAutoUpdateEnabled()) |
90 updater->checkForUpdates(); |
95 updater->checkForUpdates(); |
|
96 #endif |
91 #endif |
97 #endif |
92 |
98 |
93 UpdateTeamsLists(); |
99 UpdateTeamsLists(); |
94 UpdateWeapons(); |
100 UpdateWeapons(); |
95 |
101 |
425 eggTimer.start(); |
431 eggTimer.start(); |
426 } |
432 } |
427 |
433 |
428 void HWForm::btnExitClicked() |
434 void HWForm::btnExitClicked() |
429 { |
435 { |
430 if (eggTimer.elapsed() < 3000) |
436 if (eggTimer.elapsed() < 3000){ |
|
437 #ifdef __APPLE__ |
|
438 panel->showInstallController(); |
|
439 #endif |
431 close(); |
440 close(); |
432 else |
441 } |
|
442 else |
433 { |
443 { |
434 QPushButton * btn = findChild<QPushButton *>("imageButt"); |
444 QPushButton * btn = findChild<QPushButton *>("imageButt"); |
435 if (btn) |
445 if (btn) |
436 { |
446 { |
437 btn->setIcon(QIcon(":/res/bonus.png")); |
447 btn->setIcon(QIcon(":/res/bonus.png")); |