Beispiel #1
0
static void nk_menu_context_reset(void *data)
{
   char iconpath[PATH_MAX_LENGTH] = {0};
   nk_menu_handle_t *nk              = (nk_menu_handle_t*)data;
   settings_t *settings           = config_get_ptr();
   unsigned width, height = 0;

   video_driver_get_size(&width, &height);

   if (!nk || !settings)
      return;

   fill_pathname_join(iconpath, settings->directory.assets,
         "nuklear", sizeof(iconpath));
   fill_pathname_slash(iconpath, sizeof(iconpath));

   nk_menu_layout(nk);
   nk_menu_init_device(nk);

   wimp_context_bg_destroy(nk);
   nk_menu_context_reset_textures(nk, iconpath);

   task_push_image_load(settings->path.menu_wallpaper, "cb_menu_wallpaper",
         menu_display_handle_wallpaper_upload, NULL);
}
Beispiel #2
0
static void zrmenu_context_reset(void *data)
{
   char iconpath[PATH_MAX_LENGTH] = {0};
   zrmenu_handle_t *zr              = (zrmenu_handle_t*)data;
   settings_t *settings           = config_get_ptr();
   unsigned width, height = 0;

   video_driver_get_size(&width, &height);

   if (!zr || !settings)
      return;

   fill_pathname_join(iconpath, settings->assets_directory,
         "zahnrad", sizeof(iconpath));
   fill_pathname_slash(iconpath, sizeof(iconpath));

   zrmenu_layout(zr);
   zrmenu_init_device(zr);

   wimp_context_bg_destroy(zr);
   zrmenu_context_reset_textures(zr, iconpath);

   rarch_task_push_image_load(settings->menu.wallpaper, "cb_menu_wallpaper",
         menu_display_handle_wallpaper_upload, NULL);
}
Beispiel #3
0
static void nk_menu_context_destroy(void *data)
{
   unsigned i;
   nk_menu_handle_t *nk   = (nk_menu_handle_t*)data;

   if (!nk)
      return;

   for (i = 0; i < NK_TEXTURE_LAST; i++)
      video_driver_texture_unload((uintptr_t*)&nk->textures.list[i]);

   menu_display_font_main_deinit();
   wimp_context_bg_destroy(nk);
}
Beispiel #4
0
static void zrmenu_context_destroy(void *data)
{
   unsigned i;
   zrmenu_handle_t *zr   = (zrmenu_handle_t*)data;

   if (!zr)
      return;

   for (i = 0; i < ZR_TEXTURE_LAST; i++)
      video_driver_texture_unload((uintptr_t*)&zr->textures.list[i]);

   menu_display_ctl(MENU_DISPLAY_CTL_FONT_MAIN_DEINIT, NULL);

   wimp_context_bg_destroy(zr);
}