diff options
author | Vincent Untz <[email protected]> | 2012-02-02 12:22:04 +0100 |
---|---|---|
committer | raveit65 <[email protected]> | 2018-04-26 13:05:22 +0200 |
commit | ff613c4f6a3a33c21cacc885116cacf87ef4bf03 (patch) | |
tree | d175805da384b7ac73d919f6cde0601b0fb338de /applets/wncklet/window-list.c | |
parent | 6b461deac9fb64ff6c92958475497b7050b0bc94 (diff) | |
download | mate-panel-ff613c4f6a3a33c21cacc885116cacf87ef4bf03.tar.bz2 mate-panel-ff613c4f6a3a33c21cacc885116cacf87ef4bf03.tar.xz |
wncklet: Convert to GResource
origin commits:
https://git.gnome.org/browse/gnome-panel/commit/?h=gnome-3-4&id=9fbca7d
https://git.gnome.org/browse/gnome-panel/commit/?h=gnome-3-4&id=695d30c
https://git.gnome.org/browse/gnome-panel/commit/?h=gnome-3-4&id=00f9870
Diffstat (limited to 'applets/wncklet/window-list.c')
-rw-r--r-- | applets/wncklet/window-list.c | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/applets/wncklet/window-list.c b/applets/wncklet/window-list.c index b4c7d123..602f6ecf 100644 --- a/applets/wncklet/window-list.c +++ b/applets/wncklet/window-list.c @@ -372,7 +372,6 @@ gboolean window_list_applet_fill(MatePanelApplet* applet) { TasklistData* tasklist; GtkActionGroup* action_group; - gchar* ui_path; GtkCssProvider *provider; GdkScreen *screen; @@ -468,9 +467,9 @@ gboolean window_list_applet_fill(MatePanelApplet* applet) /* end of system monitor item */ - ui_path = g_build_filename(WNCK_MENU_UI_DIR, "window-list-menu.xml", NULL); - mate_panel_applet_setup_menu_from_file(MATE_PANEL_APPLET(tasklist->applet), ui_path, action_group); - g_free(ui_path); + mate_panel_applet_setup_menu_from_resource (MATE_PANEL_APPLET (tasklist->applet), + WNCKLET_RESOURCE_PATH "window-list-menu.xml", + action_group); if (mate_panel_applet_get_locked_down(MATE_PANEL_APPLET(tasklist->applet))) { @@ -649,20 +648,10 @@ static void display_properties_dialog(GtkAction* action, TasklistData* tasklist) if (tasklist->properties_dialog == NULL) { GtkBuilder* builder; - GError* error; builder = gtk_builder_new(); gtk_builder_set_translation_domain(builder, GETTEXT_PACKAGE); - - error = NULL; - gtk_builder_add_from_file(builder, TASKLIST_BUILDERDIR "/window-list.ui", &error); - - if (error) - { - g_warning("Error loading preferences: %s", error->message); - g_error_free(error); - return; - } + gtk_builder_add_from_resource (builder, WNCKLET_RESOURCE_PATH "window-list.ui", NULL); tasklist->properties_dialog = WID("tasklist_properties_dialog"); |