diff --git a/.gitignore b/.gitignore index 8c8d3e2..d46e6a8 100644 --- a/.gitignore +++ b/.gitignore @@ -22,3 +22,9 @@ hardware/kicad/ost-pico-addon/fp-info-cache *.png~ build-story-editor-Desktop_Qt_6_5_1_GCC_64bit-Debug/ + +build-story-editor-Desktop_Qt_6_5_1_MinGW_64_bit-Debug/ + +build-story-editor-Desktop_Qt_6_5_1_MinGW_64_bit-Release/ + +build-story-editor-Desktop_Qt_6_5_1_MSVC2019_64bit-Debug/ diff --git a/story-editor/src/main_window.cpp b/story-editor/src/main_window.cpp index d164da1..4cb264d 100644 --- a/story-editor/src/main_window.cpp +++ b/story-editor/src/main_window.cpp @@ -563,7 +563,7 @@ uint8_t MainWindow::Syscall(uint8_t code) // sound file name address is in R1 QString soundFile = m_model.BuildFullSoundPath(GetFileNameFromMemory(m_chip32_ctx.registers[R1])); qDebug() << ", Sound: " << soundFile; - m_model.PlaySound(soundFile); + m_model.PlaySoundFile(soundFile); } retCode = SYSCALL_RET_WAIT_EV; // set the VM in pause } diff --git a/story-editor/src/media_node_model.cpp b/story-editor/src/media_node_model.cpp index 84a8578..cda8b9b 100644 --- a/story-editor/src/media_node_model.cpp +++ b/story-editor/src/media_node_model.cpp @@ -52,7 +52,7 @@ MediaNodeModel::MediaNodeModel(StoryGraphModel &model) }); connect(m_ui.playSoundButton, &QPushButton::clicked, [&](bool enable) { - m_model.PlaySound(m_soundFilePath); + m_model.PlaySoundFile(m_soundFilePath); }); m_ui.playSoundButton->setEnabled(false); diff --git a/story-editor/src/resources_dock.cpp b/story-editor/src/resources_dock.cpp index 2c62d31..8304a9c 100644 --- a/story-editor/src/resources_dock.cpp +++ b/story-editor/src/resources_dock.cpp @@ -29,7 +29,7 @@ ResourcesDock::ResourcesDock(StoryProject &project, ResourceModel &model) Resource res; res.format = "BMP"; res.type = "image"; - res.file = p.filename(); + res.file = p.filename().generic_string(); m_resourcesModel.Append(res); } }); @@ -49,7 +49,7 @@ ResourcesDock::ResourcesDock(StoryProject &project, ResourceModel &model) Resource res; res.format = "WAV"; res.type = "sound"; - res.file = p.filename(); + res.file = p.filename().generic_string(); m_resourcesModel.Append(res); } }); diff --git a/story-editor/src/story_graph_model.cpp b/story-editor/src/story_graph_model.cpp index c2790d0..64d2da9 100644 --- a/story-editor/src/story_graph_model.cpp +++ b/story-editor/src/story_graph_model.cpp @@ -46,7 +46,7 @@ void StoryGraphModel::AudioThread() } } -void StoryGraphModel::PlaySound(const QString &fileName) +void StoryGraphModel::PlaySoundFile(const QString &fileName) { m_audioQueue.push({"play", fileName.toStdString()}); } diff --git a/story-editor/src/story_graph_model.h b/story-editor/src/story_graph_model.h index e26ead2..27ae391 100644 --- a/story-editor/src/story_graph_model.h +++ b/story-editor/src/story_graph_model.h @@ -180,7 +180,7 @@ public: std::string GetNodeEntryLabel(NodeId nodeId) const; // Centralized for wide usage - void PlaySound(const QString &fileName); + void PlaySoundFile(const QString &fileName); NodeId FindFirstNode() const; signals: diff --git a/story-editor/src/story_project.cpp b/story-editor/src/story_project.cpp index 0367ddc..f42be5a 100644 --- a/story-editor/src/story_project.cpp +++ b/story-editor/src/story_project.cpp @@ -17,7 +17,7 @@ void StoryProject::Initialize(const std::string &file_path) { m_project_file_path = file_path; std::filesystem::path p(file_path); - m_working_dir= p.parent_path(); + m_working_dir= p.parent_path().generic_string(); // Frist try to create the working directory if (!std::filesystem::is_directory(m_working_dir)) @@ -40,7 +40,7 @@ bool StoryProject::Load(const std::string &file_path, nlohmann::json &model) bool success = false; std::filesystem::path p(file_path); - m_working_dir= p.parent_path(); + m_working_dir= p.parent_path().generic_string(); std::cout << "Working dir is: " << m_working_dir << std::endl;