@@ -54,6 +54,8 @@ export const use_panel = (vscode: any) => {
5454 find_relevant_files_shrink_source_code ,
5555 set_find_relevant_files_shrink_source_code
5656 ] = useState < boolean > ( false )
57+ const [ voice_input_push_to_talk , set_voice_input_push_to_talk ] =
58+ useState ( false )
5759
5860 const handle_task_forward = ( text : string ) => {
5961 handle_instructions_change ( text , 'edit-context' )
@@ -152,6 +154,8 @@ export const use_panel = (vscode: any) => {
152154 set_find_relevant_files_shrink_source_code ( message . shrink_source_code )
153155 } else if ( message . command == 'RETURN_HOME' ) {
154156 set_active_view ( 'home' )
157+ } else if ( message . command == 'VOICE_INPUT_PUSH_TO_TALK' ) {
158+ set_voice_input_push_to_talk ( message . enabled )
155159 }
156160 }
157161 window . addEventListener ( 'message' , handle_message )
@@ -168,7 +172,8 @@ export const use_panel = (vscode: any) => {
168172 { command : 'GET_CHECKPOINTS' } ,
169173 { command : 'REQUEST_CAN_UNDO' } ,
170174 { command : 'GET_SETUP_PROGRESS' } ,
171- { command : 'GET_FIND_RELEVANT_FILES_SHRINK_SOURCE_CODE' }
175+ { command : 'GET_FIND_RELEVANT_FILES_SHRINK_SOURCE_CODE' } ,
176+ { command : 'GET_VOICE_INPUT_PUSH_TO_TALK' }
172177 ]
173178 initial_messages . forEach ( ( message ) => post_message ( vscode , message ) )
174179
@@ -296,6 +301,7 @@ export const use_panel = (vscode: any) => {
296301 handle_find_relevant_files_shrink_source_code_change,
297302 handle_tab_change,
298303 handle_new_tab,
299- handle_tab_delete
304+ handle_tab_delete,
305+ voice_input_push_to_talk
300306 }
301307}
0 commit comments