/test/testfwk/arkxtest/uitest/test/ |
D | rect_algorithm_test.cpp | 24 Rect rect(100, 200, 300, 400); in TEST() local 25 ASSERT_TRUE(RectAlgorithm::CheckEqual(rect, rect)); in TEST() 27 ASSERT_FALSE(RectAlgorithm::CheckEqual(rect, rect1)); in TEST() 68 auto rect = Rect(10, 20, 10, 20); in TEST() local 70 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(5, 15))); in TEST() 71 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(10, 15))); in TEST() 72 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(25, 15))); in TEST() 73 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(20, 15))); in TEST() 75 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(15, 5))); in TEST() 76 ASSERT_FALSE(RectAlgorithm::IsInnerPoint(rect, Point(15, 10))); in TEST() [all …]
|
D | ui_model_test.cpp | 26 Rect rect(100, 200, 300, 400); in TEST() local 27 ASSERT_EQ(100, rect.left_); in TEST() 28 ASSERT_EQ(200, rect.right_); in TEST() 29 ASSERT_EQ(300, rect.top_); in TEST() 30 ASSERT_EQ(400, rect.bottom_); in TEST() 32 ASSERT_EQ(rect.GetCenterX(), (100 + 200) / 2); in TEST() 33 ASSERT_EQ(rect.GetCenterY(), (300 + 400) / 2); in TEST() 34 ASSERT_EQ(rect.GetHeight(), 400 - 300); in TEST() 35 ASSERT_EQ(rect.GetWidth(), 200 - 100); in TEST() 329 for (auto &rect : visitor.boundsList_) { in CheckMergedTree() local [all …]
|
/test/xts/hats/hdf/display/device/ |
D | hdi_composition_check.cpp | 63 const IRect &rect = layer.displayRect; in GetCheckColors() local 65 if ((point.x >= rect.x) && (point.x < (rect.x + rect.w)) && (point.y >= rect.y) && in GetCheckColors() 66 (point.y < (rect.y + rect.h))) { in GetCheckColors() 86 const IRect &rect = layer.displayRect; in Check() local 88 GetCheckPoints({ rect.x, rect.y }, points); in Check() 89 GetCheckPoints({ rect.x, rect.y + rect.h }, points); in Check() 90 GetCheckPoints({ rect.x + rect.w, rect.y }, points); in Check() 91 GetCheckPoints({ rect.x + rect.w, rect.y + rect.h }, points); in Check() 93 … GetCheckPoints({ rect.x + rect.w / midPos, rect.y + rect.h / midPos }, points); // center point in Check()
|
D | hdi_test_layer.cpp | 144 void HdiTestLayer::SetLayerSize(IRect &rect) in SetLayerSize() argument 146 DISPLAY_TEST_LOGI("x : %d y : %d w : %d h : %d", rect.x, rect.y, rect.w, rect.h); in SetLayerSize() 147 mDisplayRect = rect; in SetLayerSize() 150 void HdiTestLayer::SetLayerCrop(IRect &rect) in SetLayerCrop() argument 152 DISPLAY_TEST_LOGI("x : %d y : %d w : %d h : %d", rect.x, rect.y, rect.w, rect.h); in SetLayerCrop() 153 mCropRect = rect; in SetLayerCrop()
|
/test/xts/acts/arkui/ace_ets_component_four/entry/src/main/ets/test/ |
D | DragEventJsunit.test.ets | 50 let rect = await Utils.getComponentRect('apple') 51 console.info("dragEventTest_0100 rectInfo is " + JSON.stringify(rect)); 52 let downX = rect.left + (rect.right - rect.left) / 2; 53 let downY = rect.top + (rect.bottom - rect.top) / 2; 78 let rect = await Utils.getComponentRect('orange') 79 console.info("dragEventTest_0200 rectInfo is " + JSON.stringify(rect)); 80 let downX = rect.left + (rect.right - rect.left) / 2; 81 let downY = rect.top + (rect.bottom - rect.top) / 2; 107 let rect = await Utils.getComponentRect('banana') 108 console.info("dragEventTest_0300 rectInfo is " + JSON.stringify(rect)); [all …]
|
/test/testfwk/arkxtest/uitest/core/ |
D | rect_algorithm.cpp | 49 static void CollectGridLineCoords(const Rect& rect, const Rect& overlay) in CollectGridLineCoords() argument 52 if (overlay.left_ >= rect.left_ && overlay.left_ <= rect.right_) { in CollectGridLineCoords() 65 if (overlay.right_ >= rect.left_ && overlay.right_ <= rect.right_) { in CollectGridLineCoords() 78 if (overlay.top_ >= rect.top_ && overlay.top_ <= rect.bottom_) { in CollectGridLineCoords() 91 if (overlay.bottom_ >= rect.top_ && overlay.bottom_ <= rect.bottom_) { in CollectGridLineCoords() 104 …static void CollectGridPoint(int32_t px, int32_t py, const Rect& rect, const vector<Rect>& overlay… in CollectGridPoint() argument 107 const bool onRectEdge = RectAlgorithm::IsPointOnEdge(rect, point); in CollectGridPoint() 108 if (!onRectEdge && !RectAlgorithm::IsInnerPoint(rect, point)) { in CollectGridPoint() 157 …bool RectAlgorithm::ComputeMaxVisibleRegion(const Rect& rect, const vector<Rect>& overlays, Rect& … in ComputeMaxVisibleRegion() argument 161 if (!RectAlgorithm::CheckIntersectant(rect, overlay)) { in ComputeMaxVisibleRegion() [all …]
|
D | ui_model.h | 117 FORCE_INLINE static bool IsInnerPoint(const Rect &rect, const Point &point); 118 FORCE_INLINE static bool IsPointOnEdge(const Rect &rect, const Point &point); 120 …static bool ComputeMaxVisibleRegion(const Rect &rect, const std::vector<Rect> &overlays, Rect &out… 139 FORCE_INLINE bool RectAlgorithm::IsInnerPoint(const Rect &rect, const Point& point) in IsInnerPoint() argument 141 if (point.px_ <= rect.left_ || point.px_ >= rect.right_ in IsInnerPoint() 142 || point.py_ <= rect.top_ || point.py_ >= rect.bottom_) { in IsInnerPoint() 148 FORCE_INLINE bool RectAlgorithm::IsPointOnEdge(const Rect &rect, const Point& point) in IsPointOnEdge() argument 150 if ((point.px_ == rect.left_ || point.px_ == rect.right_) in IsPointOnEdge() 151 && point.py_ >= rect.top_ && point.py_ <= rect.bottom_) { in IsPointOnEdge() 154 if ((point.py_ == rect.top_ || point.py_ == rect.bottom_) in IsPointOnEdge() [all …]
|
D | window_operator.cpp | 100 auto rect = window_.bounds_; in CallBar() local 103 Point from(rect.GetCenterX(), rect.top_ + step1); in CallBar() 104 Point to(rect.GetCenterX(), rect.top_ + step2); in CallBar() 115 auto rect = window_.bounds_; in Focus() local 117 Point focus(rect.GetCenterX(), rect.top_ + step); in Focus() 129 auto rect = window_.bounds_; in MoveTo() local 131 Point from(rect.left_ + step, rect.top_ + step); in MoveTo() 263 auto rect = widgets[index - 1]->GetBounds(); in BarAction() local 264 Point widgetCenter(rect.GetCenterX(), rect.GetCenterY()); in BarAction()
|
D | ui_model.cpp | 25 static string Rect2JsonStr(const Rect &rect) in Rect2JsonStr() argument 28 data["left"] = rect.left_; in Rect2JsonStr() 29 data["top"] = rect.top_; in Rect2JsonStr() 30 data["right"] = rect.right_; in Rect2JsonStr() 31 data["bottom"] = rect.bottom_; in Rect2JsonStr() 165 …auto rect = Rect(integers[INDEX_ZERO], integers[INDEX_TWO], integers[INDEX_ONE], integers[INDEX_TH… in SetWidgetBounds() local 166 widget.SetBounds(rect); in SetWidgetBounds() 329 auto rect = root.GetBounds(); in DfsMarshalWidget() local 330 stream << "[" << rect.left_ << "," << rect.top_ << "]" in DfsMarshalWidget() 331 << "[" << rect.right_ << "," << rect.bottom_ << "]"; in DfsMarshalWidget()
|
/test/xts/acts/arkui/ace_ets_component_three/entry/src/main/ets/test/ |
D | TapGesture.test.ets | 51 let rect = await Utils.getComponentRect('tapGesture') 52 console.info("[testTapGesture01] rectInfo is " + JSON.stringify(rect)); 53 let x_value = rect.left + (rect.right - rect.left) / 2; 54 let y_value = rect.top + (rect.bottom - rect.top) / 2; 55 let x_value_two = rect.left + (rect.right - rect.left) / 20; 56 let y_value_two = rect.top + (rect.bottom - rect.top) / 20;
|
D | PriorityGestureJsunit.test.ets | 50 let rect = await Utils.getComponentRect('tapGesture') 51 console.info("priorityGestureTest_0100 rectInfo is " + JSON.stringify(rect)); 52 let x_value = rect.left + (rect.right - rect.left) / 2; 53 let y_value = rect.top + (rect.bottom - rect.top) / 2;
|
D | ParallelGestureJsunit.test.ets | 51 let rect = await Utils.getComponentRect('tapGesture') 52 console.info("parallelGestureTest_0100 rectInfo is " + JSON.stringify(rect)); 53 let x_value = rect.left + (rect.right - rect.left) / 2; 54 let y_value = rect.top + (rect.bottom - rect.top) / 2;
|
D | PanGestureJsunit.test.ets | 75 let rect = await Utils.getComponentRect('PanGesture') 76 console.info("[testPanGesture02] rectInfo is " + JSON.stringify(rect)); 77 x_value = rect.left + (rect.right - rect.left) / 10 78 y_value = rect.top + (rect.bottom - rect.top) / 10
|
D | ResponseRegionJsunit.test.ets | 75 let rect = await Utils.getComponentRect('region') 76 console.info("[testResponseRegion02] rectInfo is " + JSON.stringify(rect)); 77 x_value = rect.left + (rect.right - rect.left) / 10 78 y_value = rect.top + (rect.bottom - rect.top) / 10
|
/test/testfwk/arkxtest/uitest/record/ |
D | find_widget.cpp | 37 Rect rect = widget.GetBounds(); in Matches() local 38 if (x_ <= rect.right_ && x_ >= rect.left_ && y_ <= rect.bottom_ && y_ >= rect.top_) { in Matches()
|
/test/xts/acts/graphic/graphicnapitest/ |
D | NativeWindowTest.cpp | 170 struct Region::Rect * rect = new Region::Rect(); variable 171 rect->x = 0x100; 172 rect->y = 0x100; 173 rect->w = 0x100; 174 rect->h = 0x100; 175 region->rects = rect; 190 struct Region::Rect * rect = new Region::Rect(); variable 191 rect->x = 0x100; 192 rect->y = 0x100; 193 rect->w = 0x100; [all …]
|
D | NativeImageTest.cpp | 331 struct Region::Rect *rect = new Region::Rect(); variable 332 rect->x = 0x100; 333 rect->y = 0x100; 334 rect->w = 0x100; 335 rect->h = 0x100; 336 region->rects = rect; 415 struct Region::Rect *rect = new Region::Rect(); variable 416 rect->x = 0x100; 417 rect->y = 0x100; 418 rect->w = 0x100; [all …]
|
/test/xts/hats/hdf/display/common/ |
D | display_test_utils.cpp | 171 void ClearColorRect(const BufferHandle &handle, uint32_t color, IRect &rect) in ClearColorRect() argument 173 DISPLAY_TEST_LOGI("x %d, y %d w %d h %d color %x ", rect.x, rect.y, rect.w, rect.h, color); in ClearColorRect() 174 for (int32_t x = 0; x < rect.w; x++) { in ClearColorRect() 175 for (int32_t y = 0; y < rect.h; y++) { in ClearColorRect() 176 SetPixel(handle, x + rect.x, y + rect.y, color); in ClearColorRect() 195 IRect rect = { 0, 0, cellWidth, cellHeight }; in SplitBuffer() local 200 rect.x = x * cellWidth; in SplitBuffer() 201 rect.y = y * cellHeight; in SplitBuffer() 202 ClearColorRect(handle, colors[count++], rect); in SplitBuffer() 203 splitRects.push_back(rect); in SplitBuffer()
|
/test/xts/acts/arkui/ace_ets_component_two/entry/src/main/ets/test/ |
D | SourceTypeJsunit.test.ets | 51 let rect = await Utils.getComponentRect('button') 52 console.info("sourceTypeTest_0100 rectInfo is " + JSON.stringify(rect)); 53 let x_value = rect.left + (rect.right - rect.left) / 2 54 let y_value = rect.top + (rect.bottom - rect.top) / 2
|
/test/xts/acts/arkui/ace_ets_component_apilack/entry/src/main/ets/test/ |
D | rect.test.ets | 25 uri: 'pages/rect', 30 console.info("get rect state success " + JSON.stringify(pages)); 31 if (!("rect" == pages.name)) { 32 console.info("get rect state success " + JSON.stringify(pages.name)); 35 console.info("push rect page success " + JSON.stringify(result)); 38 console.error("push rect page error: " + err);
|
/test/xts/acts/arkui/ace_standard/src/main/js/default/pages/tabs/router/ |
D | index.js | 395 var rect = function1.getBoundingClientRect(); 396 var width = rect.width; 397 var height = rect.height; 398 var left = rect.left; 399 var top = rect.top; 410 var rect = function1.getBoundingClientRect(); 411 var width = rect.width; 412 var height = rect.height; 413 var left = rect.left; 414 var top = rect.top; [all …]
|
/test/xts/acts/arkui/ace_ets_component_attrlack/entry/src/main/ets/MainAbility/pages/ |
D | slider.ets | 28 var rect = Utils.getComponentRect("Slider") 29 Utils.drag(rect["left"],rect["top"],rect["right"],rect["bottom"],20)
|
D | refresh.ets | 26 var rect = Utils.getComponentRect("Refresh") 27 Utils.drag(rect["left"],rect["top"],rect["right"],rect["bottom"],20)
|
/test/ostest/wukong/component_event/src/ |
D | scene_delegate.cpp | 324 auto rect = componentinfo->GetPosition(); in IsComponentInScreen() local 325 …if ((rect.GetRightBottomXScreenPostion() <= width) && (rect.GetLeftTopXScreenPostion() <= width) && in IsComponentInScreen() 326 … (rect.GetRightBottomYScreenPostion() <= height) && (rect.GetLeftTopYScreenPostion() <= height) && in IsComponentInScreen() 327 (rect.GetRightBottomXScreenPostion() > 0) && (rect.GetLeftTopXScreenPostion() > 0) && in IsComponentInScreen() 328 (rect.GetRightBottomYScreenPostion() > 0) && (rect.GetLeftTopYScreenPostion() > 0)) { in IsComponentInScreen()
|
/test/xts/acts/arkui/ace_standard/src/main/js/default/pages/obj_ImageBitmap/prop/ |
D | index.js | 33 offscreenCanvasCtx.rect(10, 10, 150, 100); 52 offscreenCanvasCtx.rect(10, 10, 100, 150);
|