Commit Graph

876 Commits (c05a70a4ca769664f2315fff1f3bf3cb2ce3e300)

Author SHA1 Message Date
Dan Zivkovic f9e2d271ca Use a single background executor.
Bug 19625976.

Change-Id: Ia03f440a31b059b5af42d162e1145330bf7b5ddf
2015-03-09 13:22:56 -07:00
Dan Zivkovic b86ca76cea Handle null InputMethodSubtype.
Bug 19627494.

Change-Id: I50dc77c59ced0f2e7c07a49ae0cb040197c2ab35
2015-03-06 14:34:57 -08:00
Dan Zivkovic bc0384c7ec Combine InputLogicTests.
Change-Id: Ie322e7d7c7098031d112abad6c9991f56ebba0f2
2015-03-04 15:07:13 -08:00
Dan Zivkovic 1ae16dc3db Next-word suggestion bit in keyboard settings.
This feature works in supported languages.
We don't need a user setting.

Bug 19596067.

Change-Id: Icdded772745f9816da47f8a5e3b87b733083b121
2015-03-04 15:02:53 -08:00
Jatin Matani a568e0acb4 Add util method in ngramcontext for context array
Change-Id: I2e3e2ac7706be50ed2055b0c69b30e25a516a879
2015-03-03 13:20:53 -08:00
Jatin Matani c83352d527 Merge "Refresh pref settings for cloud sync" 2015-02-26 22:10:02 +00:00
Jatin Matani 8ec328fb2e Refresh pref settings for cloud sync
- Show the opt-in text
- Show the account picker if user presses 'enable sync'. Previously
  we disabled the sync pref which was confusing.
- Remove the debug tags from some prefs; and improve messaging overall

General rules;
- sync is turned ON : user checks 'enable sync' pref AND
  accepts the opt-in AND chooses an account
- sync is turned OFF: when user signs out

Demo link
https://drive.google.com/a/google.com/file/d/0B9tNQOWdRuiWSUdVVE5rVDJudlk/view?usp=sharing

Change-Id: I2e7933796b15e47005ba9970a8c1294416ef31a0
2015-02-26 11:43:42 -08:00
Dan Zivkovic 7d7f082075 Stop waking up to decay dynamic dictionaries.
Bug 19516048.

Change-Id: Ibc27a792b4fa80fa8c6af4721c47a617526e9584
2015-02-25 20:13:59 -08:00
Dan Zivkovic 5551302d27 Don't assume that correctable words are invalid
Currently, the Delight3DictionaryFacilitator sets a boolean flag when the top
suggestion score exceeds the auto-correction threshold. This flag is used to
trigger auto-correction of the typed word. Also, the existing logic assumes
that if allowsToBeAutoCorrected then the word is invalid, which is no longer
true after we stopped using whitelists.

Bug 19518376.

Change-Id: Ifa7f6a09c07d25ac68c6cf3aec91f358bd88689f
2015-02-25 17:59:58 -08:00
Dan Zivkovic fe3c4ef940 Merge "Spell checker uses cache of size 1." 2015-02-20 19:06:48 +00:00
Dan Zivkovic 29aa3df3da Spell checker uses cache of size 1.
This is a step in the direction of removing the LRU cache completely.

Change-Id: I8886f7ef74e6b1b35135e68f169cb461682964e9
2015-02-20 11:05:44 -08:00
Jatin Matani 01b023730e Add tests for Contact* classes
Also add empty implementation for dictionary
facilitator iteration APIs
Change-Id: Ia847e3faa75075c819fcfda89193d1024d2d5aca
2015-02-20 09:14:27 -08:00
Dan Zivkovic 0b03f13cab Sanitize the usage of executors.
There should be 1 executor each for static and dynamic language models.
This prevents too many dynamic LM updates from running in parallel,
competing for resources.

Change-Id: I8ec439e0ea2d92fba275bc20a0b8c9193346a0c1
2015-02-19 11:40:57 -08:00
Dan Zivkovic 12d80ebead Remove shortcut support from LatinIME.
Note this change does not affect the native decoder interface.

Change-Id: I73b7dc008a5acaf75a31a36a2d332b5afabd82d0
2015-02-11 13:02:41 -08:00
Mario Tanev 2979fad213 Merge "Add new class spellcheck.UserDictionaryLookup that can look up the system "Personal dictionary" in the event that the DictionaryFacilitator doesn't." 2015-02-10 23:25:50 +00:00
Mario Tanev 8aa310aa5a Add new class spellcheck.UserDictionaryLookup that can look up the
system "Personal dictionary" in the event that the DictionaryFacilitator
doesn't.

Change-Id: Ib4f15ec4d8f06ea43c2e063f5a13a2f699afbb8a
2015-02-10 10:56:35 -08:00
Dan Zivkovic 644a709a5f Remove distracter filter from client.
Bug 19296201.

Change-Id: Ic834e5956347cd86a96bd14024c42ad8ee258659
2015-02-09 11:52:12 -08:00
Mohammadinamul Sheik aadfef6ffa Merge "Move decoder specific constants to DecoderSpecificConstants.java" 2015-02-06 22:46:08 +00:00
Dan Zivkovic d6a8adcb04 Cleanup in preparation of distracter change.
Bug 19296201.

Change-Id: If016da2b7f4b3ecb9afd6d7aed9d19fbd4938758
2015-02-06 14:25:37 -08:00
Mohammadinamul Sheik 0f7d881dc7 Move decoder specific constants to DecoderSpecificConstants.java
Change-Id: Ie4d325b3152e1e7e424b8b436e222e194e4d9da0
2015-02-05 13:27:36 -08:00
Dan Zivkovic f3c319fb8a Selections spans should not split surrogate pair.
When committing a span after a revert, the offset logic was such that it
split a surrogate unicode pair used to express an emoji.
Checking the last character of the span lets us avoid this problem.

Fix for bug 19255233.

Change-Id: I07d18d9002b5075f7925319dd05962011656c311
2015-02-04 16:35:18 -08:00
Jatin Matani 15acbdc905 Nuke Amanatto
Change-Id: Ieff2cd37f869dca69abf53ac32a576c2e45cc1e3
2015-02-02 17:10:38 -08:00
Dan Zivkovic e1758feeff Disable the Burmese keyboard.
We'll resurrect this effort in the new code base.

Bug 16900511.

Change-Id: Iae4cd27cb29cb8f991e97cffd88ed59c30d66628
2015-01-29 10:17:33 -08:00
Mario Tanev ab6f3b36d0 Change DictionaryFacilitator.java to an interface, create its
implementation DictionaryFacilitatorImpl.java and add a java-overridable
factory DictionaryFacilitatorProvider.java used to create a
DictionaryFacilitator.

Change-Id: Id4a58ae31feaa4d12a048a772c8d76ff82fdee45
2015-01-27 21:38:32 +00:00
Jean Chalard 8e235191dd Fix moving the cursor inside composition in lang w/o spaces
Also introduce the cursor move event, which we needed to do
anyway

Bug: 18827118
Change-Id: I30e994764c095b4423b874dc05d1bbedc0de592f
2014-12-22 17:47:33 +09:00
Tadashi G. Takaoka 8bc644de64 Revert "Fix unit test failure due to translation glitch"
This reverts commit f8705dd2bd.

Change-Id: I7ddc1eced8109ff0bb50eb8a217db0d276848a1e
2014-12-17 06:14:49 +00:00
Jatin Matani bc4ae6bdc0 Passing account info to dictionaryFacilitator
Attempt to use dictionary facilitor without invoking
preference manager. Instead use account from settings only when
things are being reset/changed. Discussion forked from ag/591663

Overall, the idea here is to maintain an account information
inside dictionary groups. Reset the dictionary groups if
account changes (the way we do for locale). Since only user
history dictionary is currently affected, the check to reset user
history dictionary also includes the check to verify the account.
For other things remain the same.

SettingsValues holds the current account (and is updated if prefs change
due to change in account settings). The updated settings are then
propagated to dictionary facilitator via LatinIME#loadSettings.

Bug:18104749,18469539
Change-Id: I553e776e7ea125d0fb7a1fe70a4c7eb0b2277fb8
2014-12-16 15:56:00 -08:00
Tadashi G. Takaoka 4934a88b61 Make LanguageOnSpacebarHelper as utility class
Change-Id: I546f3b1943999a41803222bd14f9ddd23aa87a51
2014-12-11 14:22:21 +09:00
Jatin Matani 2bdd5290a9 Merge "Hook for fetching sync content from UserHistoryDict" 2014-12-08 20:00:10 +00:00
Adrian Velicu 11a3965f8c Fix a misspelled method name
Change-Id: I1151dc1d5db3986a97daf68c1e387dbc2e4610dc
2014-12-02 12:53:56 +09:00
Jatin Matani 12d63820d4 Hook for fetching sync content from UserHistoryDict
Add API to ExpandableBinaryDictionary to dump content
from a given dictionary. We use this for dumping data
for sync process.

Refactored UserHistoryDictionaryTests to scrap out the util
methods for testing. These utility methods would be used
for testing sync + user dictionary code in LatinIMEGoogleTests

Bug:18106539
Change-Id: I357f9192ea1bd69a526d0b620c25616a2e8e9d5b
2014-11-26 11:17:24 -08:00
Tadashi G. Takaoka 8a711f2a54 Remove unneeded Context argument
Change-Id: Ib34931836a617d0dc049fb3c9ae6686374ec8c12
2014-11-21 12:49:04 +09:00
Tadashi G. Takaoka f8705dd2bd Fix unit test failure due to translation glitch
Once the translation strings are updated, the uni test starts
failing. Then this CL should be reverted.

Change-Id: I884663feaa53998a98dd0e488ae8e3e6d0ad4ffd
2014-11-20 17:05:21 +09:00
Jean Chalard a2cb2f36a6 Make the typed word a SuggestedWordInfo
That allows to carry the language information in an
accurate manner.

Bug: 18063142
Change-Id: I0bca8981372ae10648274095b18b26a3686b762b
2014-11-20 13:57:01 +09:00
Tadashi G. Takaoka cae324c561 Cleanup StringAndJsonUtilsTests
Change-Id: I7d35492c439c9419915251387b0c12e205740586
2014-11-19 19:08:13 +09:00
Tadashi G. Takaoka 6c47403e27 Rename StringUtils methods that handle title case manipulation
Change-Id: Iee0dd077a0423f110f4f8dad0f04933045baef2a
2014-11-19 19:08:05 +09:00
Tadashi G. Takaoka 0cf0bfaa75 Merge "Fix Greek accented upper case letters" 2014-11-19 09:29:20 +00:00
Tadashi G. Takaoka f62b5d633d Fix Greek accented upper case letters
Bug: 18418991
Change-Id: I7b34b126bec70300c83e17bea39e1036de4bf7c2
2014-11-19 17:57:10 +09:00
Jean Chalard 83f9524b87 Remove the other deprecated constructor to SuggestedWords
Change-Id: Ied821df01e032ebc913d2f15dffdf41a51372ea4
2014-11-17 16:23:52 +09:00
Jatin Matani d60f9c046e Merge "Implement UserHistoryDictionary for each user account." 2014-11-14 00:46:37 +00:00
Jatin Matani 5365191a9d Implement UserHistoryDictionary for each user account.
UserHistoryDictionary currently uses locale to determine the
UserHistoryDictionary on the filesystem. With this change we
use the account name as well. Thus each UserHistoryDictionary
would following the following spec:

UserHistoryDictionary.<locale>.<account>.dict.
In case no account is selected, we default to the existing
spec:
UserHistoryDictionary.<locale>.dict

Example
UserHistoryDictionary.en_US.testaccount@example.com.dict

Bug: 18104749
Change-Id: Iab031e166b55cf2ded68275a7e9be22475737b37
2014-11-13 14:21:38 -08:00
Tadashi G. Takaoka 1da382b81e Remove unused import
Change-Id: I9e2a79534673b2c6587f57fad663b85d971658b9
2014-11-12 16:27:14 -08:00
Tadashi G. Takaoka c4b6ac72c5 Update SubtypeLocaleUtilsTests to test Serbian Latin in Seribian
Change-Id: I80399b311ff5ed35f246e7e3d06d7386f03a0684
2014-11-12 14:56:51 -08:00
Tadashi G. Takaoka 609ee38e29 Rename unit test
Change-Id: I0d18562a0b036a3e76a6df989a143bb05f0ed833
2014-11-08 17:46:59 -08:00
Tadashi G. Takaoka ec0d6bb9b7 Merge "Move current subtype management code to RichInputMethodManager" 2014-11-07 18:02:22 +00:00
Jean Chalard 5b91b551e5 Move util classes under common
Also why did we have two copies of LocaleUtils >.>

Bug: 18108776
Change-Id: I03b4403dfd51934e66b567f2f8b87da419cfb3ab
2014-11-07 18:00:03 +09:00
Tadashi G. Takaoka 7fb0ed58ed Move current subtype management code to RichInputMethodManager
Change-Id: I82d5a17a5ec96f26047d29e79f3f28850fc5b3bb
2014-11-06 11:51:07 -08:00
Jean Chalard e1652d7570 Fix the build : move offdevice tests in an off device file
Also fix a failing test

Change-Id: I280aa6b5836c7332da08a88f1258546edeb25a37
2014-11-06 22:33:57 +09:00
Jean Chalard 5b33d197ba Add a header command to dicttool.
This will allow to greatly improve the performance of the
metadata-generating files, as they won't have to wait for
the info command to read the entire dictionary when the
header is all we need.

Also add tests, and while we're at it, use the seed as
intended to enable reproducible tests.

Change-Id: I0ba79ef62f0292b23e63aed57ff565bb102281a2
2014-11-06 18:50:59 +09:00
Jean Chalard f6b0e32df3 Add a *FAST* dictionary header reader.
It's still unused as of this change but the next change will use it

As a reference point, generating the metadata for Bayo takes
3'02" on my machine with the info command; it's down to 16" if
made to use this instead. The gains increases with the number
of dictionaries obviously.

Change-Id: I0eeea2d8f81bb74b0d1570af658e91b56f7c2b79
2014-11-06 13:17:08 +09:00
Keisuke Kuroyanagi ea468cc9de Update v4 format version from 402 to 403.
Without personalization:
Total words: 1134774, Success Num: 899230, Success Percentage: 79.243%
Bad Failures, with auto-correction (typed word == expected word, output word != expected word): 1871, Bad Failure Percentage: 0.165%
Failures, with auto-correction (F-C): 29084, F-C Percentage: 2.563%
Max Keystrokes: 6072959, Min Keystrokes: 4436090, Keystroke Saving Percentage:26.953%

Before:
Total words: 1134646, Success Num: 925194, Success Percentage: 81.540%
Bad Failures, with auto-correction (typed word == expected word, output word != expected word): 1316, Bad Failure Percentage: 0.116%
Failures, with auto-correction (F-C): 28288, F-C Percentage: 2.493%
Max Keystrokes: 6072831, Min Keystrokes: 3946188, Keystroke Saving Percentage:35.019%

After
Total words: 1134659, Success Num: 944746, Success Percentage: 83.263%
Bad Failures, with auto-correction (typed word == expected word, output word != expected word): 1258, Bad Failure Percentage: 0.111%
Failures, with auto-correction (F-C): 28016, F-C Percentage: 2.469%
Max Keystrokes: 6072844, Min Keystrokes: 3387333, Keystroke Saving Percentage:44.222%

Change-Id: I3af42ec37a11847c0429c28616e726f6a339247f
2014-10-31 17:23:39 +09:00
Ken Wakasa ed575b62da Merge "Add documentation for CollectionUtils#arrayAsList" 2014-10-31 07:07:07 +00:00
David Faden d443146c34 Add documentation for CollectionUtils#arrayAsList
(This is a cherrypick of http://ag/576739)

Also, modify the IllegalArgumentException to capture the
values passed for start, end, and array.length to make
debugging easier in the unlikely event that it is thrown.
Add corresponding tests for the exceptions.

Tested:
tapas LatinImeGoogle LatinImeGoogleTests userdebug
make -j30 && \
adb install -r \
out/target/product/generic/data/app/LatinImeGoogleTests/LatinImeGoogleTests.apk && \
adb install -r \
out/target/product/generic/system/app/LatinImeGoogle/LatinImeGoogle.apk && \
adb shell am instrument -w -e class \
com.android.inputmethod.latin.utils.CollectionUtilsTests \
com.google.android.inputmethod.latin.tests/android.support.test.runner.AndroidJUnitRunner

Change-Id: I0c579ca4f4f2a9b2575aa6f8fa75e3ee4a21cf8a
2014-10-31 06:18:35 +00:00
Adrian Velicu 88480f39f6 Update unit tests for new static dict version.
Bug: 11031090
Change-Id: Ifd7b241f1a0a30678ca7de97cc6e96927a9b5c8f
2014-10-31 14:50:18 +09:00
Adrian Velicu 7c87859d4c Using "blacklist" flag as "possibly offensive"
Bug: 11031090
Change-Id: I5cc0d006ab003656498eb82b0875eb9c051d331e
2014-10-31 14:33:05 +09:00
Keisuke Kuroyanagi bcb52d73e2 Enable count based dynamic ngram language model for v403.
Bug: 14425059

Change-Id: Icc15e14cfd77d37cd75f75318fd0fa36f9ca7a5b
2014-10-30 23:38:19 +09:00
Jean Chalard 36799b2aa2 Move InputPointers and ResizableIntArray to common
Bug: 18108776
Change-Id: Ie5c0430aa41a8d6c58bf510a10173223d7dfe9fe
2014-10-29 12:09:11 +09:00
Jean Chalard 4beeb9253a Move StringUtils under common.
Bug: 18108776
Change-Id: Ia46a4102a0e86e71118ca5e641f9f531998e166b
2014-10-28 22:44:30 +09:00
Jean Chalard 8cad60ae88 Fix tests build
Change-Id: I873ab97e2c4b30caa9227d26d7880d5ed6d134b0
2014-10-28 22:37:16 +09:00
Tadashi G. Takaoka 1290399123 Merge "Fix Serbian Latin subtype handling" 2014-10-28 09:40:00 +00:00
Tadashi G. Takaoka fec5219974 Fix Serbian Latin subtype handling
This CL also adds unit tests for Hinglish and Serbian Latin.

Bug: 9687668
Bug: 17169632
Change-Id: Ib9aa1bcdf5b390a9d8c61f07165beacf850e2692
2014-10-28 18:36:16 +09:00
Jean Chalard 450c8e8935 Merge "Add some gesture-move tests" 2014-10-28 06:22:18 +00:00
Tadashi G. Takaoka 395009c03e Fix NPE in AppearanceSettingsFragment
Bug: 18147440
Change-Id: I7a7a47b3484e54146d34d11b5bd9c1305421d829
2014-10-28 15:02:31 +09:00
Jean Chalard d17e1d31b6 Add some gesture-move tests
Change-Id: I5ec9a9169b0d27da93194e1bd3fa90da8174ee8f
2014-10-28 13:18:16 +09:00
Tadashi G. Takaoka 7a3de4dca9 Add null analysis annotation to CollectionUtils
Change-Id: I3a610b037d6d1431cced3ea193171108bd5a040d
2014-10-27 18:30:29 +09:00
Keisuke Kuroyanagi 3844f74aff Fix: deleted PtNode handling in v403.
If a word is once deleted, the word never gets into the
personalized dictionaries due to this bug.

Change-Id: Ife4e3fe1ba0615b4135e6291d2151b0db7d3f940
2014-10-27 15:32:05 +09:00
Jean Chalard 9afac3319c Merge "Add tests for type through recorrection" 2014-10-24 06:43:20 +00:00
Ken Wakasa 9342484e8d Move Constants.java to the latin.common package
Our intention is to have classes of latinime-common under the common
package as much as we can.

Change-Id: I76efbbbe7bebf1a4aa943715cdff64f91675e20d
2014-10-23 20:27:37 +09:00
Tadashi G. Takaoka 92d073c2fd Remove unused import and method
Bug: 18003991
Change-Id: Id6b67bf66b397301e5186826dba2b60df9cb4c65
2014-10-23 16:37:07 +09:00
Keisuke Kuroyanagi 16cc3992d7 Use trigrams for personalization dict.
5Bug: 14425059
Change-Id: I73cf6904e569d60996a3b079f16ea6df0cb90f02
2014-10-23 14:32:45 +09:00
Tadashi G. Takaoka d3a4c51324 Fix Javadoc and null analysis related warnings
This CL also adds @SuppressWarning("unused" to java-overridable package.

Bug: 18003991
Change-Id: If70527e30654384705d7a814f5efd181d9f539e1
2014-10-23 09:58:42 +09:00
Ken Wakasa 54a1b8ec54 Add latinime-common local lib
This is just a placeholder in this CL. It will be shared by LatinIME,
dicttool, and tests.

Change-Id: I6fb3516a5061555f6f24b29141c2871d2319b023
2014-10-22 19:26:21 +09:00
Jean Chalard 7e930bfb3a Add tests for type through recorrection
Also introduce some helper methods

Change-Id: I0f99733a4b7f0318b2b07217b614c19ea98859fc
2014-10-22 17:05:10 +09:00
Keisuke Kuroyanagi 1249395563 Merge "Support ngram entry migration." 2014-10-22 02:36:52 +00:00
Keisuke Kuroyanagi c9865785f4 Support ngram entry migration.
Bug: 14425059
Change-Id: I98cb9fa303af2d93a0a3512e8732231c564e3c5d
2014-10-22 11:31:16 +09:00
Tadashi G. Takaoka 5f00fe09e9 Fix some compiler warnings
This CL fixes the following compiler warnings.

- Indirect access to static member
- Access to a non-accessible member of an enclosing type
- Parameter assignment
- Method can be static
- Local variable declaration hides another field or variable
- Value of local variable is not used
- Unused import
- Unused private member
- Unnecessary 'else' statement
- Unnecessary declaration of throw exception
- Redundant type arguments
- Missing '@Override' annotation
- Unused '@SuppressWarning' annotations

Bug: 18003991
Change-Id: Icfebe753e53a2cc621848f769d6a3d7ce501ebc7
2014-10-21 19:28:37 +09:00
Adrian Velicu 05172bf1a5 Renaming "blacklist" flag to "possibly offensive"
No behaviour changes.
Unified the overloaded FusionDictionary::add method to always take an
isPossiblyOffensive argument.

Bug: 11031090
Change-Id: I5741a023ca1ce842d2cf10d4f6c926b0efabaa78
2014-10-21 11:51:47 +09:00
Keisuke Kuroyanagi 1085fef8d0 Change entry count limit.
Unigram 10K, Bigram 30K, Trigram 30K.

Change-Id: Ibd19c6a2b618499df1c70000bad7b47498187f0a
2014-10-20 15:01:49 +09:00
Keisuke Kuroyanagi f4928ad4dd Merge "Update useless n-gram entry detection logic during GC." 2014-10-15 21:44:45 +00:00
Keisuke Kuroyanagi 3601c214f8 Update useless n-gram entry detection logic during GC.
Bug: 14425059
Change-Id: Ib939deae5b60167751dee07965bb1ef1a43c4625
2014-10-15 20:43:27 +09:00
Jean Chalard 9ddbee8570 Add the first gesture unit tests.
At last I found a simple way to do it !

Bug: 8845843
Change-Id: I4dd3bf987b58e29a44cf0d7389d294657a33abe1
2014-10-15 19:04:06 +09:00
Sandeep Siddhartha b17a3bc4e8 Move sync policy related code out of account settings
Bug: 17981687
Bug: 17464069
Change-Id: I0ae3400564fd346cc84af74dfef65f01cc1ce6a8
2014-10-14 13:39:28 -07:00
Keisuke Kuroyanagi d1471ee053 Merge "Remove shouldBlockAutoCorrectionBySafetyNet" 2014-10-14 10:52:32 +00:00
Keisuke Kuroyanagi 29b4f7aa67 Remove shouldBlockAutoCorrectionBySafetyNet
Bug: 13756409

[Category diff]
+1      27
-1       0
+2       0
-2       0
+3       0
-3       1
+4      11
-4       0
+5      51
-5       0
+6       0
-6      38
+7       0
-7      50

[Weighted category diff]
+1      28
-1       0
+2       0
-2       0
+3       0
-3       1
+4      11
-4       0
+5      51
-5       0
+6       0
-6      39
+7       0
-7      50

show diff for ./en_user_log_phones_2011_08.csv
+1       4
+4       5
+5       7
-6       9
-7       7

The increase of false positives comes from the spaceless
typing test cases that are synthetic data.

Change-Id: I4ea77aa56ebfaa5518c71107169e1d2332de6327
2014-10-14 11:20:33 +09:00
Sandeep Siddhartha 19084d076a Cleanup LoginAccountUtils
Bug: 17464068
Change-Id: Icf994a7582491afebc5db522c127a30d079ce05c
2014-10-13 12:23:22 -07:00
Sandeep Siddhartha d9015233f5 Set up a sync preference and policy for syncing [2]
- Adds a preference for enabling sync, which controls the sync behavior
- Make the ProductionFlags depend on appropriate flags to guarantee that
  we don't mess things when flipping some flags
- Preferences now control the "syncable" property of the provider
  thereby controlling the policy and when this entry shows up in
  system settings.

Bug: 17464069
Change-Id: I1d58351188518c1ae9f1f9e147b5ea15d32a3427
2014-10-10 16:03:54 -07:00
Sandeep Siddhartha 1e10d29bc8 Don't restore device specific preferences
There are two categories of preferences:
1. That are part of the default shared preference
   They were all getting backed up and restored.
   Added a blacklist to not restore some of these.
   e.g. current account

2. That are in a non-default shared preference file.
   These are not getting backed up currently, but added a specific
   local preference file for all such preferences.

Bug: 17288591
Change-Id: I2f748be971a2337543e5014434aa39313fd1e1d8
2014-10-10 10:49:32 -07:00
Jatin Matani eaf517ffea Merge "Changes related Sync Engine library that communicates to cloud server" 2014-10-09 18:06:32 +00:00
Jean Chalard bc18005948 Always show the typed word in recorrections.
Bug: 11330140
Bug: 17875601
Bug: 17623275
Change-Id: Ie4620f36f312c54c7b01b5f6cbdb0bc9171b6179
2014-10-09 17:54:58 +09:00
Jatin Matani db1b736446 Changes related Sync Engine library that communicates to cloud server
This change updates some of the code that the library uses
to communicate with the cloud server
Specifically :
- Update BlockingHttpClient to use template ResponseProcessor
- Update HttpUrlConnectionBuilder to setAuthToken for HttpUrlConnection

Bug: 17464069
Bug: 17464805

Change-Id: I7d7b58dff594b920162f799d102e8582ff9fe6a4
2014-10-09 00:01:32 -07:00
Jean Chalard 81a5a10476 [ML19] Actually switch the language when appropriate
That is, when auto-correcting or when manually picking.
This is not great, but it's a good starting point.

Bug: 11230254
Change-Id: I07627f48e2de1c28053d6572c7c72625808ec79c
2014-10-09 13:13:25 +09:00
Jean Chalard 38ec825ef8 [ML16] Remove DictionaryFacilitator.getLocale()
Bug: 11230254
Change-Id: Ife99df42bc145fbd2d5c3128330bc0f88b104de9
2014-10-07 16:44:26 +09:00
Adrian Velicu 639837f85d Merge "Postponing memory deallocation after onFinishInputView" 2014-10-06 23:45:40 +00:00
Tadashi G. Takaoka 162ca68051 Remove preliminary subtypes from E-MR1 release
Note that unit test for Sinhala (Sri Lanka) and Tamil (Sri Lanka) have
been unexpectedly @suppressed.

Bug: 17743363
Change-Id: I4076a61adbf2d4aee58417d0c354b8ef4a938668
2014-10-06 23:42:14 +09:00
Adrian Velicu 7b8f317050 Postponing memory deallocation after onFinishInputView
Bug: 17559789
Change-Id: I1d4b1524028164d27ec4eadd3960b567148f2b84
2014-10-06 23:14:48 +09:00
Jean Chalard fcc4cbf6f1 Merge "[ML14] Forward the locale list to relevant places, again" 2014-10-06 13:32:32 +00:00
Jean Chalard bc051a561f [ML14] Forward the locale list to relevant places, again
Diff:
+++ b/java/src/com/android/inputmethod/keyboard/internal/KeyboardBuilder.java
@@ -735,7 +735,7 @@ public class KeyboardBuilder<KP extends KeyboardParams> {

     private boolean matchLocaleCodes(TypedArray caseAttr, final Locale[] locales) {
         // TODO: adujst this for multilingual input
-        return matchString(caseAttr, R.styleable.Keyboard_Case_languageCode, locales[0].toString());
+        return matchString(caseAttr, R.styleable.Keyboard_Case_localeCode, locales[0].toString());
     }

     private boolean matchLanguageCodes(TypedArray caseAttr, Locale[] locales) {

Change-Id: Icefac18dd6d5fea97f591177cf8df1ba6de7f4f0
2014-10-06 21:27:32 +09:00
Keisuke Kuroyanagi 1c2f00f6b5 Make sure to suppress BoS prediction until input twice.
Change-Id: I98d91f264d5d1d3f5bcda1fd9ec885779ba2f746
2014-10-06 19:36:04 +09:00
Keisuke Kuroyanagi ca17ed7d9d Fix: BoS prediction is shown after inputting just once.
Change-Id: Ibba209f47cb5b1a4b08281689d607711b8dcfad4
2014-10-06 19:28:39 +09:00
Keisuke Kuroyanagi 6accf63d0a Make unit tests use new entry updating method.
Bug: 14425059
Change-Id: Ie7d92e92822a0d3a8b654d213e55d45aab799f5d
2014-10-06 12:09:15 +09:00