X-Git-Url: https://git.street.me.uk/andy/viking.git/blobdiff_plain/9b082b39e38d42b4a7ac775bbb50a75e9d352ff8..c2cf03332f51a9fa992220124635f737399fba91:/src/print-preview.c?ds=inline diff --git a/src/print-preview.c b/src/print-preview.c index f14cad11..0ac7ab62 100644 --- a/src/print-preview.c +++ b/src/print-preview.c @@ -21,8 +21,6 @@ #include -#if GTK_CHECK_VERSION(2,10,0) - #include "print-preview.h" @@ -497,8 +495,10 @@ vik_print_preview_expose_event (GtkWidget *widget, if (preview->pixbuf == NULL) { - gint width = MIN (widget->allocation.width, 1024); - gint height = MIN (widget->allocation.height, 1024); + GtkAllocation allocation; + gtk_widget_get_allocation ( widget, &allocation ); + gint width = MIN (allocation.width, 1024); + gint height = MIN (allocation.height, 1024); preview->pixbuf = get_thumbnail(drawable, width, height); } @@ -588,5 +588,3 @@ print_preview_queue_draw (VikPrintPreview *preview) { gtk_widget_queue_draw (GTK_WIDGET (preview->area)); } - -#endif