Add neutral None variant to InputMethod
This commit is contained in:
parent
ae10adda74
commit
db990b77e4
4 changed files with 19 additions and 9 deletions
|
|
@ -203,10 +203,13 @@ where
|
|||
}
|
||||
|
||||
pub fn request_input_method(&mut self, input_method: InputMethod) {
|
||||
self.raw.set_ime_allowed(match input_method {
|
||||
InputMethod::Disabled => false,
|
||||
InputMethod::Allowed | InputMethod::Open { .. } => true,
|
||||
});
|
||||
match input_method {
|
||||
InputMethod::None => {}
|
||||
InputMethod::Disabled => self.raw.set_ime_allowed(false),
|
||||
InputMethod::Allowed | InputMethod::Open { .. } => {
|
||||
self.raw.set_ime_allowed(true)
|
||||
}
|
||||
}
|
||||
|
||||
if let InputMethod::Open {
|
||||
position,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue