From c4bd38dbdce947858d758d1e694ff19d9bddbaa0 Mon Sep 17 00:00:00 2001 From: a b Date: Tue, 27 Sep 2011 22:33:45 +0200 Subject: [PATCH] Mac fixes --- cockatrice/cockatrice.pro | 4 ++-- cockatrice/src/carddatabase.cpp | 4 ++-- cockatrice/src/main.cpp | 11 +++++++---- cockatrice/src/window_deckeditor.cpp | 2 +- oracle/oracle.pro | 3 ++- 5 files changed, 14 insertions(+), 10 deletions(-) diff --git a/cockatrice/cockatrice.pro b/cockatrice/cockatrice.pro index 6fce170b..5b60054a 100644 --- a/cockatrice/cockatrice.pro +++ b/cockatrice/cockatrice.pro @@ -1,5 +1,5 @@ TEMPLATE = app -TARGET = +TARGET = cockatrice DEPENDPATH += . src ../common INCLUDEPATH += . src ../common MOC_DIR = build @@ -202,6 +202,6 @@ win32 { } macx { ICON = resources/appicon.icns - CONFIG += x86 ppc + CONFIG += x86_64 release LIBS += -bind_at_load } diff --git a/cockatrice/src/carddatabase.cpp b/cockatrice/src/carddatabase.cpp index 1ba308b6..9d628a40 100644 --- a/cockatrice/src/carddatabase.cpp +++ b/cockatrice/src/carddatabase.cpp @@ -238,7 +238,7 @@ void PictureLoadingThread::run() pictureLoader->setPicsPath(picsPath); pictureLoader->setPicDownload(picDownload); - usleep(100); + usleep(10000); initWaitCondition.wakeAll(); exec(); @@ -715,4 +715,4 @@ void CardDatabase::picsPathChanged() { loadingThread->getPictureLoader()->setPicsPath(settingsCache->getPicsPath()); clearPixmapCache(); -} \ No newline at end of file +} diff --git a/cockatrice/src/main.cpp b/cockatrice/src/main.cpp index 8ce2581b..e59e18df 100644 --- a/cockatrice/src/main.cpp +++ b/cockatrice/src/main.cpp @@ -73,11 +73,11 @@ int main(int argc, char *argv[]) #ifdef Q_OS_MAC QDir baseDir(app.applicationDirPath()); baseDir.cdUp(); + baseDir.cdUp(); + baseDir.cdUp(); QDir pluginsDir = baseDir; pluginsDir.cd("PlugIns"); app.addLibraryPath(pluginsDir.absolutePath()); - baseDir.cdUp(); - baseDir.cdUp(); #endif #ifdef Q_OS_WIN app.addLibraryPath(app.applicationDirPath() + "/plugins"); @@ -116,8 +116,10 @@ int main(int argc, char *argv[]) } if (startMainProgram) { + qDebug("main(): starting main program"); soundEngine = new SoundEngine; - + qDebug("main(): SoundEngine constructor finished"); + MainWindow ui; qDebug("main(): MainWindow constructor finished"); @@ -129,7 +131,8 @@ int main(int argc, char *argv[]) app.exec(); } - + + qDebug("Event loop finished, terminating..."); delete db; delete settingsCache; delete rng; diff --git a/cockatrice/src/window_deckeditor.cpp b/cockatrice/src/window_deckeditor.cpp index 0355a62e..5387e4c5 100644 --- a/cockatrice/src/window_deckeditor.cpp +++ b/cockatrice/src/window_deckeditor.cpp @@ -395,7 +395,7 @@ void WndDeckEditor::actPrintDeck() void WndDeckEditor::actEditSets() { - WndSets *w = new WndSets(this); + WndSets *w = new WndSets; w->setWindowModality(Qt::WindowModal); w->show(); } diff --git a/oracle/oracle.pro b/oracle/oracle.pro index b42fd347..652af19f 100644 --- a/oracle/oracle.pro +++ b/oracle/oracle.pro @@ -10,6 +10,7 @@ HEADERS += src/oracleimporter.h src/window_main.h ../cockatrice/src/carddatabase SOURCES += src/main.cpp src/oracleimporter.cpp src/window_main.cpp ../cockatrice/src/carddatabase.cpp ../cockatrice/src/settingscache.cpp macx { - CONFIG += x86 ppc +# CONFIG += x86 ppc +CONFIG += x86_64 release LIBS += -bind_at_load }