add sandbox support to desktop designer, fix mouse coordinates and UI issues
- Add DesktopSandbox class that integrates timer, JSON, crypto, and VirtualFS APIs - Fix mouse coordinate handling: GLFW reports window coordinates, not physical pixels - Fix font path resolution to search multiple locations for test apps - Fix screenshot capture timing (capture before buffer swap) - Fix test app CSS: use border-width instead of border:none, add display:block - Fix test app Lua: add document nil checks, use HTML entities for symbols - Update hot_reload to reset sandbox state on reload Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -55,6 +55,14 @@ target_compile_definitions(mosis-kernel PUBLIC
|
||||
RMLUI_GL3_CUSTOM_LOADER="glad_loader.h"
|
||||
)
|
||||
|
||||
# Sandbox sources (reuse from MosisService)
|
||||
set(SANDBOX_SOURCES
|
||||
../src/main/cpp/sandbox/timer_manager.cpp
|
||||
../src/main/cpp/sandbox/json_api.cpp
|
||||
../src/main/cpp/sandbox/crypto_api.cpp
|
||||
../src/main/cpp/sandbox/virtual_fs.cpp
|
||||
)
|
||||
|
||||
# Designer executable
|
||||
add_executable(mosis-designer
|
||||
main.cpp
|
||||
@@ -62,6 +70,7 @@ add_executable(mosis-designer
|
||||
src/desktop_file_interface.cpp
|
||||
src/hot_reload.cpp
|
||||
src/platform_singleton.cpp
|
||||
src/desktop_sandbox.cpp
|
||||
src/testing/action_recorder.cpp
|
||||
src/testing/action_player.cpp
|
||||
src/testing/ui_inspector.cpp
|
||||
@@ -69,6 +78,8 @@ add_executable(mosis-designer
|
||||
# Local backend with input recording hooks
|
||||
src/backend/RmlUi_Backend_GLFW_GL3.cpp
|
||||
src/backend/RmlUi_Platform_GLFW.cpp
|
||||
# Sandbox APIs
|
||||
${SANDBOX_SOURCES}
|
||||
)
|
||||
|
||||
target_include_directories(mosis-designer PRIVATE
|
||||
@@ -77,6 +88,7 @@ target_include_directories(mosis-designer PRIVATE
|
||||
src/backend
|
||||
../src/main/kernel/include
|
||||
../src/main/cpp
|
||||
../src/main/cpp/sandbox
|
||||
)
|
||||
|
||||
target_link_libraries(mosis-designer PRIVATE
|
||||
|
||||
Reference in New Issue
Block a user