]> www.fi.muni.cz Git - evince.git/commitdiff
[libview] Do nothing in size_allocate when document is not yet loaded
authorCarlos Garcia Campos <carlosgc@gnome.org>
Sun, 9 May 2010 14:47:46 +0000 (16:47 +0200)
committerCarlos Garcia Campos <carlosgc@gnome.org>
Mon, 10 May 2010 11:58:47 +0000 (13:58 +0200)
libview/ev-view.c

index 194361f580d065bf27084fa097196591a8270be7..69f4bdd0eb6212ef9e56d23e23be4904b119729b 100644 (file)
@@ -2875,7 +2875,10 @@ ev_view_size_allocate (GtkWidget      *widget,
        gint    root_x, root_y;
 
        GTK_WIDGET_CLASS (ev_view_parent_class)->size_allocate (widget, allocation);
-       
+
+       if (!view->document)
+               return;
+
        if (view->sizing_mode == EV_SIZING_FIT_WIDTH ||
            view->sizing_mode == EV_SIZING_BEST_FIT) {
                GtkRequisition req;