@@ -6,24 +6,24 @@ Label::Label(uint8_t screenID, uint8_t numScreens, Pinetime::Applications::Displ
66 : Screen(app), labelText {labelText} {
77
88 if (numScreens > 1 ) {
9- pageIndicatorBasePoints[0 ].x = 240 - 1 ;
10- pageIndicatorBasePoints[0 ].y = 6 ;
11- pageIndicatorBasePoints[1 ].x = 240 - 1 ;
12- pageIndicatorBasePoints[1 ].y = 240 - 6 ;
9+ pageIndicatorBasePoints[0 ].x = LV_HOR_RES - 1 ;
10+ pageIndicatorBasePoints[0 ].y = 0 ;
11+ pageIndicatorBasePoints[1 ].x = LV_HOR_RES - 1 ;
12+ pageIndicatorBasePoints[1 ].y = LV_VER_RES ;
1313
1414 pageIndicatorBase = lv_line_create (lv_scr_act (), NULL );
1515 lv_obj_set_style_local_line_width (pageIndicatorBase, LV_LINE_PART_MAIN, LV_STATE_DEFAULT, 3 );
1616 lv_obj_set_style_local_line_color (pageIndicatorBase, LV_LINE_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex (0x111111 ));
1717 lv_obj_set_style_local_line_rounded (pageIndicatorBase, LV_LINE_PART_MAIN, LV_STATE_DEFAULT, true );
1818 lv_line_set_points (pageIndicatorBase, pageIndicatorBasePoints, 2 );
1919
20- uint16_t indicatorSize = 228 / numScreens;
20+ uint16_t indicatorSize = LV_VER_RES / numScreens;
2121 uint16_t indicatorPos = indicatorSize * screenID;
2222
23- pageIndicatorPoints[0 ].x = 240 - 1 ;
24- pageIndicatorPoints[0 ].y = ( 6 + indicatorPos) ;
25- pageIndicatorPoints[1 ].x = 240 - 1 ;
26- pageIndicatorPoints[1 ].y = ( 6 + indicatorPos) + indicatorSize;
23+ pageIndicatorPoints[0 ].x = LV_HOR_RES - 1 ;
24+ pageIndicatorPoints[0 ].y = indicatorPos;
25+ pageIndicatorPoints[1 ].x = LV_HOR_RES - 1 ;
26+ pageIndicatorPoints[1 ].y = indicatorPos + indicatorSize;
2727
2828 pageIndicator = lv_line_create (lv_scr_act (), NULL );
2929 lv_obj_set_style_local_line_width (pageIndicator, LV_LINE_PART_MAIN, LV_STATE_DEFAULT, 3 );
0 commit comments