diff --git a/panels/background/cc-background-panel.c b/panels/background/cc-background-panel.c index fe44f227d..926239dbc 100644 --- a/panels/background/cc-background-panel.c +++ b/panels/background/cc-background-panel.c @@ -203,17 +203,15 @@ set_background (CcBackgroundPanel *panel, static void -on_chooser_background_chosen_cb (CcBackgroundChooser *chooser, - CcBackgroundItem *item, - CcBackgroundPanel *self) +on_chooser_background_chosen_cb (CcBackgroundPanel *self, + CcBackgroundItem *item) { set_background (self, self->settings, item); set_background (self, self->lock_settings, item); } static void -on_add_picture_button_clicked_cb (GtkWidget *button, - CcBackgroundPanel *self) +on_add_picture_button_clicked_cb (CcBackgroundPanel *self) { cc_background_chooser_select_file (self->background_chooser); } diff --git a/panels/background/cc-background-panel.ui b/panels/background/cc-background-panel.ui index 946974b78..e418d1ae0 100644 --- a/panels/background/cc-background-panel.ui +++ b/panels/background/cc-background-panel.ui @@ -42,7 +42,7 @@ True False True - + @@ -53,6 +53,6 @@ True Add Picture… - + diff --git a/panels/background/cc-background-preview.c b/panels/background/cc-background-preview.c index 1f2e682a0..fa2bc90f8 100644 --- a/panels/background/cc-background-preview.c +++ b/panels/background/cc-background-preview.c @@ -151,9 +151,8 @@ stop_monitor_time (CcBackgroundPreview *self) /* Callbacks */ static gboolean -on_preview_draw_cb (GtkWidget *widget, - cairo_t *cr, - CcBackgroundPreview *self) +on_preview_draw_cb (CcBackgroundPreview *self, + cairo_t *cr) { g_autoptr(GdkPixbuf) pixbuf = NULL; GtkAllocation allocation; @@ -162,8 +161,8 @@ on_preview_draw_cb (GtkWidget *widget, if (!self->item) return FALSE; - scale_factor = gtk_widget_get_scale_factor (widget); - gtk_widget_get_allocation (widget, &allocation); + scale_factor = gtk_widget_get_scale_factor (self->drawing_area); + gtk_widget_get_allocation (self->drawing_area, &allocation); pixbuf = cc_background_item_get_frame_thumbnail (self->item, self->thumbnail_factory, allocation.width, diff --git a/panels/background/cc-background-preview.ui b/panels/background/cc-background-preview.ui index da1f23943..0906847e1 100644 --- a/panels/background/cc-background-preview.ui +++ b/panels/background/cc-background-preview.ui @@ -22,7 +22,7 @@ True False True - +