[gnac/devel] Added properties can_default and has_default to add_button in gnac_file_chooser



commit 240d0a5e12a4d226bc73593452ce939dbc5d03de
Author: Benoît Dupasquier <bdupasqu src gnome org>
Date:   Thu Mar 7 00:31:37 2013 +0100

    Added properties can_default and has_default to add_button in gnac_file_chooser

 data/ui/gnac.xml |    3 ++-
 src/gnac-ui.c    |   14 --------------
 src/gnac-ui.h    |    4 ----
 3 files changed, 2 insertions(+), 19 deletions(-)
---
diff --git a/data/ui/gnac.xml b/data/ui/gnac.xml
index 09dec3b..fc71f99 100644
--- a/data/ui/gnac.xml
+++ b/data/ui/gnac.xml
@@ -454,7 +454,6 @@ Alexandre Roux &lt;alexroux src gnome org&gt;</property>
     <property name="use_preview_label">False</property>
     <property name="preview_widget_active">False</property>
     <signal name="delete-event" handler="gtk_widget_hide_on_delete"/>
-    <signal name="key-press-event" handler="gnac_ui_file_chooser_key_press_event_cb"/>
     <signal name="file-activated" handler="gnac_ui_file_chooser_file_activated_cb"/>
     <signal name="response" handler="gnac_ui_file_chooser_response_cb"/>
     <signal name="destroy" handler="gtk_widget_hide"/>
@@ -514,6 +513,8 @@ Alexandre Roux &lt;alexroux src gnome org&gt;</property>
                 <property name="label">gtk-add</property>
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
+                <property name="can_default">True</property>
+                <property name="has_default">True</property>
                 <property name="receives_default">True</property>
                 <property name="use_stock">True</property>
               </object>
diff --git a/src/gnac-ui.c b/src/gnac-ui.c
index 0a54306..a186760 100644
--- a/src/gnac-ui.c
+++ b/src/gnac-ui.c
@@ -507,20 +507,6 @@ gnac_ui_file_chooser_file_activated_cb(GtkFileChooser *chooser,
 }
 
 
-gboolean
-gnac_ui_file_chooser_key_press_event_cb(GtkWidget   *widget,
-                                        GdkEventKey *event,
-                                        gpointer     user_data)
-{
-  if (gnac_ui_utils_event_is_return_key(event)) {
-    gnac_ui_file_chooser_response_cb(GTK_DIALOG(widget),
-        GTK_RESPONSE_NONE, NULL);
-    return TRUE;
-  }
-  return FALSE;
-}
-
-
 static void
 gnac_ui_new(void)
 {
diff --git a/src/gnac-ui.h b/src/gnac-ui.h
index e5568f7..4dee699 100644
--- a/src/gnac-ui.h
+++ b/src/gnac-ui.h
@@ -78,10 +78,6 @@ void
 gnac_ui_file_chooser_file_activated_cb(GtkFileChooser *chooser,
                                        gpointer        user_data);
 
-gboolean
-gnac_ui_file_chooser_key_press_event_cb(GtkWidget   *widget,
-                                        GdkEventKey *event,
-                                        gpointer     user_data);
 void
 gnac_ui_init(void);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]