aboutsummaryrefslogtreecommitdiffstats
path: root/java/res/layout
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2013-08-28 09:14:00 +0900
committerTadashi G. Takaoka <takaoka@google.com>2013-08-28 20:18:19 +0900
commit8ac0eb59e13bce327007ba2cf2f1a7e767eebe0a (patch)
tree3cfdb087a927b2ed454b9c97e85e07afacda28e9 /java/res/layout
parent8e3a90e58ffd09692a23b29dc949a2f0fb3d774c (diff)
downloadlatinime-8ac0eb59e13bce327007ba2cf2f1a7e767eebe0a.tar.gz
latinime-8ac0eb59e13bce327007ba2cf2f1a7e767eebe0a.tar.xz
latinime-8ac0eb59e13bce327007ba2cf2f1a7e767eebe0a.zip
Add EmojiKeyboardView
Bug: 6370846 Change-Id: Ic7d75f1d242795e756e6fede988cfe4b5cc17f0e
Diffstat (limited to 'java/res/layout')
-rw-r--r--java/res/layout/emoji_keyboard_page.xml33
-rw-r--r--java/res/layout/emoji_keyboard_tab_icon.xml26
-rw-r--r--java/res/layout/emoji_keyboard_tab_label.xml26
-rw-r--r--java/res/layout/emoji_keyboard_view.xml94
4 files changed, 179 insertions, 0 deletions
diff --git a/java/res/layout/emoji_keyboard_page.xml b/java/res/layout/emoji_keyboard_page.xml
new file mode 100644
index 000000000..e0b752b32
--- /dev/null
+++ b/java/res/layout/emoji_keyboard_page.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2013, 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.keyboard.internal.ScrollViewWithNotifier
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/emoji_keyboard_scroller"
+ android:clipToPadding="false"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+>
+ <com.android.inputmethod.keyboard.internal.ScrollKeyboardView
+ android:id="@+id/emoji_keyboard_page"
+ android:layoutDirection="ltr"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content" />
+</com.android.inputmethod.keyboard.internal.ScrollViewWithNotifier>
diff --git a/java/res/layout/emoji_keyboard_tab_icon.xml b/java/res/layout/emoji_keyboard_tab_icon.xml
new file mode 100644
index 000000000..d79276eb9
--- /dev/null
+++ b/java/res/layout/emoji_keyboard_tab_icon.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2013, 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.
+*/
+-->
+
+<ImageView xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="0dip"
+ android:layout_weight="1.0"
+ android:layout_height="wrap_content"
+ android:gravity="center"
+/>
diff --git a/java/res/layout/emoji_keyboard_tab_label.xml b/java/res/layout/emoji_keyboard_tab_label.xml
new file mode 100644
index 000000000..62c552dd8
--- /dev/null
+++ b/java/res/layout/emoji_keyboard_tab_label.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2013, 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.
+*/
+-->
+
+<TextView xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="0dip"
+ android:layout_weight="1.0"
+ android:layout_height="wrap_content"
+ android:gravity="center"
+/>
diff --git a/java/res/layout/emoji_keyboard_view.xml b/java/res/layout/emoji_keyboard_view.xml
new file mode 100644
index 000000000..ccbcfdc6f
--- /dev/null
+++ b/java/res/layout/emoji_keyboard_view.xml
@@ -0,0 +1,94 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2013, 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.keyboard.EmojiKeyboardView
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/emoji_keyboard_view"
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ style="?attr/emojiKeyboardViewStyle"
+>
+ <LinearLayout
+ android:orientation="horizontal"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/suggestions_strip_height"
+ >
+ <TabHost
+ android:id="@+id/emoji_category_tabhost"
+ android:layout_width="0dip"
+ android:layout_weight="87.5"
+ android:layout_height="match_parent"
+ >
+ <TabWidget
+ android:id="@android:id/tabs"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:background="@drawable/tab_selected"
+ android:divider="@null"
+ android:tabStripEnabled="true"
+ android:tabStripLeft="@drawable/tab_unselected"
+ android:tabStripRight="@drawable/tab_unselected" />
+ <FrameLayout
+ android:id="@android:id/tabcontent"
+ android:layout_width="0dip"
+ android:layout_height="0dip"
+ >
+ <!-- Empty placeholder that TabHost requires. But we don't use it to actually
+ display anything. We monitor the tab changes and change the ViewPager.
+ Similarly the ViewPager swipes are intercepted and passed to the TabHost. -->
+ <View
+ android:id="@+id/emoji_keyboard_dummy"
+ android:layout_width="0dip"
+ android:layout_height="0dip"
+ android:visibility="gone" />
+ </FrameLayout>
+ </TabHost>
+ <ImageButton
+ android:id="@+id/emoji_keyboard_delete"
+ android:layout_width="0dip"
+ android:layout_weight="12.5"
+ android:layout_height="match_parent"
+ android:src="@drawable/sym_keyboard_delete_holo" />
+ </LinearLayout>
+ <android.support.v4.view.ViewPager
+ android:id="@+id/emoji_keyboard_pager"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content" />
+ <LinearLayout
+ android:id="@+id/emoji_action_bar"
+ android:orientation="horizontal"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/suggestions_strip_height"
+ >
+ <ImageButton
+ android:id="@+id/emoji_keyboard_alphabet"
+ android:layout_width="0dip"
+ android:layout_weight="0.825"
+ android:layout_height="match_parent"
+ android:src="@drawable/ic_ime_light" />
+ <ImageButton
+ android:id="@+id/emoji_keyboard_send"
+ android:layout_width="0dip"
+ android:layout_weight="0.125"
+ android:layout_height="match_parent"
+ android:src="@drawable/sym_keyboard_return_holo" />
+ </LinearLayout>
+</com.android.inputmethod.keyboard.EmojiKeyboardView>