gnome-commander r1706 - in branches/gcmd-1-3: . doc/C src



Author: epiotr
Date: Fri Apr 18 22:55:02 2008
New Revision: 1706
URL: http://svn.gnome.org/viewvc/gnome-commander?rev=1706&view=rev

Log:
Define CTRL+Q binding as user definable (file.exit)

Modified:
   branches/gcmd-1-3/ChangeLog
   branches/gcmd-1-3/doc/C/gnome-commander.xml
   branches/gcmd-1-3/src/gnome-cmd-main-win.cc
   branches/gcmd-1-3/src/gnome-cmd-user-actions.cc

Modified: branches/gcmd-1-3/doc/C/gnome-commander.xml
==============================================================================
--- branches/gcmd-1-3/doc/C/gnome-commander.xml	(original)
+++ branches/gcmd-1-3/doc/C/gnome-commander.xml	Fri Apr 18 22:55:02 2008
@@ -4309,7 +4309,7 @@
                     <row valign="top">
                         <entry><para>file.exit</para></entry>
                         <entry><para>Exit &app;</para></entry>
-                        <entry><para></para></entry>
+                        <entry><para><keycombo><keycap>CTRL</keycap><keycap>Q</keycap></keycombo></para></entry>
                     </row>
                     <row valign="top">
                         <entry><para>file.external_view</para></entry>
@@ -4368,7 +4368,7 @@
                     </row>
                     <row valign="top">
                         <entry><para>help.keyboard</para></entry>
-                        <entry><para>Help on keayboard shortcuts</para></entry>
+                        <entry><para>Help on keyboard shortcuts</para></entry>
                         <entry><para></para></entry>
                     </row>
                     <row valign="top">

Modified: branches/gcmd-1-3/src/gnome-cmd-main-win.cc
==============================================================================
--- branches/gcmd-1-3/src/gnome-cmd-main-win.cc	(original)
+++ branches/gcmd-1-3/src/gnome-cmd-main-win.cc	Fri Apr 18 22:55:02 2008
@@ -1020,11 +1020,6 @@
                     clear_event_key (event);
                 }
                 return TRUE;
-
-            case GDK_Q:
-            case GDK_q:
-                gtk_widget_destroy (GTK_WIDGET (main_win));
-                return TRUE;
         }
     }
     else if (state_is_alt_shift (event->state))

Modified: branches/gcmd-1-3/src/gnome-cmd-user-actions.cc
==============================================================================
--- branches/gcmd-1-3/src/gnome-cmd-user-actions.cc	(original)
+++ branches/gcmd-1-3/src/gnome-cmd-user-actions.cc	Fri Apr 18 22:55:02 2008
@@ -216,7 +216,7 @@
     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");
+    // register_action(GDK_F10, "file.exit");      //  do not register F10 here, as file.exit action wouldn't be checked for registration later
 
     load("key-bindings");
 
@@ -260,6 +260,9 @@
     if (!registered("file.edit_new_doc"))
         register_action(GDK_SHIFT_MASK, GDK_F4, "file.edit_new_doc");
 
+    if (!registered("file.exit"))
+        register_action(GDK_CONTROL_MASK, GDK_Q, "file.exit");
+
     if (!registered("file.external_view"))
         register_action(GDK_MOD1_MASK, GDK_F3, "file.external_view");
 
@@ -287,6 +290,7 @@
     {
         register_action(GDK_CONTROL_MASK, GDK_5, "plugins.execute_python", "md5sum");
         register_action(GDK_CONTROL_MASK, GDK_KP_5, "plugins.execute_python", "md5sum");
+        register_action(GDK_CONTROL_MASK, GDK_KP_Begin, "plugins.execute_python", "md5sum");
     }
 
     if (!registered("view.equal_panes"))
@@ -327,6 +331,9 @@
 
     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
  }
 
 



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