Skip to content

Commit e67ffab

Browse files
committed
Fix module paths under Linux.
1 parent 81c3d19 commit e67ffab

File tree

2 files changed

+21
-11
lines changed

2 files changed

+21
-11
lines changed

src/ide/ide.cpp

+17-11
Original file line numberDiff line numberDiff line change
@@ -473,11 +473,14 @@ void
473473
IDE::initModules()
474474
{
475475
this->activeModules.insert(
476-
"indicators", ModuleSlotWidget(tr("Block of 8-segment indicators"), "indicators", indicatorsModulePath, false));
476+
"indicators", ModuleSlotWidget(tr("Block of 8-segment indicators"),
477+
"indicators", indicatorsModulePath, false));
477478
this->activeModules.insert(
478-
"display", ModuleSlotWidget(tr("Text display and keyboard"), "display", displayModulePath, false));
479+
"display", ModuleSlotWidget(tr("Text display and keyboard"), "display",
480+
displayModulePath, false));
479481
this->activeModules.insert(
480-
"keyboard", ModuleSlotWidget(tr("Digital keyboard"), "keyboard", keyboardModulePath, false));
482+
"keyboard", ModuleSlotWidget(tr("Digital keyboard"), "keyboard",
483+
keyboardModulePath, false));
481484
this->activeModules.insert(
482485
"adc", ModuleSlotWidget(tr("ADC/DAC"), "adc", adcModulePath, false));
483486
}
@@ -525,14 +528,17 @@ IDE::onStepClick()
525528
this->ui->menuStart->setEnabled(true);
526529
}
527530

528-
#ifndef MAC_OS_X
531+
#ifdef MAC_OS_X
529532
const char* IDE::adcModulePath = "../Resources/adc.app/Contents/MacOS/adc";
530-
const char* IDE::displayModulePath = "../Resources/display.app/Contents/MacOS/display";
531-
const char* IDE::indicatorsModulePath = "../Resources/indicators.app/Contents/MacOS/indicators";
532-
const char* IDE::keyboardModulePath = "../Resources/keyboard.app/Contents/MacOS/keyboard";
533+
const char* IDE::displayModulePath =
534+
"../Resources/display.app/Contents/MacOS/display";
535+
const char* IDE::indicatorsModulePath =
536+
"../Resources/indicators.app/Contents/MacOS/indicators";
537+
const char* IDE::keyboardModulePath =
538+
"../Resources/keyboard.app/Contents/MacOS/keyboard";
533539
#else
534-
const char* IDE::adcModulePath = "modules/adc";
535-
const char* IDE::displayModulePath = "modules/display";
536-
const char* IDE::indicatorsModulePath = "modules/indicators";
537-
const char* IDE::keyboardModulePath = "modules/keyboard";
540+
const char* IDE::adcModulePath = "module/adc";
541+
const char* IDE::displayModulePath = "module/display";
542+
const char* IDE::indicatorsModulePath = "module/indicators";
543+
const char* IDE::keyboardModulePath = "module/keyboard";
538544
#endif

try8085.pri

+4
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,7 @@ QMAKE_BUNDLE_DATA += \
2121

2222
GIT_VERSION = $$system(git --git-dir $$PWD/.git --work-tree $$PWD describe --always --tags)
2323
DEFINES += GIT_VERSION=\\\"$$GIT_VERSION\\\"
24+
25+
macx {
26+
DEFINES += MAC_OS_X
27+
}

0 commit comments

Comments
 (0)