From f08b762107c7b22227a0c7b3d21c18b4b976f47a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=83=A1=E6=99=97?= Date: Fri, 15 Aug 2025 10:06:48 +0800 Subject: [PATCH] fix spell error MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 胡晗 --- .../window_manager_napi/js_window_manager.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/interfaces/kits/napi/window_runtime/window_manager_napi/js_window_manager.cpp b/interfaces/kits/napi/window_runtime/window_manager_napi/js_window_manager.cpp index aa2d6ad6a4..a6dd850ec4 100644 --- a/interfaces/kits/napi/window_runtime/window_manager_napi/js_window_manager.cpp +++ b/interfaces/kits/napi/window_runtime/window_manager_napi/js_window_manager.cpp @@ -957,7 +957,7 @@ static napi_value GetTopWindowTask(void* contextPtr, napi_env env, napi_value ca if (lists->ability->GetWindow() == nullptr) { lists->errorCode = newApi ? static_cast(WmErrorCode::WM_ERROR_STATE_ABNORMALLY) : static_cast(WMError::WM_ERROR_NULLPTR); - lists->errMsg = "[window][getLatsWindow]msg: FA mode can not get ability window"; + lists->errMsg = "[window][getLastWindow]msg: FA mode can not get ability window"; return; } lists->window = Window::GetTopWindowWithId(lists->ability->GetWindow()->GetWindowId()); @@ -966,7 +966,7 @@ static napi_value GetTopWindowTask(void* contextPtr, napi_env env, napi_value ca if (contextPtr == nullptr || context == nullptr) { lists->errorCode = newApi ? static_cast(WmErrorCode::WM_ERROR_STATE_ABNORMALLY) : static_cast(WMError::WM_ERROR_NULLPTR); - lists->errMsg = "[window][getLatsWindow]msg: Stage mode without context"; + lists->errMsg = "[window][getLastWindow]msg: Stage mode without context"; return; } lists->window = Window::GetTopWindowWithContext(context->lock()); @@ -976,10 +976,10 @@ static napi_value GetTopWindowTask(void* contextPtr, napi_env env, napi_value ca if (lists == nullptr) { if (newApi) { task.Reject(env, JsErrUtils::CreateJsError(env, WmErrorCode::WM_ERROR_STATE_ABNORMALLY, - "[window][getLatsWindow]msg: NAPI abnormal")); + "[window][getLastWindow]msg: NAPI abnormal")); } else { task.Reject(env, JsErrUtils::CreateJsError(env, WMError::WM_ERROR_NULLPTR, - "[window][getLatsWindow]msg: NAPI abnormal")); + "[window][getLastWindow]msg: NAPI abnormal")); } return; } @@ -997,10 +997,10 @@ static napi_value GetTopWindowTask(void* contextPtr, napi_env env, napi_value ca if (lists->window == nullptr || lists->window->GetWindowState() == WindowState::STATE_DESTROYED) { if (newApi) { task.Reject(env, JsErrUtils::CreateJsError(env, WmErrorCode::WM_ERROR_STATE_ABNORMALLY, - "[window][getLatsWindow]msg: Get top window failed")); + "[window][getLastWindow]msg: Get top window failed")); } else { task.Reject(env, JsErrUtils::CreateJsError(env, WMError::WM_ERROR_NULLPTR, - "[window][getLatsWindow]msg: Get top window failed")); + "[window][getLastWindow]msg: Get top window failed")); } return; } -- Gitee