fenster können erstellt werden
This commit is contained in:
@@ -49,7 +49,7 @@ file(GLOB_RECURSE SOURCES "src/*.cpp" "inc/*.h")
|
|||||||
add_executable(Toolbox main.cpp ${SOURCES} ${RESOURCE_FILES} ${PLATFORM_SOURCES})
|
add_executable(Toolbox main.cpp ${SOURCES} ${RESOURCE_FILES} ${PLATFORM_SOURCES})
|
||||||
|
|
||||||
target_include_directories(${PROJECT_NAME} PRIVATE "out_embed")
|
target_include_directories(${PROJECT_NAME} PRIVATE "out_embed")
|
||||||
target_link_libraries(Toolbox PRIVATE saucer::saucer sol2::sol2 tray nlohmann_json cppcodec fltk::fltk moonfltk lua)
|
target_link_libraries(Toolbox PRIVATE saucer::saucer sol2::sol2 tray nlohmann_json cppcodec fltk moonfltk lua)
|
||||||
|
|
||||||
if(WIN32 AND (CMAKE_BUILD_TYPE STREQUAL "Release" OR CMAKE_BUILD_TYPE STREQUAL "MinSizeRel"))
|
if(WIN32 AND (CMAKE_BUILD_TYPE STREQUAL "Release" OR CMAKE_BUILD_TYPE STREQUAL "MinSizeRel"))
|
||||||
set_target_properties(Toolbox PROPERTIES WIN32_EXECUTABLE TRUE)
|
set_target_properties(Toolbox PROPERTIES WIN32_EXECUTABLE TRUE)
|
||||||
|
|||||||
2
lib/fltk
2
lib/fltk
Submodule lib/fltk updated: 34b5fe9e92...6835b94a47
Submodule lib/moonfltk updated: 8c63723dbb...3b63ccd8f7
@@ -261,10 +261,13 @@ void ToolboxWindow::run_lua(int id) {
|
|||||||
try {
|
try {
|
||||||
std::string scriptPath = m_toolboxItems[id].lua_script;
|
std::string scriptPath = m_toolboxItems[id].lua_script;
|
||||||
lua.script_file(scriptPath);
|
lua.script_file(scriptPath);
|
||||||
|
|
||||||
m_webview.execute("enableButtonByToolId({})",saucer::make_args(id));
|
m_webview.execute("enableButtonByToolId({})",saucer::make_args(id));
|
||||||
m_webview.reload();
|
m_webview.reload();
|
||||||
} catch (const sol::error& e) {
|
} catch (const sol::error& e) {
|
||||||
std::cerr << "Lua error: " << e.what() << std::endl;
|
std::cerr << "Lua error: " << e.what() << std::endl;
|
||||||
|
m_webview.execute("enableButtonByToolId({})",saucer::make_args(id));
|
||||||
|
m_webview.reload();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user