From 8bf9f114e3f8d59e126eb4736c1d46ca42511ab0 Mon Sep 17 00:00:00 2001 From: guyuanzhang Date: Wed, 16 Jun 2021 11:00:41 +0800 Subject: [PATCH] Description:fix ui code clean Sig:graphic Feature or Bugfix:Feature Binary Source:No Signed-off-by: guyuanzhang --- frameworks/draw/draw_utils.cpp | 6 ++++-- test/uitest/test_view_bounds/ui_test_view_bounds.cpp | 2 +- test/uitest/test_view_bounds/ui_test_view_bounds.h | 2 +- test/unittest/components/ui_scroll_bar_test.cpp | 8 ++++---- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/frameworks/draw/draw_utils.cpp b/frameworks/draw/draw_utils.cpp index 2700c02..51f5bf3 100755 --- a/frameworks/draw/draw_utils.cpp +++ b/frameworks/draw/draw_utils.cpp @@ -1290,9 +1290,11 @@ void DrawUtils::DrawTriangleTrueColorBilinear8888(const TriangleScanInfo& in, co { DEBUG_PERFORMANCE_TRACE("DrawTriangleTrueColorBilinear8888"); #if ENABLE_FIXED_POINT - DrawFixedTriangleTrueColorBilinear8888Inner(in, screenBuffer, xMax - xMin + 1, bufferMode, in.init.verticalU, in.init.verticalV); + DrawFixedTriangleTrueColorBilinear8888Inner(in, screenBuffer, xMax - xMin + 1, bufferMode, + in.init.verticalU, in.init.verticalV); #else - DrawTriangleTrueColorBilinear8888Inner(in, screenBuffer, xMax - xMin + 1, bufferMode, in.init.verticalU, in.init.verticalV); + DrawTriangleTrueColorBilinear8888Inner(in, screenBuffer, xMax - xMin + 1, bufferMode, in.init.verticalU, + in.init.verticalV); #endif } #endif diff --git a/test/uitest/test_view_bounds/ui_test_view_bounds.cpp b/test/uitest/test_view_bounds/ui_test_view_bounds.cpp index bb57205..6014b3a 100644 --- a/test/uitest/test_view_bounds/ui_test_view_bounds.cpp +++ b/test/uitest/test_view_bounds/ui_test_view_bounds.cpp @@ -54,7 +54,7 @@ void UITestViewBounds::TearDown() container_ = nullptr; } -UIView* UITestViewBounds::GetTestView() +const UIView* UITestViewBounds::GetTestView() { UIKitViewBoundsSetState001(); UIKitViewBoundsMargin001(); diff --git a/test/uitest/test_view_bounds/ui_test_view_bounds.h b/test/uitest/test_view_bounds/ui_test_view_bounds.h index 34bad06..884a9ae 100644 --- a/test/uitest/test_view_bounds/ui_test_view_bounds.h +++ b/test/uitest/test_view_bounds/ui_test_view_bounds.h @@ -31,7 +31,7 @@ public: ~UITestViewBounds(); void SetUp() override; void TearDown() override; - UIView* GetTestView() override; + const UIView* GetTestView() override; /** * @brief test show or hide view bounds diff --git a/test/unittest/components/ui_scroll_bar_test.cpp b/test/unittest/components/ui_scroll_bar_test.cpp index 2423344..366724a 100644 --- a/test/unittest/components/ui_scroll_bar_test.cpp +++ b/test/unittest/components/ui_scroll_bar_test.cpp @@ -42,11 +42,11 @@ public: { return radius_; } - Style* GetBackStyle() + const Style* GetBackStyle() { return backgroundStyle_; } - Style* GetForeStyle() + const Style* GetForeStyle() { return foregroundStyle_; } @@ -70,11 +70,11 @@ public: { return backgroundRect_.GetHeight(); } - Style* GetBackStyle() + const Style* GetBackStyle() { return backgroundStyle_; } - Style* GetForeStyle() + const Style* GetForeStyle() { return foregroundStyle_; } -- GitLab