[gnome-commander] Fixed problem #352024 (F10 key doesn't work)



commit 3e251d056ca74484bfaf05037849d54eebc82349
Author: Thomas Jost <thomas jost gmail com>
Date:   Fri Nov 19 21:01:58 2010 +0100

    Fixed problem #352024 (F10 key doesn't work)
    
    The current behavior is incoherent: F10 should close the window, but it
    currently gives focus to the menu bar (#352024). Since this is the expected
    behavior according to the GNOME HIG, removing the F10 assignment is probably a
    good idea.

 NEWS                                          |    1 +
 doc/C/gnome-commander.xml                     |    8 +++-----
 doc/keys.txt                                  |    1 -
 src/dialogs/gnome-cmd-key-shortcuts-dialog.cc |    2 --
 src/gnome-cmd-main-win.cc                     |   14 --------------
 src/gnome-cmd-user-actions.cc                 |    5 -----
 6 files changed, 4 insertions(+), 27 deletions(-)
---
diff --git a/NEWS b/NEWS
index 1f34e99..1db3d1b 100644
--- a/NEWS
+++ b/NEWS
@@ -33,6 +33,7 @@ gnome-commander 1.2.8.9
 ---------------
 
 Bug fixes:
+ * Fixed problem #352024 (F10 key doesn't work)
  * Fixed problem #631243 (advrename $c(width) regression)
 
 New features:
diff --git a/doc/C/gnome-commander.xml b/doc/C/gnome-commander.xml
index 2d07658..bda02fe 100644
--- a/doc/C/gnome-commander.xml
+++ b/doc/C/gnome-commander.xml
@@ -5388,11 +5388,6 @@
             <entry><para></para></entry>
         </row>
         <row valign="top">
-            <entry><para><keycombo><keycap>F10</keycap></keycombo></para></entry>
-            <entry><para>Quit</para></entry>
-            <entry><para></para></entry>
-        </row>
-        <row valign="top">
             <entry><para></para></entry>
             <entry><para></para></entry>
             <entry><para></para></entry>
@@ -7481,6 +7476,9 @@
                 <para>
                     <itemizedlist>
                         <listitem>
+                            <para>Fixed problem #352024 (F10 key doesn't work)</para>
+                        </listitem>
+                        <listitem>
                             <para>Fixed problem #631243 (advrename $c(width) regression)</para>
                         </listitem>
                     </itemizedlist>
diff --git a/doc/keys.txt b/doc/keys.txt
index d95b430..4090233 100644
--- a/doc/keys.txt
+++ b/doc/keys.txt
@@ -10,7 +10,6 @@ F6              Rename or move files
 F7              Create directory
 F8              Delete files
 F9              Search
-F10             Quit
 
 ALT+1           Change left connection
 ALT+2           Change right connection
diff --git a/src/dialogs/gnome-cmd-key-shortcuts-dialog.cc b/src/dialogs/gnome-cmd-key-shortcuts-dialog.cc
index 8c00a22..a62d1f1 100644
--- a/src/dialogs/gnome-cmd-key-shortcuts-dialog.cc
+++ b/src/dialogs/gnome-cmd-key-shortcuts-dialog.cc
@@ -134,7 +134,6 @@ static void response_callback (GnomeCmdKeyShortcutsDialog *dialog, int response_
                 dialog->user_actions->unregister(GDK_F7);
                 dialog->user_actions->unregister(GDK_F8);
                 dialog->user_actions->unregister(GDK_F9);
-                dialog->user_actions->unregister(GDK_F10);
 
                 dialog->user_actions->register_action(GDK_F3, "file.view");
                 dialog->user_actions->register_action(GDK_F4, "file.edit");
@@ -143,7 +142,6 @@ static void response_callback (GnomeCmdKeyShortcutsDialog *dialog, int response_
                 dialog->user_actions->register_action(GDK_F7, "file.mkdir");
                 dialog->user_actions->register_action(GDK_F8, "file.delete");
                 dialog->user_actions->register_action(GDK_F9, "edit.search");
-                dialog->user_actions->register_action(GDK_F10, "file.exit");
             }
 
             break;
diff --git a/src/gnome-cmd-main-win.cc b/src/gnome-cmd-main-win.cc
index 9ec9af6..fc56309 100644
--- a/src/gnome-cmd-main-win.cc
+++ b/src/gnome-cmd-main-win.cc
@@ -101,7 +101,6 @@ struct GnomeCmdMainWin::Private
     GtkWidget *mkdir_btn;
     GtkWidget *delete_btn;
     GtkWidget *find_btn;
-    GtkWidget *quit_btn;
 
     GtkWidget *menubar;
     GtkWidget *toolbar;
@@ -413,12 +412,6 @@ static void on_search_clicked (GtkButton *button, GnomeCmdMainWin *mw)
 }
 
 
-static void on_quit_clicked (GtkButton *button, GnomeCmdMainWin *mw)
-{
-    file_exit (NULL);
-}
-
-
 void GnomeCmdMainWin::create_buttonbar()
 {
     priv->buttonbar_sep = create_separator (FALSE);
@@ -441,8 +434,6 @@ void GnomeCmdMainWin::create_buttonbar()
     priv->delete_btn = add_buttonbar_button(_("F8 Delete"), this, "delete_btn", priv->accel_group, 0);
     gtk_box_pack_start (GTK_BOX (priv->buttonbar), create_separator (TRUE), FALSE, TRUE, 0);
     priv->find_btn = add_buttonbar_button(_("F9 Search"), this, "find_btn", priv->accel_group, 0);
-    gtk_box_pack_start (GTK_BOX (priv->buttonbar), create_separator (TRUE), FALSE, TRUE, 0);
-    priv->quit_btn = add_buttonbar_button(_("F10 Quit"), this, "quit_btn", priv->accel_group, 0);
 
     g_signal_connect (priv->view_btn, "clicked", G_CALLBACK (on_view_clicked), this);
     g_signal_connect (priv->edit_btn, "clicked", G_CALLBACK (on_edit_clicked), this);
@@ -451,7 +442,6 @@ void GnomeCmdMainWin::create_buttonbar()
     g_signal_connect (priv->mkdir_btn, "clicked", G_CALLBACK (on_mkdir_clicked), this);
     g_signal_connect (priv->delete_btn, "clicked", G_CALLBACK (on_delete_clicked), this);
     g_signal_connect (priv->find_btn, "clicked", G_CALLBACK (on_search_clicked), this);
-    g_signal_connect (priv->quit_btn, "clicked", G_CALLBACK (on_quit_clicked), this);
 }
 
 
@@ -1083,10 +1073,6 @@ gboolean GnomeCmdMainWin::key_pressed(GdkEventKey *event)
                 case GDK_F9:
                     on_search_clicked (NULL, this);
                     return TRUE;
-
-                case GDK_F10:
-                    on_quit_clicked (NULL, this);
-                    return TRUE;
             }
 
     if (fs(ACTIVE)->key_pressed(event))
diff --git a/src/gnome-cmd-user-actions.cc b/src/gnome-cmd-user-actions.cc
index 85a1df6..1a7d308 100644
--- a/src/gnome-cmd-user-actions.cc
+++ b/src/gnome-cmd-user-actions.cc
@@ -238,7 +238,6 @@ void GnomeCmdUserActions::init()
     register_action(GDK_F7, "file.mkdir");
     register_action(GDK_F8, "file.delete");
     // register_action(GDK_F9, "edit.search");     //  do not register F9 here, as edit.search action wouldn't be checked for registration later
-    // register_action(GDK_F10, "file.exit");      //  do not register F10 here, as file.exit action wouldn't be checked for registration later
 }
 
 
@@ -399,9 +398,6 @@ void GnomeCmdUserActions::init()
 
     unregister(GDK_F9);                                 // unregister F9 if defined in [key-bindings]
     register_action(GDK_F9, "edit.search");             // and overwrite it with edit.search action
-
-    unregister(GDK_F10);                                // unregister F10 if defined in [key-bindings]
-    register_action(GDK_F10, "file.exit");              // and overwrite it with file.exit action
  }
 
 
@@ -416,7 +412,6 @@ void GnomeCmdUserActions::shutdown()
     unregister(GDK_F7);
     unregister(GDK_F8);
     unregister(GDK_F9);
-    unregister(GDK_F10);
 }
 
 



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