From bfdae8a2b130085313d29d14ef61e863e7887451 Mon Sep 17 00:00:00 2001 From: ma-shaoyin Date: Fri, 23 Sep 2022 10:34:38 +0800 Subject: [PATCH] Signed-off-by: ma-shaoyin Changes to be committed: --- .../js_input_method_engine_setting.h | 2 +- .../js_text_input_client_engine.h | 14 +++++++------- .../js_get_input_method_controller.h | 2 +- .../js_get_input_method_setting.h | 2 +- .../js/napi/inputmethodclient/js_input_method.h | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/interfaces/kits/js/napi/inputmethodability/js_input_method_engine_setting.h b/interfaces/kits/js/napi/inputmethodability/js_input_method_engine_setting.h index 298fb0ff..4ba28758 100644 --- a/interfaces/kits/js/napi/inputmethodability/js_input_method_engine_setting.h +++ b/interfaces/kits/js/napi/inputmethodability/js_input_method_engine_setting.h @@ -54,7 +54,7 @@ private: uv_work_t *GetUVwork(std::string type); uv_work_t *GetStopInputUVwork(std::string type, std::string imeId); uv_work_t *GetWindowIDUVwork(std::string type, uint32_t windowid); - static std::string GetStringProperty(napi_env env, napi_value obj); + static std::string GetStringProperty(napi_env env, napi_value jsString); static constexpr int32_t MAX_VALUE_LEN = 1024; static const std::string IMES_CLASS_NAME; static thread_local napi_ref IMESRef_; diff --git a/interfaces/kits/js/napi/inputmethodability/js_text_input_client_engine.h b/interfaces/kits/js/napi/inputmethodability/js_text_input_client_engine.h index e898e427..d206dbd4 100644 --- a/interfaces/kits/js/napi/inputmethodability/js_text_input_client_engine.h +++ b/interfaces/kits/js/napi/inputmethodability/js_text_input_client_engine.h @@ -196,14 +196,14 @@ public: JsTextInputClientEngine() = default; ~JsTextInputClientEngine() = default; static napi_value Init(napi_env env, napi_value info); - static napi_value SendKeyFunction(napi_env env, napi_callback_info Info); - static napi_value DeleteForward(napi_env env, napi_callback_info Info); - static napi_value DeleteBackward(napi_env env, napi_callback_info Info); - static napi_value InsertText(napi_env env, napi_callback_info Info); - static napi_value GetForward(napi_env env, napi_callback_info Info); - static napi_value GetBackward(napi_env env, napi_callback_info Info); + static napi_value SendKeyFunction(napi_env env, napi_callback_info info); + static napi_value DeleteForward(napi_env env, napi_callback_info info); + static napi_value DeleteBackward(napi_env env, napi_callback_info info); + static napi_value InsertText(napi_env env, napi_callback_info info); + static napi_value GetForward(napi_env env, napi_callback_info info); + static napi_value GetBackward(napi_env env, napi_callback_info info); static napi_value MoveCursor(napi_env env, napi_callback_info info); - static napi_value GetEditorAttribute(napi_env env, napi_callback_info Info); + static napi_value GetEditorAttribute(napi_env env, napi_callback_info info); static napi_value GetTextInputClientInstance(napi_env env); private: static napi_status GetAction(napi_env env, napi_value argv, diff --git a/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_controller.h b/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_controller.h index 4e154ba0..c7564398 100644 --- a/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_controller.h +++ b/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_controller.h @@ -46,7 +46,7 @@ public: JsGetInputMethodController() = default; ~JsGetInputMethodController() = default; static napi_value Init(napi_env env, napi_value info); - static napi_value GetInputMethodController(napi_env env, napi_callback_info info); + static napi_value GetInputMethodController(napi_env env, napi_callback_info cbInfo); static napi_value HandleSoftKeyboard( napi_env env, napi_callback_info info, std::function callback, bool isOutput); static napi_value HideSoftKeyboard(napi_env env, napi_callback_info info); diff --git a/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_setting.h b/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_setting.h index 748d7fd0..02554a60 100644 --- a/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_setting.h +++ b/interfaces/kits/js/napi/inputmethodclient/js_get_input_method_setting.h @@ -23,7 +23,7 @@ namespace OHOS { namespace MiscServices { struct ListInputContext : public AsyncCall::Context { - InputMethodStatus inputMethodStatus; + InputMethodStatus inputMethodStatus = InputMethodStatus::ALL; std::vector properties; napi_status status = napi_generic_failure; ListInputContext() : Context(nullptr, nullptr) { }; diff --git a/interfaces/kits/js/napi/inputmethodclient/js_input_method.h b/interfaces/kits/js/napi/inputmethodclient/js_input_method.h index 9fe04fb8..c4428e3d 100644 --- a/interfaces/kits/js/napi/inputmethodclient/js_input_method.h +++ b/interfaces/kits/js/napi/inputmethodclient/js_input_method.h @@ -56,7 +56,7 @@ public: static napi_value GetJSInputMethodProperties(napi_env env, const std::vector &properties); private: - static std::string GetStringProperty(napi_env env, napi_value result); + static std::string GetStringProperty(napi_env env, napi_value obj); static napi_status GetInputMethodProperty(napi_env env, napi_value argv, std::shared_ptr ctxt); static constexpr std::int32_t MAX_VALUE_LEN = 4096;