mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-01-01 08:44:25 +03:00
Fix close icon size on tabs. Thanks to Christian Dywan (kalikiana).
svn path=/trunk/netsurf/; revision=5534
This commit is contained in:
parent
4e79ee3d07
commit
56f8f275fd
@ -92,6 +92,7 @@ void nsgtk_tab_set_title(struct gui_window *g, const char *title)
|
||||
GtkWidget *nsgtk_tab_label_setup(struct gui_window *window)
|
||||
{
|
||||
GtkWidget *hbox, *label, *button, *close;
|
||||
GtkRcStyle *rcstyle;
|
||||
|
||||
hbox = gtk_hbox_new(FALSE, 2);
|
||||
|
||||
@ -103,13 +104,16 @@ GtkWidget *nsgtk_tab_label_setup(struct gui_window *window)
|
||||
gtk_widget_show(label);
|
||||
|
||||
button = gtk_button_new();
|
||||
close = gtk_image_new_from_stock("gtk-close",
|
||||
GTK_ICON_SIZE_MENU);
|
||||
gtk_container_add(GTK_CONTAINER(button), close);
|
||||
gtk_button_set_focus_on_click(GTK_BUTTON(button), FALSE);
|
||||
gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
|
||||
gtk_widget_set_tooltip_text(button, "Close this tab.");
|
||||
close = gtk_image_new_from_stock("gtk-close", GTK_ICON_SIZE_MENU);
|
||||
gtk_container_add(GTK_CONTAINER(button), close);
|
||||
gtk_button_set_focus_on_click(GTK_BUTTON(button), FALSE);
|
||||
gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
|
||||
gtk_widget_set_tooltip_text(button, "Close this tab.");
|
||||
|
||||
rcstyle = gtk_rc_style_new();
|
||||
rcstyle->xthickness = rcstyle->ythickness = 0;
|
||||
gtk_widget_modify_style(button, rcstyle);
|
||||
g_object_unref(rcstyle);
|
||||
|
||||
g_signal_connect_swapped(button, "clicked",
|
||||
G_CALLBACK(nsgtk_window_destroy_browser), window);
|
||||
|
Loading…
Reference in New Issue
Block a user