forked from AuroraMiddleware/gtk
entry: avoid a mismatched cairo_save/restore
Leftover from GtkIconHelper migration.
This commit is contained in:
parent
5a471fefdb
commit
2bf765ab49
@ -3374,14 +3374,9 @@ draw_icon (GtkWidget *widget,
|
||||
gint x, y, width, height, pix_width, pix_height;
|
||||
GtkStyleContext *context;
|
||||
|
||||
context = gtk_widget_get_style_context (widget);
|
||||
|
||||
if (!icon_info)
|
||||
return;
|
||||
|
||||
cairo_save (cr);
|
||||
gtk_cairo_transform_to_window (cr, widget, icon_info->window);
|
||||
|
||||
width = gdk_window_get_width (icon_info->window);
|
||||
height = gdk_window_get_height (icon_info->window);
|
||||
|
||||
@ -3390,6 +3385,10 @@ draw_icon (GtkWidget *widget,
|
||||
if (width == 1 || height == 1)
|
||||
return;
|
||||
|
||||
cairo_save (cr);
|
||||
gtk_cairo_transform_to_window (cr, widget, icon_info->window);
|
||||
|
||||
context = gtk_widget_get_style_context (widget);
|
||||
gtk_entry_prepare_context_for_icon (entry, context, icon_pos);
|
||||
_gtk_icon_helper_get_size (icon_info->icon_helper, context, &pix_width, &pix_height);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user