Skip to content
Permalink
Browse files

avoid deprecated GtkButton:use-stock

  • Loading branch information...
sc0w committed Feb 23, 2018
1 parent 012d9f8 commit e313685f58549d3b98dc42a10b58f830e5b934e9
Showing with 9 additions and 21 deletions.
  1. +4 −10 libcaja-private/caja-mime-application-chooser.c
  2. +5 −11 src/caja-property-browser.c
@@ -417,11 +417,8 @@ caja_mime_application_chooser_init (CajaMimeApplicationChooser *chooser)
gtk_box_pack_start (GTK_BOX (chooser), box, FALSE, FALSE, 6);
gtk_widget_show (box);

button = GTK_WIDGET (g_object_new (GTK_TYPE_BUTTON,
"label", "gtk-add",
"use-stock", TRUE,
"use-underline", TRUE,
NULL));
button = gtk_button_new_with_mnemonic (_("_Add"));
gtk_button_set_image (GTK_BUTTON (button), gtk_image_new_from_icon_name ("list-add", GTK_ICON_SIZE_BUTTON));

g_signal_connect (button, "clicked",
G_CALLBACK (add_clicked_cb),
@@ -430,11 +427,8 @@ caja_mime_application_chooser_init (CajaMimeApplicationChooser *chooser)
gtk_widget_show (button);
gtk_container_add (GTK_CONTAINER (box), button);

button = GTK_WIDGET (g_object_new (GTK_TYPE_BUTTON,
"label", "gtk-remove",
"use-stock", TRUE,
"use-underline", TRUE,
NULL));
button = gtk_button_new_with_mnemonic (_("_Remove"));
gtk_button_set_image (GTK_BUTTON (button), gtk_image_new_from_icon_name ("list-remove", GTK_ICON_SIZE_BUTTON));

g_signal_connect (button, "clicked",
G_CALLBACK (remove_clicked_cb),
@@ -387,22 +387,16 @@ caja_property_browser_init (CajaPropertyBrowser *property_browser)
gtk_container_add (GTK_CONTAINER (temp_box), property_browser->details->bottom_box);

/* create the "help" button */
temp_button = GTK_WIDGET (g_object_new (GTK_TYPE_BUTTON,
"label", "gtk-help",
"use-stock", TRUE,
"use-underline", TRUE,
NULL));
temp_button = gtk_button_new_with_mnemonic (_("_Help"));
gtk_button_set_image (GTK_BUTTON (temp_button), gtk_image_new_from_icon_name ("help-browser", GTK_ICON_SIZE_BUTTON));

gtk_widget_show (temp_button);
gtk_box_pack_start (GTK_BOX (property_browser->details->bottom_box), temp_button, FALSE, FALSE, 0);
g_signal_connect_object (temp_button, "clicked", G_CALLBACK (help_button_callback), property_browser, 0);

/* create the "done" button */
temp_button = GTK_WIDGET (g_object_new (GTK_TYPE_BUTTON,
"label", "gtk-close",
"use-stock", TRUE,
"use-underline", TRUE,
NULL));
/* create the "close" button */
temp_button = gtk_button_new_with_mnemonic (_("_Close"));
gtk_button_set_image (GTK_BUTTON (temp_button), gtk_image_new_from_icon_name ("window-close", GTK_ICON_SIZE_BUTTON));

gtk_widget_set_can_default (temp_button, TRUE);

0 comments on commit e313685

Please sign in to comment.
You can’t perform that action at this time.