Revert the style, fix backspace behaviour.

This commit is contained in:
2024-10-16 17:33:47 +02:00
parent e40dab3342
commit 9154b0d865
3 changed files with 4 additions and 11 deletions
@@ -82,13 +82,8 @@ public class IME extends InputMethodService {
return true;
}
return false;
// If it's the Enter key, we let the application do it's job.
case KeyEvent.KEYCODE_ENTER:
return false;
// If it's the backspace key, we remove one character.
case KeyEvent.KEYCODE_DEL:
conn.deleteSurroundingText(1, 0);
mMetaKeyManager.adjustMetaStateAfterKeypress();
case KeyEvent.KEYCODE_ENTER:
return false;
case KeyEvent.KEYCODE_SPACE:
conn.commitText(" ", 1);
+1 -5
View File
@@ -2,16 +2,12 @@
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="false">
<shape>
<gradient android:angle="-45"
android:startColor="#333"
android:endColor="#222"/>
<stroke android:width="1dp" android:color="#333" />
<solid android:color="#333" />
</shape>
</item>
<item android:state_pressed="true">
<shape>
<solid android:color="#555" />
<stroke android:width="1dp" android:color="#222" />
</shape>
</item>
</selector>
+2
View File
@@ -37,6 +37,8 @@
<item name="android:background">@drawable/key</item>
<item name="android:textColor">#FFF</item>
<item name="android:textSize">18sp</item>
<item name="android:layout_marginLeft">1dp</item>
<item name="android:layout_marginRight">1dp</item>
<item name="android:layout_marginTop">2dp</item>
<item name="android:layout_marginBottom">2dp</item>
<item name="android:onClick">onInputViewKeyClick</item>