aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenny Root <kenny@the-b.org>2009-07-04 13:42:35 +0000
committerKenny Root <kenny@the-b.org>2009-07-04 13:42:35 +0000
commite1f93cdb7d17a52e38adb7c09c34fd7ace25d28f (patch)
tree809eff1d826fba29f5bb10aea31ae1282cfdd513
parent2ca280d2bcfec320e1e25bd5800f4675e71a57c6 (diff)
downloadconnectbot-e1f93cdb7d17a52e38adb7c09c34fd7ace25d28f.tar.gz
connectbot-e1f93cdb7d17a52e38adb7c09c34fd7ace25d28f.tar.bz2
connectbot-e1f93cdb7d17a52e38adb7c09c34fd7ace25d28f.zip
Restore some Fn key functionality for hardware keyboard users
git-svn-id: https://connectbot.googlecode.com/svn/trunk/connectbot@353 df292f66-193f-0410-a5fc-6d59da041ff2
-rw-r--r--AndroidManifest.xml2
-rw-r--r--src/org/connectbot/service/TerminalBridge.java5
2 files changed, 5 insertions, 2 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 9928c2c..e06631a 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -2,7 +2,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.connectbot"
android:versionName="1.6-dev"
- android:versionCode="159">
+ android:versionCode="160">
<application
android:icon="@drawable/icon"
diff --git a/src/org/connectbot/service/TerminalBridge.java b/src/org/connectbot/service/TerminalBridge.java
index f66d89c..a79668d 100644
--- a/src/org/connectbot/service/TerminalBridge.java
+++ b/src/org/connectbot/service/TerminalBridge.java
@@ -520,6 +520,8 @@ public class TerminalBridge implements VDUDisplay, OnKeyListener {
if (printing) {
int curMetaState = event.getMetaState();
+ boolean oppositeShift = (metaState & META_TAB) != 0;
+
metaState &= ~(META_SLASH | META_TAB);
if ((metaState & META_SHIFT_MASK) != 0) {
@@ -554,7 +556,7 @@ public class TerminalBridge implements VDUDisplay, OnKeyListener {
}
// handle pressing f-keys
- if ((metaState & META_TAB) != 0) {
+ if (oppositeShift) {
switch(key) {
case '!': ((vt320)buffer).keyPressed(vt320.KEY_F1, ' ', 0); return true;
case '@': ((vt320)buffer).keyPressed(vt320.KEY_F2, ' ', 0); return true;
@@ -583,6 +585,7 @@ public class TerminalBridge implements VDUDisplay, OnKeyListener {
event.getAction() == KeyEvent.ACTION_MULTIPLE) {
byte[] input = event.getCharacters().getBytes(host.getEncoding());
transport.write(input);
+ return true;
}
// try handling keymode shortcuts