gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] gnash gui/gui.h gui/gtk.cpp ChangeLog


From: Rob Savoye
Subject: [Gnash-commit] gnash gui/gui.h gui/gtk.cpp ChangeLog
Date: Sun, 05 Nov 2006 23:10:43 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Rob Savoye <rsavoye>    06/11/05 23:10:43

Modified files:
        gui            : gui.h gtk.cpp 
        .              : ChangeLog 

Log message:
                * gui/gui.h: Add stuff for Emacs mode.
                * gui/gtk.cpp: Handle control keys better, so Gnash doesn't core
                dump. Works around #18207.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/gui/gui.h?cvsroot=gnash&r1=1.35&r2=1.36
http://cvs.savannah.gnu.org/viewcvs/gnash/gui/gtk.cpp?cvsroot=gnash&r1=1.46&r2=1.47
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.1531&r2=1.1532

Patches:
Index: gui/gui.h
===================================================================
RCS file: /sources/gnash/gnash/gui/gui.h,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -b -r1.35 -r1.36
--- gui/gui.h   2 Nov 2006 14:00:34 -0000       1.35
+++ gui/gui.h   5 Nov 2006 23:10:43 -0000       1.36
@@ -221,3 +221,8 @@
 
 // end of _GUI_H_
 #endif
+
+// Local Variables:
+// mode: C++
+// indent-tabs-mode: t
+// End:

Index: gui/gtk.cpp
===================================================================
RCS file: /sources/gnash/gnash/gui/gtk.cpp,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -b -r1.46 -r1.47
--- gui/gtk.cpp 29 Oct 2006 18:34:10 -0000      1.46
+++ gui/gtk.cpp 5 Nov 2006 23:10:43 -0000       1.47
@@ -449,7 +449,7 @@
 void
 GtkGui::menuitem_sound_callback(GtkMenuItem* /*menuitem*/, gpointer /*data*/)
 {
-    GNASH_REPORT_FUNCTION;
+//    GNASH_REPORT_FUNCTION;
 
     sound_handler* snd_handler = get_sound_handler();
 
@@ -494,7 +494,6 @@
 GtkGui::menuitem_pause_callback(GtkMenuItem* /*menuitem*/, gpointer /*data*/)
 {
 //    GNASH_REPORT_FUNCTION;
-    dbglogfile << "menuitem_pause_callback: " << endl;
     menu_pause();
 }
 
@@ -719,28 +718,28 @@
         dbglogfile << "Got Shift-key: " << key << endl;
     }
     if (event->state == GDK_CONTROL_MASK) {
-        switch( (char)key) {
-          case 'q':
-          case 'w':
-              menuitem_quit_callback(NULL, NULL);
-              break;
+        dbglogfile << "Got Control-key: " << key << endl;
+        switch(key) {
           case 'r':
-              menuitem_restart_callback(NULL, NULL);
+              menu_restart();
               break;
           case 'p':
-              menuitem_pause_callback(NULL, NULL);
+              menu_pause();
+              break;
+          case 'q':
+          case 'w':
+              menu_quit();
               break;
           default:
-              dbglogfile << "Got Control-key: " << key << endl;
               break;
         }
-    }
-    if ( event->hardware_keycode == 9 )
-        menuitem_quit_callback(NULL,NULL); //Only hardware_keycode worked to 
detect Escape key pressed.
-    if ((event->state != GDK_CONTROL_MASK) || !(event->state != 
GDK_SHIFT_MASK)) {
-        dbglogfile << "Got key: '" << (char) key << "' its name is: " << 
gdk_keyval_name(key) << " hwkeycode: " << event->hardware_keycode << endl;
-    }
-        
+    } else {
+#if 0
+        dbglogfile << "Got key: '" << (char) key
+                   << "' its name is: " << gdk_keyval_name(key)
+                   << " it's value is: " << (int)key
+                   << " hwkeycode: " << event->hardware_keycode << endl;
+#endif
     switch (key) {
       case '[':
           menuitem_step_forward_callback(NULL, NULL);
@@ -751,6 +750,7 @@
       default:
           break;
     }
+    }
         
     return true;
 }

Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.1531
retrieving revision 1.1532
diff -u -b -r1.1531 -r1.1532
--- ChangeLog   5 Nov 2006 20:36:35 -0000       1.1531
+++ ChangeLog   5 Nov 2006 23:10:43 -0000       1.1532
@@ -1,3 +1,9 @@
+2006-11-05  Rob Savoye  <address@hidden>
+
+       * gui/gui.h: Add stuff for Emacs mode.
+       * gui/gtk.cpp: Handle control keys better, so Gnash doesn't core
+       dump.
+
 2006-11-05 Sandro Santilli <address@hidden>
 
        * testsuite/actionscript.all/String.as:
@@ -46,7 +52,7 @@
        * testsuite/server/PropertyListTest.cpp: Include
        config.h. Optionally include either dejagnu.h or check.h.
 
-2006-11-04 Sandro Santilli <address@hidden>
+q2006-11-04 Sandro Santilli <address@hidden>
 
        * server/sprite_instance.cpp (ctor): code cleanup.
         * testsuite/libbase/NoSeekFileTest.cpp: added missing unistd.h




reply via email to

[Prev in Thread] Current Thread [Next in Thread]