@@ -68,8 +68,6 @@ static Window* s_window;
6868static Layer * s_layer_count ;
6969static Layer * s_layer_name ;
7070static Layer * s_layer_dots ;
71- static Layer * s_indicator_up_layer ;
72- static Layer * s_indicator_down_layer ;
7371static AppInfo * s_app_info ;
7472static uint8_t s_app_position = 0 ;
7573static uint8_t s_app_position_new = 0 ;
@@ -85,8 +83,13 @@ static uint16_t s_name_offset = 0;
8583static uint8_t s_animation_direction ;
8684static uint16_t s_dot_current_x = 0 ;
8785static GSize s_window_size ;
86+
87+ #ifdef PBL_SDK_3
88+ static Layer * s_indicator_up_layer ;
89+ static Layer * s_indicator_down_layer ;
8890static ContentIndicator * s_indicator_up ;
8991static ContentIndicator * s_indicator_down ;
92+ #endif
9093
9194void win_main_init (void ) {
9295 s_window = window_create ();
@@ -139,10 +142,12 @@ static void window_load(Window* window) {
139142 layer_set_update_proc (s_layer_count , layer_update_count );
140143 layer_add_to_window (s_layer_count , window );
141144
142- s_layer_dots = layer_create (GRect (0 , 120 , s_window_size .w , 12 ));
145+ s_layer_dots = layer_create (GRect (0 , 130 , s_window_size .w , 12 ));
143146 layer_set_update_proc (s_layer_dots , layer_update_dots );
144147 layer_add_to_window (s_layer_dots , window );
145148
149+ #ifdef PBL_SDK_3
150+
146151 s_indicator_up_layer = layer_create (GRect (0 , 0 ,
147152 s_window_size .w , STATUS_BAR_LAYER_HEIGHT ));
148153 s_indicator_down_layer = layer_create (GRect (0 , s_window_size .h - STATUS_BAR_LAYER_HEIGHT ,
@@ -178,6 +183,7 @@ static void window_load(Window* window) {
178183
179184 content_indicator_set_content_available (s_indicator_down , ContentIndicatorDirectionDown , true);
180185 content_indicator_set_content_available (s_indicator_up , ContentIndicatorDirectionUp , false);
186+ #endif
181187}
182188
183189static void window_unload (Window * window ) {
@@ -201,8 +207,10 @@ static void do_transition(void) {
201207 transition_animation_implementation .update = transition_animation_update ;
202208 transition_animation_run (ANIMATION_DURATION , 0 , & transition_animation_implementation , true);
203209
210+ #ifdef PBL_SDK_3
204211 content_indicator_set_content_available (s_indicator_down , ContentIndicatorDirectionDown , s_app_position < (app_info_count - 1 ));
205212 content_indicator_set_content_available (s_indicator_up , ContentIndicatorDirectionUp , s_app_position > 0 );
213+ #endif
206214}
207215
208216static void up_click_handler (ClickRecognizerRef recognizer , void * context ) {
0 commit comments