From: John Darrington Date: Sun, 8 Jul 2007 11:13:54 +0000 (+0000) Subject: Removed visibility from recent file menuitems, if recent managers aren't X-Git-Tag: v0.6.0~401 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f8278f359b743b60a3970e0b65bb3c9e980e0c94;p=pspp-builds.git Removed visibility from recent file menuitems, if recent managers aren't available. --- diff --git a/src/ui/gui/data-editor.c b/src/ui/gui/data-editor.c index 982b6983..fd800de6 100644 --- a/src/ui/gui/data-editor.c +++ b/src/ui/gui/data-editor.c @@ -130,7 +130,6 @@ static void on_recent_data_select (GtkMenuShell *menushell, gpointer user_data) { gchar *file; - struct data_editor *de = user_data; gchar *uri = @@ -254,8 +253,6 @@ new_data_editor (void) G_CALLBACK (insert_variable), de); - - gtk_action_connect_proxy (de->insert_variable, get_widget_assert (de->xml, "button-insert-variable") ); @@ -372,11 +369,16 @@ new_data_editor (void) GtkRecentManager *rm = gtk_recent_manager_get_default (); GtkWidget *recent_data = get_widget_assert (de->xml, "file_recent-data"); GtkWidget *recent_files = get_widget_assert (de->xml, "file_recent-files"); + GtkWidget *recent_separator = get_widget_assert (de->xml, "file_separator1"); GtkWidget *menu = gtk_recent_chooser_menu_new_for_manager (rm); GtkRecentFilter *filter = gtk_recent_filter_new (); + gtk_widget_show (recent_data); + gtk_widget_show (recent_files); + gtk_widget_show (recent_separator); + gtk_recent_filter_add_pattern (filter, "*.sav"); gtk_recent_filter_add_pattern (filter, "*.SAV"); diff --git a/src/ui/gui/data-editor.glade b/src/ui/gui/data-editor.glade index a4dbe644..148219c2 100644 --- a/src/ui/gui/data-editor.glade +++ b/src/ui/gui/data-editor.glade @@ -88,14 +88,14 @@ - - True + + False GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - True + False GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Recently Used Da_ta True @@ -103,7 +103,7 @@ - True + False GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Recently Used _Files True