mirror of
https://gitee.com/openharmony/inputmethod_imf
synced 2024-12-18 04:10:21 +00:00
!538 【问题修复】修复stopInput等的napi实现问题 && 修改选择输入法弹窗类型为悬浮窗类型
Merge pull request !538 from Hollokin/master
This commit is contained in:
commit
6208a4d728
@ -133,6 +133,7 @@ napi_value JsGetInputMethodController::HandleSoftKeyboard(
|
|||||||
ctxt->SetErrorCode(errCode);
|
ctxt->SetErrorCode(errCode);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
ctxt->SetAction(std::move(input), std::move(output));
|
||||||
AsyncCall asyncCall(env, info, std::dynamic_pointer_cast<AsyncCall::Context>(ctxt), 0);
|
AsyncCall asyncCall(env, info, std::dynamic_pointer_cast<AsyncCall::Context>(ctxt), 0);
|
||||||
return asyncCall.Call(env, exec);
|
return asyncCall.Call(env, exec);
|
||||||
}
|
}
|
||||||
|
@ -37,7 +37,7 @@ export default class ServiceExtAbility extends ServiceExtensionAbility {
|
|||||||
height: 300,
|
height: 300,
|
||||||
}
|
}
|
||||||
this.getInputMethods().then(() => {
|
this.getInputMethods().then(() => {
|
||||||
this.createWindow("inputmethod Dialog:" + startId, window.WindowType.TYPE_DIALOG, dialogRect)
|
this.createWindow("inputmethod Dialog:" + startId, window.WindowType.TYPE_FLOAT, dialogRect)
|
||||||
})
|
})
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
console.log(TAG + "getDefaultDisplay err: " + JSON.stringify(err));
|
console.log(TAG + "getDefaultDisplay err: " + JSON.stringify(err));
|
||||||
|
@ -27,6 +27,9 @@
|
|||||||
"requestPermissions": [
|
"requestPermissions": [
|
||||||
{
|
{
|
||||||
"name": "ohos.permission.CONNECT_IME_ABILITY"
|
"name": "ohos.permission.CONNECT_IME_ABILITY"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "ohos.permission.SYSTEM_FLOAT_WINDOW"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user