[nostalgia/studio] Bundle default profile in studio executable
This commit is contained in:
parent
4276135e65
commit
45a27800b6
6
Makefile
6
Makefile
@ -26,11 +26,9 @@ endif
|
|||||||
|
|
||||||
ifeq ($(OS),darwin)
|
ifeq ($(OS),darwin)
|
||||||
NOSTALGIA_STUDIO=./dist/${CURRENT_BUILD}/nostalgia-studio.app/Contents/MacOS/nostalgia-studio
|
NOSTALGIA_STUDIO=./dist/${CURRENT_BUILD}/nostalgia-studio.app/Contents/MacOS/nostalgia-studio
|
||||||
NOSTALGIA_STUDIO_PROFILE=dist/${CURRENT_BUILD}/nostalgia-studio.app/Contents/Resources/nostalgia-studio.json
|
|
||||||
MGBA=/Applications/mGBA.app/Contents/MacOS/mGBA
|
MGBA=/Applications/mGBA.app/Contents/MacOS/mGBA
|
||||||
else
|
else
|
||||||
NOSTALGIA_STUDIO=./dist/${CURRENT_BUILD}/bin/nostalgia-studio
|
NOSTALGIA_STUDIO=./dist/${CURRENT_BUILD}/bin/nostalgia-studio
|
||||||
NOSTALGIA_STUDIO_PROFILE=dist/${CURRENT_BUILD}/share/nostalgia-studio.json
|
|
||||||
MGBA=mgba-qt
|
MGBA=mgba-qt
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -59,7 +57,7 @@ run: install
|
|||||||
${ENV_RUN} ./dist/${CURRENT_BUILD}/bin/nostalgia sample_project
|
${ENV_RUN} ./dist/${CURRENT_BUILD}/bin/nostalgia sample_project
|
||||||
.PHONY: run-studio
|
.PHONY: run-studio
|
||||||
run-studio: install
|
run-studio: install
|
||||||
${ENV_RUN} ${NOSTALGIA_STUDIO} -profile ${NOSTALGIA_STUDIO_PROFILE}
|
${ENV_RUN} ${NOSTALGIA_STUDIO}
|
||||||
.PHONY: gba-run
|
.PHONY: gba-run
|
||||||
gba-run: pkg-gba
|
gba-run: pkg-gba
|
||||||
${MGBA} nostalgia.gba
|
${MGBA} nostalgia.gba
|
||||||
@ -68,7 +66,7 @@ gdb: install
|
|||||||
${ENV_RUN} gdb --args ./dist/${CURRENT_BUILD}/bin/nostalgia sample_project
|
${ENV_RUN} gdb --args ./dist/${CURRENT_BUILD}/bin/nostalgia sample_project
|
||||||
.PHONY: gdb-studio
|
.PHONY: gdb-studio
|
||||||
gdb-studio: install
|
gdb-studio: install
|
||||||
${ENV_RUN} gdb --args ${NOSTALGIA_STUDIO} -profile ${NOSTALGIA_STUDIO_PROFILE}
|
${ENV_RUN} gdb --args ${NOSTALGIA_STUDIO}
|
||||||
|
|
||||||
.PHONY: devenv-image
|
.PHONY: devenv-image
|
||||||
devenv-image:
|
devenv-image:
|
||||||
|
@ -10,6 +10,7 @@ add_executable(
|
|||||||
main.cpp
|
main.cpp
|
||||||
mainwindow.cpp
|
mainwindow.cpp
|
||||||
oxfstreeview.cpp
|
oxfstreeview.cpp
|
||||||
|
studiorsrc.qrc
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(
|
target_link_libraries(
|
||||||
|
@ -16,7 +16,7 @@ using namespace nostalgia::studio;
|
|||||||
|
|
||||||
int main(int argc, char **args) {
|
int main(int argc, char **args) {
|
||||||
ox::ClArgs clargs(argc, const_cast<const char**>(args));
|
ox::ClArgs clargs(argc, const_cast<const char**>(args));
|
||||||
QString argProfilePath = clargs.getString("profile").c_str();
|
QString argProfilePath = clargs.getString("profile", ":/profiles/nostalgia-studio.json").c_str();
|
||||||
|
|
||||||
QApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
|
QApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
|
||||||
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||||
|
@ -46,8 +46,8 @@ ox::Error model(T *io, NostalgiaStudioState *obj) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct NostalgiaStudioProfile {
|
struct NostalgiaStudioProfile {
|
||||||
QString appName = "Nostalgia Studio";
|
QString appName;
|
||||||
QString orgName = "Drinking Tea";
|
QString orgName;
|
||||||
QVector<QString> modulesPath;
|
QVector<QString> modulesPath;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
6
src/nostalgia/studio/studiorsrc.qrc
Normal file
6
src/nostalgia/studio/studiorsrc.qrc
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<RCC>
|
||||||
|
<qresource prefix="/profiles">
|
||||||
|
<file>nostalgia-studio.json</file>
|
||||||
|
<file>nostalgia-studio-dev.json</file>
|
||||||
|
</qresource>
|
||||||
|
</RCC>
|
Loading…
Reference in New Issue
Block a user