Load the settings file (configuration, --config)

Config parses and validates the JSON settings (D34): required device name
and broker host, defaults, type checks, device id from ha_unique_id or
derived from the name (D31), warnings for unknown keys and for a password
in a file others can read. Dashboard::prepare() loads it in overlay and
desktop mode; --config selects another file (D22). New static library
frameassistant_lib for app logic; tst_config covers it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-05 22:09:42 +02:00
co-authored by Claude Opus 5.5
parent 4f47874a4b
commit a3ba712860
7 changed files with 604 additions and 1 deletions
+9
View File
@@ -49,6 +49,14 @@ else()
endif()
message(STATUS "Vulkan backend: ${_vulkan_ok}")
# The app's own logic (no SteamVR, no rendering): linked by the app and its tests.
qt_add_library(frameassistant_lib STATIC
config/Config.h config/Config.cpp
)
target_include_directories(frameassistant_lib PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
target_link_libraries(frameassistant_lib PUBLIC Qt6::Core)
target_compile_options(frameassistant_lib PRIVATE -Wall -Wextra)
# The app: its UI is the QML module "FrameAssistant" (src/qml/).
vrdash_add_dashboard(frameassistant
OUTPUT_NAME ${VRDASH_EXECUTABLE_NAME}
@@ -57,6 +65,7 @@ vrdash_add_dashboard(frameassistant
QML_FILES
qml/Main.qml
qml/Card.qml)
target_link_libraries(frameassistant PRIVATE frameassistant_lib)
install(FILES ${OPENVR_LIBRARY} DESTINATION ${CMAKE_INSTALL_LIBDIR})