diff --git a/options.json b/options.json new file mode 100644 index 0000000..b27e67a --- /dev/null +++ b/options.json @@ -0,0 +1,44 @@ +{ + "startup" : { + "open_OBS" : true, + "OBS_path" : "C:\\ProgramData\\Microsoft\\Windows\\Start Menu\\Programs\\OBS Studio\\OBS Studio (64bit).lnk", + "open_ProPresenter" : false, + "ProPresenter_path" : "C:\\Program Files (x86)\\Renewed Vision\\ProPresenter 6\\ProPresenter.exe", + "open_itunes" : false, + "itunes_path" : " Not Implemented " + }, + "streaming_service": "w3schools", + "general":{ + "music_default_state-on" : true, + "music_fade_time": 5, + "default_timer_length": 15, + "windows_change_delay_length": 0.1, + "obs_screen_switch_delay_length": 0.4 + }, + "windows":{ + "obs_re": "OBS ", + "propresenter_re": "ProPresenter - .*", + "chrome_re": ".* - Google Chrome" + }, + "hotkeys":{ + "obs":{ + "camera_scene_hotkey" : "shift+alt+ctrl+*", + "screen_scene_hotkey" : "shift+alt+ctrl+/", + "camera_scene_augmented" : "shift+alt+ctrl+-", + "unmute_stream" : "shift+alt+ctrl+u", + "mute_stream" : "shift+alt+ctrl+i", + "start_stream" : "ctrl+shift+j", + "stop_stream" : "ctrl+alt+j", + "Camera_Top_Right" : "ctrl+alt+]", + "Camera_Bottom_Right" : "ctrl+shift+]", + "Camera_Bottom_Left" : "ctrl+shift+alt+]", + "Screen_Top_Right" : "ctrl+alt+[", + "Screen_Bottom_Right" : "ctrl+shift+[" + }, + "general":{ + "clicker_forward" : "page down", + "clicker_backward" : "page up" + } + } + +} \ No newline at end of file diff --git a/src/tests/message_handler_tests.rs b/src/tests/message_handler_tests.rs index 38d88f7..621fb24 100644 --- a/src/tests/message_handler_tests.rs +++ b/src/tests/message_handler_tests.rs @@ -1,10 +1,13 @@ -use crate::modules::{message_handler::{MessageHandler}, stream_states::{state_update::StateUpdate, stream_states_class::StreamState}}; +use crate::modules::{message_handler::{MessageHandler}, stream_states::{state_update::StateUpdate, stream_states_class::StreamState}, external_interface::Hotkeys}; #[test] fn does_stream_state_implement_message_handler() { + let hotkeys = Hotkeys { + hotkeys: serde_json::Value::Null + }; let mut state = StreamState::new(); state.debug_mode = true; - state.handle_update(StateUpdate::ToggleComputerSoundOn(false)); + state.handle_update(StateUpdate::ToggleComputerSoundOn(false), &hotkeys); assert_eq!(state.computer_sound_is_on, false); }