diff --git a/src/imservice.rs b/src/imservice.rs index 3a87de4b..ce6a036e 100644 --- a/src/imservice.rs +++ b/src/imservice.rs @@ -153,14 +153,14 @@ pub mod c { if active_changed { (imservice.active_callback)(imservice.current.active); - if imservice.current.active { - unsafe { - eekboard_context_service_set_hint_purpose( - imservice.state_manager, - imservice.current.content_hint.bits(), - imservice.current.content_purpose.clone() as u32, - ); - } + } + if imservice.current.active { + unsafe { + eekboard_context_service_set_hint_purpose( + imservice.state_manager, + imservice.current.content_hint.bits(), + imservice.current.content_purpose.clone() as u32, + ); } } }