您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ window_set_click_config_provider函数代码示例

51自学网 2021-06-03 09:58:05
  C++
这篇教程C++ window_set_click_config_provider函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中window_set_click_config_provider函数的典型用法代码示例。如果您正苦于以下问题:C++ window_set_click_config_provider函数的具体用法?C++ window_set_click_config_provider怎么用?C++ window_set_click_config_provider使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了window_set_click_config_provider函数的30个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: chrono_start_stop_handler

void chrono_start_stop_handler(ClickRecognizerRef recognizer, Window *window) {  PblTm time;  int seconds;  get_time(&time);  seconds = get_time_seconds(&time);  // The start/stop button was pressed.  if (chrono_running) {    // If the chronograph is currently running, this means to stop (or    // pause).    chrono_hold_seconds = seconds - chrono_start_seconds;    chrono_running = false;    chrono_lap_paused = false;    vibes_enqueue_custom_pattern(tap);    update_hands(&time);    // We change the click config provider according to the chrono run    // state.  When the chrono is stopped, we listen for a different    // set of buttons than when it is started.    window_set_click_config_provider(window, (ClickConfigProvider)stopped_click_config_provider);  } else {    // If the chronograph is not currently running, this means to    // start, from the currently showing Chronograph time.    chrono_start_seconds = seconds - chrono_hold_seconds;    chrono_running = true;    vibes_enqueue_custom_pattern(tap);    update_hands(&time);    window_set_click_config_provider(window, (ClickConfigProvider)started_click_config_provider);  }}
开发者ID:R1chChapp3rs,项目名称:rosewright,代码行数:32,


示例2: chrono_set_click_config

void chrono_set_click_config(struct Window *window) {  if (chrono_data.running) {    window_set_click_config_provider(window, &started_click_config_provider);  } else {    window_set_click_config_provider(window, &stopped_click_config_provider);  }}
开发者ID:Quikrobot,项目名称:rosewright,代码行数:7,


示例3: chrono_digital_window_appear_handler

void chrono_digital_window_appear_handler(struct Window *window) {  app_log(APP_LOG_LEVEL_INFO, __FILE__, __LINE__, "chrono digital appears");  chrono_digital_window_showing = true;  // We never have the lap timer paused while the digital window is visible.  chrono_data.lap_paused = false;  if (chrono_data.running) {    window_set_click_config_provider(chrono_digital_window, &started_click_config_provider);  } else {    window_set_click_config_provider(chrono_digital_window, &stopped_click_config_provider);  }  reset_chrono_digital_timer();}
开发者ID:Quikrobot,项目名称:rosewright,代码行数:15,


示例4: single_code_window_load

static void single_code_window_load(Window *window) {	window_set_click_config_provider(single_code_main_window, (ClickConfigProvider) window_config_provider);		Layer *window_layer = window_get_root_layer(single_code_main_window);	display_bounds = layer_get_frame(window_layer);  Layer *countdown_layer = layer_create(display_bounds);  layer_add_child(window_layer, countdown_layer);	//add_countdown_layer(s_layer);  start_managing_countdown_layer(countdown_layer);		text_label_rect = single_text_label_rect;	GRect text_label_start = text_label_rect;	text_label_start.origin.x = display_bounds.size.w;	text_label_layer = text_layer_create(text_label_start);	text_layer_set_background_color(text_label_layer, GColorClear);	text_layer_set_text_alignment(text_label_layer, single_text_label_alignment);	text_layer_set_overflow_mode(text_label_layer, GTextOverflowModeWordWrap);	text_layer_set_text(text_label_layer, label_text);	layer_add_child(window_layer, text_layer_get_layer(text_label_layer));		text_pin_rect = single_text_pin_rect;	GRect text_pin_start = text_pin_rect;	text_pin_start.origin.x = display_bounds.size.w;	text_pin_layer = text_layer_create(text_pin_start);	text_layer_set_background_color(text_pin_layer, GColorClear);	text_layer_set_text_alignment(text_pin_layer, GTextAlignmentCenter);	text_layer_set_text(text_pin_layer, pin_text);	layer_add_child(window_layer, text_layer_get_layer(text_pin_layer));		apply_display_colors();	set_fonts();	loading_complete = true;}
开发者ID:ardaozkal,项目名称:QuickAuth,代码行数:34,


示例5: main_window_load

//Loads main_windowstatic void main_window_load(Window *window) {  // Here we load the bitmap assets  s_menu_icons[0] = gbitmap_create_with_resource(RESOURCE_ID_VERYGOOD);  s_menu_icons[1] = gbitmap_create_with_resource(RESOURCE_ID_GOOD);  s_menu_icons[2] = gbitmap_create_with_resource(RESOURCE_ID_MED);  s_menu_icons[3] = gbitmap_create_with_resource(RESOURCE_ID_BAD);  s_menu_icons[4] = gbitmap_create_with_resource(RESOURCE_ID_VERYBAD);  s_menu_icons[5] = gbitmap_create_with_resource(RESOURCE_ID_EXAMPLE1);  // Now we prepare to initialize the menu layer  Layer *window_layer = window_get_root_layer(window);  GRect bounds = layer_get_frame(window_layer);  //if user presses BACK, the app exits  window_set_click_config_provider(window, back_click_config_provider);  // Create the menu layer  s_menu_layer = menu_layer_create(bounds);  menu_layer_set_callbacks(s_menu_layer, NULL, (MenuLayerCallbacks){    .get_num_rows = menu_get_num_rows_callback,    .get_header_height = PBL_IF_RECT_ELSE(menu_get_header_height_callback, NULL),    .draw_header = PBL_IF_RECT_ELSE(menu_draw_header_callback, NULL),    .draw_row = menu_draw_row_callback,    .select_click = menu_select_callback,    .get_cell_height = PBL_IF_ROUND_ELSE(get_cell_height_callback, NULL),  });
开发者ID:Peter-Master,项目名称:PebbleHealthNet,代码行数:28,


示例6: onWindowLoad

static void onWindowLoad(Window *window) {    // 配置按键    window_set_click_config_provider(window, clickConfigProvider);    // 窗口信息    Layer *layer = window_get_root_layer(window);    bounds = layer_get_bounds(layer);    // bitmap图层    GRect fromRect = GRect(0, 0, bounds.size.w, bounds.size.h);    GRect toRect = GRect(0, bounds.size.h, bounds.size.w, bounds.size.h);    bitmapLayer = bitmap_layer_create(fromRect);    // bitmap对象    bitmap = gbitmap_create_with_resource(RESOURCE_ID_MY_LOGO);    bitmap_layer_set_compositing_mode(bitmapLayer, GCompOpSet);    bitmap_layer_set_bitmap(bitmapLayer, bitmap);    // logo动画    PropertyAnimation *propAnim = property_animation_create_layer_frame((Layer *)bitmapLayer, &fromRect, &toRect);    Animation *anim = property_animation_get_animation(propAnim);    const int delay_ms = 1000;    const int duration_ms = 3000;    animation_set_curve(anim, AnimationCurveEaseOut);    animation_set_delay(anim, delay_ms);    animation_set_duration(anim, duration_ms);    animation_schedule(anim);    // 添加图层    layer_add_child(window_get_root_layer(window), bitmap_layer_get_layer(bitmapLayer));}
开发者ID:zhengxiaoyao0716,项目名称:PebbleDemo,代码行数:31,


示例7: x01_gui_window_push

void x01_gui_window_push(ClickConfigProvider click_config_provider) {  s_window = window_create();  setup_window();  window_set_click_config_provider(s_window, click_config_provider);  window_set_window_handlers(s_window, (WindowHandlers) {    .unload = handle_window_unload  });
开发者ID:vassdoki,项目名称:pebble-darts-counter,代码行数:7,


示例8: timer_window_load

void timer_window_load(Window *me) {  static char headerText[16];  snprintf(headerText, sizeof(headerText), "Timer %d", curTimer+1);  updateTimerValueText();  text_layer_init(&timerSelectHeader, timerUpdateWindow.layer.frame);  text_layer_set_text_color(&timerSelectHeader, GColorBlack);  text_layer_set_background_color(&timerSelectHeader, GColorClear);  layer_set_frame(&timerSelectHeader.layer, GRect(8, 8, 144-8, 168-68));  text_layer_set_font(&timerSelectHeader, fonts_get_system_font(FONT_KEY_GOTHAM_30_BLACK));  text_layer_set_text(&timerSelectHeader, headerText);  layer_add_child(&timerUpdateWindow.layer, &timerSelectHeader.layer);  text_layer_init(&timerSelectValue, timerUpdateWindow.layer.frame);  text_layer_set_text_color(&timerSelectValue, GColorBlack);  text_layer_set_background_color(&timerSelectValue, GColorClear);  layer_set_frame(&timerSelectValue.layer, GRect(40, 50, 144-8, 168-68));  text_layer_set_font(&timerSelectValue, fonts_get_system_font(FONT_KEY_GOTHAM_42_LIGHT));  text_layer_set_text(&timerSelectValue, timerValueText);  layer_add_child(&timerUpdateWindow.layer, &timerSelectValue.layer);  text_layer_init(&timerSelectFooter, timerUpdateWindow.layer.frame);  text_layer_set_text_color(&timerSelectFooter, GColorBlack);  text_layer_set_background_color(&timerSelectFooter, GColorClear);  layer_set_frame(&timerSelectFooter.layer, GRect(8, 110, 144-8, 168-68));  text_layer_set_font(&timerSelectFooter, fonts_get_system_font(FONT_KEY_GOTHAM_30_BLACK));  text_layer_set_text(&timerSelectFooter, "minutes");  layer_add_child(&timerUpdateWindow.layer, &timerSelectFooter.layer);  window_set_click_config_provider(&timerUpdateWindow, (ClickConfigProvider) timer_click_config_provider);}
开发者ID:elch5655,项目名称:pebble_plane_timer,代码行数:32,


示例9: init_text_layers

static void init_text_layers(void){    // text_layer = text_layer_create(GRect(x,  y, width, height));        // Time Text Layer and Label        base_layer = layer_create (GRect(0, 0, 144, 168));        text_layer = text_layer_create(GRect(0, 67, 144, 34));    text_layer_set_font(text_layer, fonts_get_system_font(FONT_KEY_GOTHIC_28_BOLD));    text_layer_set_text_alignment(text_layer, GTextAlignmentCenter);    text_layer_set_background_color(text_layer, GColorClear);    text_layer_set_text_color(text_layer, GColorWhite);        // Add Layers to Root Window        layer_add_child(base_layer, text_layer_get_layer(text_layer));        layer_add_child(window_get_root_layer(window), base_layer);        // Set Initial Text Layer Text        text_layer_set_text(text_layer, "hello");        // Set Window Click Config Provider        window_set_click_config_provider(window, (ClickConfigProvider) config_provider);}
开发者ID:jamesmattis,项目名称:Hello,代码行数:28,


示例10: init

static void init() {  s_main_window = window_create();  window_set_click_config_provider(s_main_window, config_provider);  window_set_window_handlers(s_main_window, (WindowHandlers) {    .load = main_window_load,    .unload = main_window_unload,  });
开发者ID:DamiMartinez,项目名称:pebble-sdk-examples,代码行数:7,


示例11: init

static void init(void) {  window = window_create();  window_set_click_config_provider(window, click_config_provider);  window_set_window_handlers(window, (WindowHandlers) {    .load = window_load,    .unload = window_unload,  });
开发者ID:cjwilliams,项目名称:pebble-gbitmap-lib,代码行数:7,


示例12: window_load

static void window_load(Window *window) {  Layer *window_layer = window_get_root_layer(window);  icon_layer = bitmap_layer_create(GRect(12, -5, 120, 120));  layer_add_child(window_layer, bitmap_layer_get_layer(icon_layer));  temperature_layer = text_layer_create(GRect(0, 100, 144, 68));  text_layer_set_text_color(temperature_layer, GColorWhite);  text_layer_set_background_color(temperature_layer, GColorClear);  text_layer_set_font(temperature_layer, fonts_get_system_font(FONT_KEY_BITHAM_42_LIGHT));  text_layer_set_text_alignment(temperature_layer, GTextAlignmentCenter);  text_layer_set_text(temperature_layer, temperature);  Tuplet initial_values[] = {    TupletInteger(WEATHER_ICON_KEY, (uint8_t) 0),    TupletCString(WEATHER_TEMPERATURE_KEY, "70/u00B0F"),    TupletCString(WEATHER_REALFEEL_KEY, "70/u00B0F"),  };      app_sync_init(&sync, sync_buffer, sizeof(sync_buffer), initial_values, ARRAY_LENGTH(initial_values),      sync_tuple_changed_callback, sync_error_callback, NULL);    window_set_click_config_provider(window, (ClickConfigProvider) config_provider);  layer_add_child(window_layer, text_layer_get_layer(temperature_layer));}
开发者ID:sridvijay,项目名称:ForecasterForPebble,代码行数:26,


示例13: prv_init

//Initialise Windowsstatic void prv_init(void) {  s_window = window_create();  window_set_click_config_provider(s_window, prv_click_config_provider);  window_set_window_handlers(s_window, (WindowHandlers) {    .load = prv_window_load,    .unload = prv_window_unload,  });
开发者ID:CIA-hideout,项目名称:centinel-pebble,代码行数:8,


示例14: handle_init

void handle_init(AppContextRef ctx) {	(void)ctx;		app_ctx = ctx;	window_init(&window, "Vibe");	window_stack_push(&window, true /* Animated */);    	power = 3;	on = false;		resource_init_current_app(&APP_RESOURCES);		layer_init(&controls_layer, GRect(124, 3, 20, 146));	controls_layer.update_proc = &controls_update_callback;	layer_add_child(&window.layer, &controls_layer);		layer_init(&bars_layer, GRect(22, 22, 85, 115));	bars_layer.update_proc = &bars_update_callback;	layer_add_child(&window.layer, &bars_layer);		bmp_init_container(RESOURCE_ID_IMAGE_CONTROLS, &controls);	bmp_init_container(RESOURCE_ID_IMAGE_BAR_ON,   &bar_on);	bmp_init_container(RESOURCE_ID_IMAGE_BAR_OFF,  &bar_off);		window_set_click_config_provider(&window, (ClickConfigProvider) click_config_provider);}
开发者ID:fuzzie360,项目名称:pebble-vibe,代码行数:27,


示例15: init

static void init(void) {	// Initialize Pebble Autoconfig to register App Message handlers and restores settings	autoconfig_init();	// Here the restored or defaulted settings are available	logSettings("restored");	// Register our custom receive handler which in turn will call Pebble Autoconfigs receive handler	app_message_register_inbox_received(in_received_handler);		window = window_create();	Layer *window_layer = window_get_root_layer(window);	GRect bounds = layer_get_frame(window_layer);	for (int i = 0; i < SETTING_COUNT; ++i) {		layer[i] = text_layer_create(GRect(10, 10 + i*35, bounds.size.w - 10, 28));		layer_add_child(window_layer, text_layer_get_layer(layer[i]));	}	updateDisplay();	// Attach our desired button functionality	window_set_click_config_provider(window, (ClickConfigProvider) click_config_provider);	window_stack_push(window, true);}
开发者ID:kevincon,项目名称:pebble-autoconfig,代码行数:26,


示例16: init

static void init() {  srand(time(NULL));  lightup();  // Create maze  mazeWidth = 18;  mazeHeight = 19;  corridorSize = 8;  maze = genmaze(mazeWidth, mazeHeight);    // Init Accelerometer  accel_data_service_subscribe(10, NULL);  accel_service_set_sampling_rate(ACCEL_SAMPLING_10HZ);    // Init Player Position  playerX = 0;  playerY = 0;     // Create main Window  s_main_window = window_create();  window_set_click_config_provider(s_main_window,clickprovider);  window_set_window_handlers(s_main_window, (WindowHandlers) {    .load = main_window_load,    .unload = main_window_unload  });
开发者ID:Zerthick,项目名称:PebbleMaze,代码行数:25,


示例17: handle_init

void handle_init(void) {  my_window = window_create();//  text_layer = text_layer_create(GRect(0, 0, 144, 20));  // Create time TextLayer  s_time_layer = text_layer_create(GRect(0, 55, 144, 50));  text_layer_set_background_color(s_time_layer, GColorClear);  text_layer_set_text_color(s_time_layer, GColorBlack);  text_layer_set_text(s_time_layer, "00:00");  // Improve the layout to be more like a watchface  text_layer_set_font(s_time_layer, fonts_get_system_font(FONT_KEY_BITHAM_42_BOLD));  text_layer_set_text_alignment(s_time_layer, GTextAlignmentCenter);  // Add it as a child layer to the Window's root layer  layer_add_child(window_get_root_layer(my_window), text_layer_get_layer(s_time_layer));  tick_timer_service_subscribe(MINUTE_UNIT, tick_handler);  update_time();  window_set_click_config_provider(my_window, config_provider);  app_message_register_inbox_received(in_received_handler);   app_message_register_inbox_dropped(in_dropped_handler);   app_message_register_outbox_sent(out_sent_handler);   app_message_register_outbox_failed(out_failed_handler);const uint32_t inbound_size = 64;   const uint32_t outbound_size = 64;   app_message_open(inbound_size, outbound_size);  window_stack_push(my_window, true);}
开发者ID:jwiggers,项目名称:PVPebble,代码行数:28,


示例18: handle_init

void handle_init(void) {	  //This is just some "Hello, World" stuff:	  static char* hello_text;	  //hello_text = "Hello, 22";	  int percentage = battery_state_service_peek().charge_percent;	  snprintf (hello_text, 10, "Hello. %d", percentage);	  my_window = window_create();	  Layer *window_layer = window_get_root_layer(my_window);	  GRect window_frame = layer_get_bounds(window_layer);	  text_layer = text_layer_create(GRect(0, 0, 144, 20));	  text_layer_set_text(text_layer, hello_text);	  layer_add_child(window_layer, text_layer_get_layer(text_layer));	      //This is the layer with the bluetooth connection status:	  int status_x = window_frame.size.w - 12;	  int status_y = 0;	  //status_layer = create_status_layer(window_frame);	  status_layer = create_status_layer(status_x, status_y, PHONE_STATUS_BLACK);	  layer_add_child(window_layer, bitmap_layer_get_layer(status_layer));		  //This is the layer with the battery status:	  GRect battery_bar_rect = GRect(0,0,10,100);	  int battery_bar_shape = BATTERY_BAR_VERTICAL;	  battery_layer = create_battery_layer(battery_bar_rect, battery_bar_shape);	  layer_add_child(window_layer, inverter_layer_get_layer(battery_layer));		  //This is some testing on how to move and resize things:	  window_set_click_config_provider(my_window, my_click_handler);		  //Finally, display the window:	  window_stack_push(my_window, true);}
开发者ID:RealGarethEvans,项目名称:pebble_status_indicators,代码行数:32,


示例19: window_load

static void window_load(Window *window) {  Layer *window_layer = window_get_root_layer(window);  GRect bounds = layer_get_bounds(window_layer);    window_set_click_config_provider(window, main_click_config_provider);  s_center = grect_center_point(&bounds);  s_main_layer = layer_create(bounds);  layer_add_child(window_layer, s_main_layer);    // left time label  s_left_time_label = text_layer_create(GRect(46, 102, 110, 40));  text_layer_set_background_color(s_left_time_label, GColorClear);  if(persist_read_int(MODE_REST)) {    text_layer_set_text_color(s_left_time_label, REST_COLOR);  } else {    text_layer_set_text_color(s_left_time_label, CONCENTRATION_COLOR);  }  text_layer_set_font(s_left_time_label, fonts_get_system_font(FONT_KEY_BITHAM_34_MEDIUM_NUMBERS));  layer_add_child(window_layer, text_layer_get_layer(s_left_time_label));  layer_set_update_proc(s_main_layer, update_main_proc);    // fire timer  app_timer_register(0, count_timer_handler, NULL);}
开发者ID:jojonki,项目名称:pomodoro,代码行数:27,


示例20: help_window_push

void help_window_push() {  if(!help_window) {    help_window = window_create();    window_set_click_config_provider(help_window, help_click_config_provider);    window_set_window_handlers(help_window, (WindowHandlers) {      .load = help_window_load,      .unload = help_window_unload    });
开发者ID:HipsterBrown,项目名称:Slate,代码行数:8,


示例21: main_window_push

void main_window_push() {  if(!s_window) {    s_window = window_create();    window_set_click_config_provider(s_window, click_config_provider);    window_set_window_handlers(s_window, (WindowHandlers) {      .load = window_load,      .unload = window_unload,    });
开发者ID:sprateek,项目名称:lazy-sloth,代码行数:8,


示例22: init

static void init() {  app_message_open(512, 512);  s_main_window = window_create();  window_set_click_config_provider(s_main_window, click_config_provider);  window_set_window_handlers(s_main_window, (WindowHandlers) {    .load = window_load,    .unload = window_unload,  });
开发者ID:yinghuayang,项目名称:Alang,代码行数:8,


示例23: post_init_hook

/* * Stuff we only allow after we've gone through the normal pre-amble */EXTFN void post_init_hook(void *data) {  wakeup_init();  ui.animation_count = 6; // Make it 6 so we consider is_animation_complete() will return true  layer_mark_dirty(ui.icon_bar);   // Set click provider  window_set_click_config_provider(ui.primary_window, (ClickConfigProvider) click_config_provider);}
开发者ID:JamesFowler42,项目名称:morpheuz20,代码行数:11,


示例24: win_vibrate_init

void win_vibrate_init(void) {  window = window_create();  window_set_background_color(window, GColorBlack);  window_set_click_config_provider(window, (ClickConfigProvider)click_config_provider);  window_set_window_handlers(window, (WindowHandlers) {    .appear = window_appear,    .disappear = window_disappear  });
开发者ID:angkec,项目名称:multi-timer,代码行数:8,


示例25: InitializeBattleExitConfirmationWindow

void InitializeBattleExitConfirmationWindow(void){	InitializeConfirmationWindow(&battleExitWindow, &exitText, &yesText, &noText);	battleExitWindow.window_handlers.unload = BattleExitConfirmationDeinit;	window_set_click_config_provider(&battleExitWindow, (ClickConfigProvider) BattleExitWindowClickConfigProvider);		BattleInit();	ShowMainBattleMenu();}
开发者ID:mla133,项目名称:PebbGame,代码行数:9,


示例26: init

static void init() {  app_message_open(512, 512);  app_message_register_inbox_received(inbox_received_callback);  s_main_window = window_create();  window_set_click_config_provider(s_main_window, click_config_provider);  window_set_window_handlers(s_main_window, (WindowHandlers) {    .load = window_load,    .unload = window_unload,  });
开发者ID:SahaSG552,项目名称:PebbleDicT,代码行数:9,


示例27: load

//loadingstatic void load(Window* window) {      previous_question = -1;  Layer *window_layer = window_get_root_layer(ui.window);  GRect window_bounds = layer_get_bounds(window_layer);  #ifdef PBL_COLOR    layer_set_update_proc(window_layer, bg_update_proc);  #endif  // init text layers  for(int i=0; i < 3; i++) {    GRect answerBounds = GRect(144 - 34, 84 - 58 + i * 49, 30, 18);    ui.romajiAnswer[i] = text_layer_create(answerBounds);        text_layer_set_text_alignment(ui.romajiAnswer[i], GTextAlignmentRight);    text_layer_set_font(ui.romajiAnswer[i], fonts_get_system_font(FONT_KEY_GOTHIC_18));    text_layer_set_text(ui.romajiAnswer[i], "");    #ifdef PBL_COLOR      text_layer_set_background_color(ui.romajiAnswer[i], GColorClear);      text_layer_set_text_color(ui.romajiAnswer[i], SEC_FG_COLOR);    #endif  }  for(int i=0; i < 3; i++)     ui.bitmaps[i] = NULL;  GRect statsBounds = GRect(0, 0, 144, 18);  ui.stats = text_layer_create(statsBounds);  text_layer_set_text_alignment(ui.stats, GTextAlignmentCenter);  text_layer_set_font(ui.stats, fonts_get_system_font(FONT_KEY_GOTHIC_18));  #ifdef PBL_COLOR    text_layer_set_background_color(ui.stats, GColorClear);    text_layer_set_text_color(ui.stats, SEC_FG_COLOR);  #endif  total_question_num = 0;  correct_anserted_questions = 0;  update_stats_disp();  // init icons  GRect icon_rect = GRect(0, 0, window_bounds.size.w, window_bounds.size.h);  grect_align(&icon_rect, &window_bounds, GAlignCenter, false);  ui.glyph_layer = layer_create(icon_rect);  layer_set_update_proc(ui.glyph_layer, glyph_layer_update_proc);  layer_set_clips(ui.glyph_layer, true);  // init layers  layer_add_child(window_layer, ui.glyph_layer);    layer_add_child(window_layer, text_layer_get_layer(ui.stats));  for(int i=0; i<3; i++)     layer_add_child(window_layer, text_layer_get_layer(ui.romajiAnswer[i]));   window_set_click_config_provider(ui.window, (ClickConfigProvider) config_provider);  load_new_question();}
开发者ID:bcaller,项目名称:PebbleKana,代码行数:58,


示例28: game_init

void game_init(void) {    game_window = window_create();    window_set_click_config_provider(game_window, click_config_provider);    window_set_window_handlers(game_window, (WindowHandlers) {        .load = window_load,        .unload = window_unload,        .appear = window_appear,        .disappear = window_disappear    });
开发者ID:phmagic,项目名称:snakey,代码行数:9,


示例29: init

static void init(void) {  app_message_init();  data_image = malloc(sizeof(uint8_t) * (5 * 4) * 168 + 12);  window = window_create();  window_set_click_config_provider(window, click_config_provider);  window_set_window_handlers(window, (WindowHandlers) {    .load = window_load,    .unload = window_unload,  });
开发者ID:PayFace,项目名称:PebbleApp,代码行数:9,


示例30: init

void init(void) {	window = window_create();	window_set_click_config_provider(window, click_config_provider);	window_set_background_color(window, GColorWhite);	window_set_fullscreen(window, true);	window_set_window_handlers(window, (WindowHandlers) {		.load = window_load,		.unload = window_unload	}); 
开发者ID:skybolt,项目名称:pebble_f1_2014,代码行数:9,



注:本文中的window_set_click_config_provider函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


C++ window_set_fullscreen函数代码示例
C++ window_set_background_color函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。