mirror of
				https://github.com/mfulz/qmk_firmware.git
				synced 2025-11-04 07:12:33 +01:00 
			
		
		
		
	Add user-overridable callback for cancelling UCIS input (#5564)
* Add user-overridable callback for cancelling UCIS input To clean up things from qk_ucis_start_user() for instance. * restore lost newline to quantum/process_keycode/process_ucis.c Co-Authored-By: shinmai <aapo.saaristo@gmail.com>
This commit is contained in:
		
							parent
							
								
									0f95c0865c
								
							
						
					
					
						commit
						2a231457bd
					
				@ -64,6 +64,10 @@ void qk_ucis_symbol_fallback (void) {
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
__attribute__((weak))
 | 
			
		||||
void qk_ucis_cancel(void) {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
void register_ucis(const char *hex) {
 | 
			
		||||
  for(int i = 0; hex[i]; i++) {
 | 
			
		||||
    uint8_t kc = 0;
 | 
			
		||||
@ -130,6 +134,7 @@ bool process_ucis (uint16_t keycode, keyrecord_t *record) {
 | 
			
		||||
 | 
			
		||||
    if (keycode == KC_ESC) {
 | 
			
		||||
      qk_ucis_state.in_progress = false;
 | 
			
		||||
      qk_ucis_cancel();
 | 
			
		||||
      return false;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user