abouttreesummaryrefslogcommitdiff
path: root/res/layout
diff options
context:
space:
mode:
authorJules Aguillon2021-12-30 00:26:05 +0100
committerJules Aguillon2021-12-30 00:26:05 +0100
commit093a00c572a29d292bc6bbb09559611cb61e1331 (patch)
tree945f43f7c4bbff2bf5d22fa3a12c7d42833dc97d /res/layout
parent40b1ec63a932606fb432ee81801acf147e9ee70e (diff)
downloadunexpected-keyboard-093a00c572a29d292bc6bbb09559611cb61e1331.tar.gz
unexpected-keyboard-093a00c572a29d292bc6bbb09559611cb61e1331.zip
Add themes
Add a "Theme" option to choose between a dark and light theme. The light theme uses the colors of the dark theme with the luminance inversed. The reloading after a configuration change is changed slightly: - Special handling is needed when the Theme is changed (recreate the views) - The default implementation of 'onConfigurationChanged' is used Which triggers more refresh (but don't recreate the views) - 'onCreateInputView' is no longer needed
Diffstat (limited to 'res/layout')
-rw-r--r--res/layout/emoji_pane.xml2
-rw-r--r--res/layout/keyboard.xml2
2 files changed, 2 insertions, 2 deletions
diff --git a/res/layout/emoji_pane.xml b/res/layout/emoji_pane.xml
index 3c58330..2931282 100644
--- a/res/layout/emoji_pane.xml
+++ b/res/layout/emoji_pane.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:hardwareAccelerated="false" android:theme="@style/Dark">
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:hardwareAccelerated="false">
<juloo.keyboard2.EmojiGroupButtonsBar android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content"/>
<juloo.keyboard2.EmojiGridView android:id="@+id/emoji_grid" android:background="?attr/colorKeyboard" android:layout_width="fill_parent" android:layout_height="@dimen/emoji_grid_height"/>
<LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content">
diff --git a/res/layout/keyboard.xml b/res/layout/keyboard.xml
index b15f6d0..8af048d 100644
--- a/res/layout/keyboard.xml
+++ b/res/layout/keyboard.xml
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
-<juloo.keyboard2.Keyboard2View xmlns:android="http://schemas.android.com/apk/res/android" android:hardwareAccelerated="false" android:theme="@style/Dark" android:background="?attr/colorKeyboard"/>
+<juloo.keyboard2.Keyboard2View xmlns:android="http://schemas.android.com/apk/res/android" android:hardwareAccelerated="false" android:background="?attr/colorKeyboard"/>