Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/shell
diff options
context:
space:
mode:
Diffstat (limited to 'shell')
-rw-r--r--shell/ev-sidebar-links.c2
-rw-r--r--shell/ev-sidebar-thumbnails.c13
-rw-r--r--shell/ev-view.c4
-rw-r--r--shell/ev-window.c5
4 files changed, 18 insertions, 6 deletions
diff --git a/shell/ev-sidebar-links.c b/shell/ev-sidebar-links.c
index 14b4b00..6573f80 100644
--- a/shell/ev-sidebar-links.c
+++ b/shell/ev-sidebar-links.c
@@ -228,7 +228,7 @@ create_loading_model (void)
/* Creates a fake model to indicate that we're loading */
retval = (GtkTreeModel *)gtk_list_store_new (EV_DOCUMENT_LINKS_COLUMN_NUM_COLUMNS,
G_TYPE_STRING,
- G_TYPE_OBJECT,
+ G_TYPE_POINTER,
G_TYPE_BOOLEAN);
gtk_list_store_append (GTK_LIST_STORE (retval), &iter);
diff --git a/shell/ev-sidebar-thumbnails.c b/shell/ev-sidebar-thumbnails.c
index 93f4150..c2c07c8 100644
--- a/shell/ev-sidebar-thumbnails.c
+++ b/shell/ev-sidebar-thumbnails.c
@@ -101,9 +101,16 @@ ev_sidebar_thumbnails_dispose (GObject *object)
EvSidebarThumbnails *sidebar_thumbnails = EV_SIDEBAR_THUMBNAILS (object);
ev_sidebar_thumbnails_clear_model (sidebar_thumbnails);
- g_object_unref (sidebar_thumbnails->priv->loading_icon);
- g_object_unref (sidebar_thumbnails->priv->list_store);
-
+ if (sidebar_thumbnails->priv->loading_icon) {
+ g_object_unref (sidebar_thumbnails->priv->loading_icon);
+ sidebar_thumbnails->priv->loading_icon = NULL;
+ }
+
+ if (sidebar_thumbnails->priv->list_store) {
+ g_object_unref (sidebar_thumbnails->priv->list_store);
+ sidebar_thumbnails->priv->list_store = NULL;
+ }
+
G_OBJECT_CLASS (ev_sidebar_thumbnails_parent_class)->dispose (object);
}
diff --git a/shell/ev-view.c b/shell/ev-view.c
index c366b04..5cc6f57 100644
--- a/shell/ev-view.c
+++ b/shell/ev-view.c
@@ -1931,6 +1931,8 @@ ev_view_set_document (EvView *view,
g_return_if_fail (EV_IS_VIEW (view));
if (document != view->document) {
+ clear_caches (view);
+
if (view->document) {
g_signal_handlers_disconnect_by_func (view->document,
find_changed_cb,
@@ -1940,8 +1942,6 @@ ev_view_set_document (EvView *view,
}
- clear_caches (view);
-
view->document = document;
view->find_page = 0;
view->find_result = 0;
diff --git a/shell/ev-window.c b/shell/ev-window.c
index 10bdb9c..509ac25 100644
--- a/shell/ev-window.c
+++ b/shell/ev-window.c
@@ -2409,6 +2409,11 @@ ev_window_dispose (GObject *object)
priv->toolbar_file = NULL;
}
+ if (priv->recent_model) {
+ g_object_unref (priv->recent_model);
+ priv->recent_model = NULL;
+ }
+
if (priv->ui_manager) {
g_object_unref (priv->ui_manager);
priv->ui_manager = NULL;