From: luozheng <1732036298@qq.com> Date: Fri, 20 Sep 2024 12:46:13 +0000 (+0800) Subject: 解决设置视图右滑难退出问题 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=bcd8cf9d167c00483a384d7e83e1e15ba2754fe4;p=mirrors%2FFD230.git 解决设置视图右滑难退出问题 --- diff --git a/code/sdk/application/wearable/fd230app/nativeui/settings/src/SettingView.cpp b/code/sdk/application/wearable/fd230app/nativeui/settings/src/SettingView.cpp index 006795faa..9bd7ca5fb 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/settings/src/SettingView.cpp +++ b/code/sdk/application/wearable/fd230app/nativeui/settings/src/SettingView.cpp @@ -2,7 +2,7 @@ * @Author: luozheng 1732036298@qq.com * @Date: 2024-07-12 09:55:29 * @LastEditors: luozheng 1732036298@qq.com - * @LastEditTime: 2024-09-20 16:04:46 + * @LastEditTime: 2024-09-20 20:42:55 * @FilePath: /FD230/code/sdk/application/wearable/fd230app/nativeui/settings/src/SettingView.cpp */ @@ -90,6 +90,7 @@ namespace OHOS scrollView->SetHorizontalScrollState(false); scrollView->SetTouchable(true); scrollView->SetThrowDrag(true); + scrollView->SetOnDragListener(presenter_); /* -------------------------------------------------------------------------- */ title = new UILabelExt(); if (title == nullptr) @@ -134,7 +135,6 @@ namespace OHOS FocusManager::GetInstance()->RequestFocus(contentList); FocusManager::GetInstance()->RequestFocusByDirection(FOCUS_DIRECTION_UP); contentList->SetRotateFactor(1.0); - contentList->SetOnDragListener(presenter_); /* ----------------------------------- Add ---------------------------------- */ scrollView->Add(title); scrollView->Add(contentList);