Beispiel #1
0
void handle_deinit(void) {
  tick_timer_service_unsubscribe();

  persist_write_string(MESSAGE_KEY_DATE_FORMAT_KEY,       PersistDateFormat);
  persist_write_int(MESSAGE_KEY_BT_VIBRATE_KEY,           PersistBTLoss);
  persist_write_int(MESSAGE_KEY_LOW_BATTERY_KEY,          PersistLow_Batt);
  
  battery_state_service_unsubscribe();
  bluetooth_connection_service_unsubscribe();
  app_focus_service_unsubscribe();

  text_layer_destroy(text_time_layer);
  text_layer_destroy(text_date_layer);
  text_layer_destroy(text_dayname_layer);
  text_layer_destroy(text_battery_layer);

  layer_destroy(BatteryLineLayer);
  layer_destroy(BTLayer);

  gbitmap_destroy(image);
  bitmap_layer_destroy(image_layer);

  fonts_unload_custom_font(fontHelvNewLight20);
  fonts_unload_custom_font(fontRobotoBoldSubset40);
  fonts_unload_custom_font(fontRobotoBoldSubset45);


  window_destroy(window);
}
Beispiel #2
0
static void prv_app_did_focus(bool did_focus) {
  if (!did_focus) {
    return;
  }
  app_focus_service_unsubscribe();
  prv_start_intro_animation();
}
Beispiel #3
0
void handle_deinit() 
{
	INFO_LOG("Cleaning up on exit.");
	SavePersistedData();
	UnloadBackgroundImage();
	UnloadMainBmpImage();
	UnloadTextLayers();
	tick_timer_service_unsubscribe();
	app_focus_service_unsubscribe();
#if ALLOW_WORKER_APP
	AppDying(ClosingWhileInBattle());
	app_worker_message_unsubscribe();
#endif
}
Beispiel #4
0
void handle_deinit(void) {
  tick_timer_service_unsubscribe();

  layer_destroy(triangle_overlay_layer);
  layer_destroy(s_hands_layer);
  
  bluetooth_connection_service_unsubscribe();
  battery_state_service_unsubscribe();
  app_focus_service_unsubscribe();
  
  fonts_unload_custom_font(fontRobotoCondensed19);
  
  window_destroy(window);
}
Beispiel #5
0
void handle_deinit(void) {
  tick_timer_service_unsubscribe();
  battery_state_service_unsubscribe();
  bluetooth_connection_service_unsubscribe();
  app_focus_service_unsubscribe();

  text_layer_destroy(text_time_layer);
  text_layer_destroy(text_date_layer);
  text_layer_destroy(text_wa1oui_layer);
  text_layer_destroy(text_dayname_layer);
  text_layer_destroy(text_degrees_layer);
  text_layer_destroy(text_degrees_inside_layer);

  layer_destroy(LineLayer);
  layer_destroy(BTLayer1);

  fonts_unload_custom_font(fontHelvNewLight20);
  fonts_unload_custom_font(fontRobotoCondensed20);
  fonts_unload_custom_font(fontRobotoCondensed21);
  fonts_unload_custom_font(fontRobotoBoldSubset37);
  fonts_unload_custom_font(fontRobotoBoldSubset49);

  window_destroy(window);
}