]> www.fi.muni.cz Git - evince.git/blobdiff - shell/ev-window.c
[shell] Remove unused variable and code
[evince.git] / shell / ev-window.c
index 030a86dd27dfdb98e90db15b8b16018abba8186f..d4057b115bc97b05451917f10b254ff21db7b858 100644 (file)
@@ -223,13 +223,12 @@ struct _EvWindowPrivate {
 #define NAVIGATION_ACTION      "Navigation"
 
 #define GCONF_LOCKDOWN_DIR          "/desktop/gnome/lockdown"
-#define GCONF_OVERRIDE_RESTRICTIONS "/apps/evince/override_restrictions"
 #define GCONF_LOCKDOWN_SAVE         "/desktop/gnome/lockdown/disable_save_to_disk"
 #define GCONF_LOCKDOWN_PRINT        "/desktop/gnome/lockdown/disable_printing"
 #define GCONF_LOCKDOWN_PRINT_SETUP  "/desktop/gnome/lockdown/disable_print_setup"
 
 #define GS_SCHEMA_NAME           "org.gnome.Evince"
-#define GS_OVERRIDE_RESTRICTIONS "override_restrictions"
+#define GS_OVERRIDE_RESTRICTIONS "override-restrictions"
 
 #define SIDEBAR_DEFAULT_SIZE    132
 #define LINKS_SIDEBAR_ID "links"
@@ -358,7 +357,6 @@ ev_window_setup_action_sensitivity (EvWindow *ev_window)
        const EvDocumentInfo *info = NULL;
        gboolean has_document = FALSE;
        gboolean ok_to_print = TRUE;
-       gboolean ok_to_print_setup = TRUE;
        gboolean ok_to_copy = TRUE;
        gboolean has_properties = TRUE;
        gboolean override_restrictions = TRUE;
@@ -408,11 +406,6 @@ ev_window_setup_action_sensitivity (EvWindow *ev_window)
            gconf_client_get_bool (ev_window->priv->gconf_client, GCONF_LOCKDOWN_PRINT, NULL)) {
                ok_to_print = FALSE;
        }
-
-       if (has_document &&
-           gconf_client_get_bool (ev_window->priv->gconf_client, GCONF_LOCKDOWN_PRINT_SETUP, NULL)) {
-               ok_to_print_setup = FALSE;
-       }
 #endif
 
        /* File menu */
@@ -1090,7 +1083,7 @@ setup_document_from_metadata (EvWindow *window)
                screen = gtk_window_get_screen (GTK_WINDOW (window));
                if (screen) {
                        request_width = MIN (request_width, gdk_screen_get_width (screen));
-                       request_height = MIN (request_width, gdk_screen_get_height (screen));
+                       request_height = MIN (request_height, gdk_screen_get_height (screen));
                }
 
                if (request_width > 0 && request_height > 0) {
@@ -4874,6 +4867,7 @@ ev_window_dispose (GObject *object)
        }
 
        if (priv->last_settings) {
+               g_settings_apply (priv->last_settings);
                g_object_unref (priv->last_settings);
                priv->last_settings = NULL;
        }
@@ -6460,6 +6454,7 @@ ev_window_init (EvWindow *ev_window)
        gtk_widget_grab_focus (ev_window->priv->view);
 
        ev_window->priv->last_settings = g_settings_new (GS_SCHEMA_NAME".Default");
+       g_settings_delay (ev_window->priv->last_settings);
 
        /* Set it user interface params */
        ev_window_setup_recent (ev_window);