Jelajahi Sumber

spacebar bug fixed

Michael 10 tahun lalu
induk
melakukan
b4c88dea09
2 mengubah file dengan 6 tambahan dan 4 penghapusan
  1. 2 4
      glueIt
  2. 4 0
      src/allplatforms/classes/Keyboard.js

+ 2 - 4
glueIt

@@ -32,8 +32,7 @@ case "$1" in
         echo "Testing Firefox add-on..."
         cd ./tools/firefox-addon-sdk-1.16
         source bin/activate
-        cd ../..
-        cd ./build/firefox
+        cd ../../build/firefox
         cfx run
         cd ../..
         ;;
@@ -43,8 +42,7 @@ case "$1" in
         echo "Packaging Firefox add-on..."
         cd ./tools/firefox-addon-sdk-1.16
         source bin/activate
-        cd ../..
-        cd ./build/firefox
+        cd ../../build/firefox
         cfx xpi
         cd ../..
         ;;

+ 4 - 0
src/allplatforms/classes/Keyboard.js

@@ -51,6 +51,8 @@ SC.loadPackage({ 'Keyboard': {
                             myDocument.set({ showOutlines: !myDocument.get('showOutlines') });
                             spaceBarDown = true;
                         }
+                        evt.stopPropagation();
+                        evt.preventDefault();
 
                     }
 
@@ -73,6 +75,8 @@ SC.loadPackage({ 'Keyboard': {
                             myDocument.set({ showOutlines: !myDocument.get('showOutlines') });
                             spaceBarDown = false;
                         }
+                        evt.stopPropagation();
+                        evt.preventDefault();
 
                     }