aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmith Yamasani <yamasani@google.com>2010-02-12 06:18:18 -0800
committerAmith Yamasani <yamasani@google.com>2010-02-12 06:23:06 -0800
commitd2a4e90a05030281aba9967cb6aac6e75b85430b (patch)
treeb547dce5a811a761e6db962aab97afb833bc811a
parent9a503e07d594ddf3cd0c31609c5311440b975906 (diff)
downloadlatinime-d2a4e90a05030281aba9967cb6aac6e75b85430b.tar.gz
latinime-d2a4e90a05030281aba9967cb6aac6e75b85430b.tar.xz
latinime-d2a4e90a05030281aba9967cb6aac6e75b85430b.zip
Use transparent keys for extension keyboard.
-rw-r--r--res/drawable-hdpi/btn_keyboard_key_fulltrans_normal.9.pngbin0 -> 1649 bytes
-rw-r--r--res/drawable-hdpi/btn_keyboard_key_fulltrans_pressed.9.pngbin0 -> 1696 bytes
-rw-r--r--res/drawable-mdpi/btn_keyboard_key_fulltrans_normal.9.pngbin0 -> 1068 bytes
-rw-r--r--res/drawable-mdpi/btn_keyboard_key_fulltrans_pressed.9.pngbin0 -> 1021 bytes
-rw-r--r--res/drawable/btn_keyboard_key_fulltrans.xml26
-rwxr-xr-xres/layout/input_trans.xml29
-rw-r--r--src/com/android/inputmethod/latin/LatinKeyboardView.java2
7 files changed, 56 insertions, 1 deletions
diff --git a/res/drawable-hdpi/btn_keyboard_key_fulltrans_normal.9.png b/res/drawable-hdpi/btn_keyboard_key_fulltrans_normal.9.png
new file mode 100644
index 000000000..b6c234c04
--- /dev/null
+++ b/res/drawable-hdpi/btn_keyboard_key_fulltrans_normal.9.png
Binary files differ
diff --git a/res/drawable-hdpi/btn_keyboard_key_fulltrans_pressed.9.png b/res/drawable-hdpi/btn_keyboard_key_fulltrans_pressed.9.png
new file mode 100644
index 000000000..73a8cd1c3
--- /dev/null
+++ b/res/drawable-hdpi/btn_keyboard_key_fulltrans_pressed.9.png
Binary files differ
diff --git a/res/drawable-mdpi/btn_keyboard_key_fulltrans_normal.9.png b/res/drawable-mdpi/btn_keyboard_key_fulltrans_normal.9.png
new file mode 100644
index 000000000..20f3d5087
--- /dev/null
+++ b/res/drawable-mdpi/btn_keyboard_key_fulltrans_normal.9.png
Binary files differ
diff --git a/res/drawable-mdpi/btn_keyboard_key_fulltrans_pressed.9.png b/res/drawable-mdpi/btn_keyboard_key_fulltrans_pressed.9.png
new file mode 100644
index 000000000..1ed3065c5
--- /dev/null
+++ b/res/drawable-mdpi/btn_keyboard_key_fulltrans_pressed.9.png
Binary files differ
diff --git a/res/drawable/btn_keyboard_key_fulltrans.xml b/res/drawable/btn_keyboard_key_fulltrans.xml
new file mode 100644
index 000000000..bad2a931d
--- /dev/null
+++ b/res/drawable/btn_keyboard_key_fulltrans.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+
+ <!-- Normal keys -->
+
+ <item android:state_pressed="true"
+ android:drawable="@drawable/btn_keyboard_key_fulltrans_pressed" />
+ <item
+ android:drawable="@drawable/btn_keyboard_key_fulltrans_normal" />
+
+</selector>
diff --git a/res/layout/input_trans.xml b/res/layout/input_trans.xml
new file mode 100755
index 000000000..a988bcc68
--- /dev/null
+++ b/res/layout/input_trans.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2010, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<com.android.inputmethod.latin.LatinKeyboardView
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@android:id/keyboardView"
+ android:layout_alignParentBottom="true"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:background="#A0000000"
+ android:keyBackground="@drawable/btn_keyboard_key_fulltrans"
+ />
diff --git a/src/com/android/inputmethod/latin/LatinKeyboardView.java b/src/com/android/inputmethod/latin/LatinKeyboardView.java
index bdac4a5b5..2686a93c6 100644
--- a/src/com/android/inputmethod/latin/LatinKeyboardView.java
+++ b/src/com/android/inputmethod/latin/LatinKeyboardView.java
@@ -171,7 +171,7 @@ public class LatinKeyboardView extends KeyboardView {
mExtensionPopup.setBackgroundDrawable(null);
LayoutInflater li = (LayoutInflater) getContext().getSystemService(
Context.LAYOUT_INFLATER_SERVICE);
- mExtension = (LatinKeyboardView) li.inflate(R.layout.input, null);
+ mExtension = (LatinKeyboardView) li.inflate(R.layout.input_trans, null);
mExtension.setOnKeyboardActionListener((LatinIME) getContext());
mExtension.setPopupParent(this);
mExtension.setPopupOffset(0, -windowLocation[1]);