From 826131fb75fadb602b375ba29e593d1e0ab3dde8 Mon Sep 17 00:00:00 2001 From: Martin Kretzschmar Date: Fri, 04 Feb 2005 12:15:13 +0000 Subject: (ev_sidebar_thumbnails_select_page): do nothing unless we have a document. Prevents warning from scroll_to_cell. --- (limited to 'shell/ev-sidebar-thumbnails.c') diff --git a/shell/ev-sidebar-thumbnails.c b/shell/ev-sidebar-thumbnails.c index 2d71539..382a5a9 100644 --- a/shell/ev-sidebar-thumbnails.c +++ b/shell/ev-sidebar-thumbnails.c @@ -312,6 +312,10 @@ ev_sidebar_thumbnails_select_page (EvSidebarThumbnails *sidebar, GtkTreePath *path; GtkTreeSelection *selection; + /* if the EvSidebar's document can't provide thumbnails */ + if (sidebar->priv->document == NULL) + return; + path = gtk_tree_path_new_from_indices (page - 1, -1); selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (sidebar->priv->tree_view)); -- cgit v0.9.1