mirror of
https://github.com/SimpleMobileTools/Simple-Keyboard.git
synced 2025-06-05 21:49:26 +02:00
use rounded corners at the Delete etc backgrounds
This commit is contained in:
@ -335,7 +335,7 @@ class MyKeyboardView @JvmOverloads constructor(context: Context, attrs: Attribut
|
|||||||
MSG_SHOW_PREVIEW -> showKey(msg.arg1)
|
MSG_SHOW_PREVIEW -> showKey(msg.arg1)
|
||||||
MSG_REMOVE_PREVIEW -> mPreviewText!!.visibility = INVISIBLE
|
MSG_REMOVE_PREVIEW -> mPreviewText!!.visibility = INVISIBLE
|
||||||
MSG_REPEAT -> if (repeatKey()) {
|
MSG_REPEAT -> if (repeatKey()) {
|
||||||
val repeat: Message = Message.obtain(this, MSG_REPEAT)
|
val repeat = Message.obtain(this, MSG_REPEAT)
|
||||||
sendMessageDelayed(repeat, REPEAT_INTERVAL.toLong())
|
sendMessageDelayed(repeat, REPEAT_INTERVAL.toLong())
|
||||||
}
|
}
|
||||||
MSG_LONGPRESS -> openPopupIfRequired(msg.obj as MotionEvent)
|
MSG_LONGPRESS -> openPopupIfRequired(msg.obj as MotionEvent)
|
||||||
|
9
app/src/main/res/drawable/key_pressed_background.xml
Normal file
9
app/src/main/res/drawable/key_pressed_background.xml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item>
|
||||||
|
<shape android:shape="rectangle">
|
||||||
|
<solid android:color="@color/key_press_color" />
|
||||||
|
<corners android:radius="@dimen/medium_margin" />
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</layer-list>
|
@ -4,5 +4,5 @@
|
|||||||
<item android:drawable="@drawable/minikeyboard_selected_background" android:state_focused="true" />
|
<item android:drawable="@drawable/minikeyboard_selected_background" android:state_focused="true" />
|
||||||
|
|
||||||
<!-- used at clicking some keys on the main keyboard -->
|
<!-- used at clicking some keys on the main keyboard -->
|
||||||
<item android:drawable="@color/key_press_color" android:state_pressed="true" />
|
<item android:drawable="@drawable/key_pressed_background" android:state_pressed="true" />
|
||||||
</selector>
|
</selector>
|
||||||
|
Reference in New Issue
Block a user