add new preference for popup preview
this option is disabled as the default at x-large
Bug:2909517
Change-Id: Ifda1b7ff89bc4beeee02ba0f3e01d441a9435b37
diff --git a/java/res/values-xlarge/bools.xml b/java/res/values-xlarge/bools.xml
new file mode 100644
index 0000000..fe8fc58
--- /dev/null
+++ b/java/res/values-xlarge/bools.xml
@@ -0,0 +1,23 @@
+<?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.
+*/
+-->
+<resources>
+ <!-- Whether or not Popup on key press is enabled by default -->
+ <bool name="default_popup_preview">false</bool>
+</resources>
diff --git a/java/res/values/bools.xml b/java/res/values/bools.xml
index a0cebbb..f5f2c3d 100644
--- a/java/res/values/bools.xml
+++ b/java/res/values/bools.xml
@@ -26,4 +26,6 @@
<!-- Whether or not voice input is enabled by default. -->
<bool name="voice_input_default">true</bool>
<bool name="config_swipeDisambiguation">true</bool>
+ <!-- Whether or not Popup on key press is enabled by default -->
+ <bool name="default_popup_preview">true</bool>
</resources>
diff --git a/java/res/values/strings.xml b/java/res/values/strings.xml
index e77155d..d2166f7 100644
--- a/java/res/values/strings.xml
+++ b/java/res/values/strings.xml
@@ -29,6 +29,9 @@
<!-- Option to play back sound on keypress in soft keyboard -->
<string name="sound_on_keypress">Sound on keypress</string>
+ <!-- Option to pop up the character with a larger font above soft keyboard -->
+ <string name="popup_on_keypress">Popup on keypress</string>
+
<!-- Option to enable using nearby keys when correcting/predicting -->
<string name="hit_correction">Correct typing errors</string>
diff --git a/java/res/xml/prefs.xml b/java/res/xml/prefs.xml
index e4c689a..11cc3ac 100644
--- a/java/res/xml/prefs.xml
+++ b/java/res/xml/prefs.xml
@@ -31,6 +31,13 @@
/>
<CheckBoxPreference
+ android:key="popup_on"
+ android:title="@string/popup_on_keypress"
+ android:persistent="true"
+ android:defaultValue="@bool/default_popup_preview"
+ />
+
+ <CheckBoxPreference
android:key="auto_cap"
android:title="@string/auto_cap"
android:persistent="true"