Jean Chalard
251bb70f08
Cleanup (A5)
...
Change-Id: I06134145b47c46bbc6c340ca539f34a01e2ca163
2012-06-28 19:12:37 +09:00
Jean Chalard
4c4e3a0949
Transform the whitelist suggestion like the others (A4)
...
...instead of having a different code path
Change-Id: Icd177e2151e45d25300000d4b63d4fba1f52b6a8
2012-06-28 19:10:32 +09:00
Jean Chalard
33b3805e79
Small refactoring (A3)
...
This will help make upcoming changes clearer
Change-Id: Ida8d4935f7315e5da6007ad364124694da3112d0
2012-06-28 19:10:24 +09:00
Jean Chalard
b7cdafd78a
Don't pass everything to a function that needs only the head (A2)
...
Change-Id: Ic367836202ab8071c1a9a02eaf0651b0da947d51
2012-06-28 19:10:13 +09:00
Jean Chalard
09b30ac954
Merge "Use a TreeSet to sort suggestions instead of doing it by hand (A1)"
2012-06-28 03:08:26 -07:00
Jean Chalard
2d2e348033
Use a TreeSet to sort suggestions instead of doing it by hand (A1)
...
Change-Id: I16ba39321107e87ad48a99c2410a15995a66f23c
2012-06-28 18:54:14 +09:00
Tadashi G. Takaoka
69527d4d60
am 5e5cf045
: am 7f7947c9
: Keep subtypes in method.xml the same as pre-JellyBean
...
* commit '5e5cf045ca6debafcc29ae1c47afda4a3a152326':
Keep subtypes in method.xml the same as pre-JellyBean
2012-06-27 21:58:53 -07:00
Tadashi G. Takaoka
7f7947c97b
Keep subtypes in method.xml the same as pre-JellyBean
...
This change prevents Android Keyboard subtypes being mistakenly
disabled when upgrading from pre-JellyBean to JellyBean.
Bug: 6750906
Change-Id: I05de6c512e7aa17356e415476e5248986c7d4253
2012-06-28 13:44:09 +09:00
Jean Chalard
10abf10c1f
Convert local members to local variables
...
Change-Id: I852787986c79502a4de7effe9c8281a4cf2d519d
2012-06-27 19:54:29 +09:00
Jean Chalard
3ecb2747b3
Optimization.
...
It's useless to do this for all suggestions including those
that will be ousted from the list.
Change-Id: I7bd63d783e21984a269e4b1ae17e9b9d8c0859e3
2012-06-27 18:55:43 +09:00
Jean Chalard
3705ef407b
Read the suggestion type from the suggestion
...
...instead of dirtily passing it from the dictionary loop
Change-Id: I92ddbd7451609b69f6d4dc31bf89d614423b2016
2012-06-27 18:18:35 +09:00
Jean Chalard
24eec0fa68
Remember the source dictionary for each suggestion.
...
Change-Id: I3c63372bd5572a479a67eaecfe8c8ea1cabc70d9
2012-06-27 18:17:28 +09:00
Jean Chalard
d8f0caa406
Move constants to a better place.
...
Change-Id: I5c27a3ed99b17f850e26a8503de16f001c7111c1
2012-06-27 18:08:08 +09:00
Jean Chalard
089c11a086
Cleanup
...
Change-Id: I575f22330bf6881af1d9a35f22b51b7bf2198113
2012-06-27 17:59:58 +09:00
Jean Chalard
b5afd3de0c
Remove unused stuff.
...
Change-Id: Ifd0d5b6978f76b841574a6e10157c32d0cd656b6
2012-06-27 17:44:16 +09:00
Jean Chalard
05efe576f9
Cleanup the dictionary type.
...
Stop storing an int in each of the different class types, and
just store a string in the top class.
Change-Id: I2af1832743e6fe78e5c1364f6d9cc21252bf5831
2012-06-27 17:31:09 +09:00
Jean Chalard
c356df8e08
Merge "Update the prototype of onAddSuggestedWord - calling side."
2012-06-27 01:25:59 -07:00
Ken Wakasa
e55c23e4b0
Small cleanups
...
Change-Id: Ic1a198ab1b4f0323fde9e4245729fd0e6011b914
2012-06-27 16:54:37 +09:00
Jean Chalard
32ff2504a0
Update the prototype of onAddSuggestedWord - calling side.
...
We want to get rid of all those IDs in Latin IME.
Change-Id: Ibe08100a5e2976c80abb049889233b4047a686f3
2012-06-27 16:17:14 +09:00
Jean Chalard
2db27bcd06
Merge "Use binarySearch instead of a hand-written linear search"
2012-06-26 23:55:46 -07:00
Jean Chalard
78a8d5b6bc
Merge "Implement a comparator for SuggestedWordInfos."
2012-06-26 22:55:51 -07:00
Jean Chalard
56beb9e321
Use binarySearch instead of a hand-written linear search
...
Yay.
Change-Id: Icf686eb2d675da959f19edc856b521e6288dcea3
2012-06-27 14:17:29 +09:00
Jean Chalard
9da0027b38
Implement a comparator for SuggestedWordInfos.
...
Change-Id: Ic4b0ae05cd98a1aec5806c5e4b744158e73aea7a
2012-06-27 14:16:23 +09:00
Kurt Partridge
30447239e8
Merge "only output every kth word to log"
2012-06-26 20:49:03 -07:00
Jean Chalard
4ef01c51f8
Merge "Remove some special casing"
2012-06-26 20:33:43 -07:00
Kurt Partridge
e961188e9f
only output every kth word to log
...
multi-project CL with Ib5b544b9b2d8b0e4419238976b2e274e5ac564f8
Bug: 6188932
Change-Id: Iea68cf36924d6fda126130a98431a6ce02ba251e
2012-06-26 16:15:20 -07:00
Jean Chalard
7e49a2b6b8
Remove some special casing
...
This special casing is useless. If the word is the same as what
user typed, the scoring algorithm already ensures that it comes
out at the top. Actually, as is written in a comment here, code
executed later is actively relying on this suggestion having
the top score ! There is no need to test it for equalness and
inserting it at the top then.
Change-Id: I263a6de59b77ec72a2dcbb933361b8e16fca0681
2012-06-26 20:40:42 +09:00
Jean Chalard
a3f5f51ec4
Fix a bug where a log would mysteriously not work
...
Change-Id: I5ca77ed65e95a6d357215c0e730238fb463986bb
2012-06-26 20:36:51 +09:00
Jean Chalard
22657dcba0
Optimization.
...
We already had that computed
Change-Id: I2a9742eaee2e9db1f73aeddda7bae7e237b4d15c
2012-06-26 20:02:07 +09:00
Jean Chalard
ec8b27fe49
Cut out a method for clarity
...
Change-Id: I1dc668698a5cd840297e713a26a525f5e32d35d6
2012-06-26 19:49:01 +09:00
Jean Chalard
0131170da9
Merge "Avoid string conversions when possible."
2012-06-26 03:48:01 -07:00
Jean Chalard
5953dc93cf
Avoid string conversions when possible.
...
Change-Id: Ibf5f3e40da55998364d0d835ecf283f32c80fcf5
2012-06-26 19:45:52 +09:00
Jean Chalard
5d218bc029
Merge "Simplify a method call."
2012-06-26 03:45:02 -07:00
Jean Chalard
bed514bd90
Simplify a method call.
...
Change-Id: Ieede787a13cef79353f13af52488ef3732ac9850
2012-06-26 19:33:16 +09:00
Jean Chalard
61c1002b6b
Merge "Refactor and squash long-standing bugs (A2)"
2012-06-26 03:19:20 -07:00
Tadashi G. Takaoka
abf81192ff
Merge "Remove unnecessary variables"
2012-06-26 03:16:17 -07:00
Tadashi G. Takaoka
342ea3d324
Merge "Pass MotionEvent to PointerTracker"
2012-06-26 03:16:12 -07:00
Jean Chalard
9433ce86b7
Refactor and squash long-standing bugs (A2)
...
This is awesome.
- Improve performance by stopping useless string/array conversions.
- Simplify method interface.
- Fix localization bugs - we now know our locale
- Fix bugs with surrogate code points
Bug: 4769095
Change-Id: I8a8ee224b713429ee0a4ce5bd52f1b63378cf56f
2012-06-26 19:12:07 +09:00
Tadashi G. Takaoka
3314d38daf
Pass MotionEvent to PointerTracker
...
This is a one of groundwork to integrate gesture input.
Change-Id: I5b75c6978b51df91fdc384a9f6d1d5a5ddc563e2
2012-06-26 19:05:47 +09:00
Jean Chalard
a8c9946b44
Merge "Remember the locale in the Suggest object (A1)"
2012-06-26 03:05:05 -07:00
Tadashi G. Takaoka
7bb8e95b52
Merge "Cleanup PointerTracker debug method"
2012-06-26 03:03:49 -07:00
Tadashi G. Takaoka
0d9d37cec2
Remove unnecessary variables
...
Bug: 6722052
Change-Id: I92e85b3e49b8f4b228f0cf0994216c5050e0865c
2012-06-26 19:01:59 +09:00
Jean Chalard
8e17f6d93a
Remember the locale in the Suggest object (A1)
...
This will be necessary for uppercasing and titlecasing words
correctly.
Change-Id: I0f446a4c82bc482240ff730a2ad6586a61571d6b
2012-06-26 18:55:18 +09:00
Jean Chalard
6cad198d9c
Remove a useless member (A2)
...
Change-Id: Ia727ffc2946352bbf79e0c97684f8fa98f428cef
2012-06-26 18:42:06 +09:00
Jean Chalard
0da9a7c094
Convert a member to a local variable (A1)
...
Change-Id: I9eab910989443704f83711cf4fb0070c5987a13a
2012-06-26 18:41:49 +09:00
Tadashi G. Takaoka
d7edd1cbb5
Cleanup PointerTracker debug method
...
Change-Id: Ib3bfa0a46f5814a6df838005d7243e2f536a98a0
2012-06-26 18:36:30 +09:00
Jean Chalard
f05392f213
Remove an unused method (A22)
...
Change-Id: I2195f365df1799c8b3b2a53670d1df535ab1a742
2012-06-26 17:59:04 +09:00
Jean Chalard
6234be1fe7
Simplification and optimization (A20)
...
Change-Id: Ia837e553ccfe67cd4303096290194a5186df059b
2012-06-26 17:59:04 +09:00
Jean Chalard
77e95e60bb
Preparation for a simplification (A19)
...
Change-Id: I4605a571faf5fbc68b18ce525d6019600bfa8cf7
2012-06-26 17:59:04 +09:00
Jean Chalard
0a79446531
Remove a meaningless separation (A18)
...
Change-Id: I267177044c7d7b0d9119839a11057b2bbf41f75f
2012-06-26 17:59:04 +09:00
Jean Chalard
61e7ec6587
Remove the Callback interface for simpler code. (A17)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: I009b54fc2e73cadca6734bdca074d033e81f6a2b
2012-06-26 17:58:52 +09:00
Jean Chalard
2f1b6c9ea4
Remove the callback argument to getBigrams() (A16)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: I7457ac04f8cd4019fb86c986725aae3de1b1a65e
2012-06-26 17:54:49 +09:00
Jean Chalard
60eed92dc3
Remove the callback argument to getWords() (A15)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: I919bf70a1213ab5d7c7a9e5715bd72a6e257148b
2012-06-26 17:36:47 +09:00
Jean Chalard
2225b3bace
Do away with Utils#addAllSuggestions (A14)
...
It's not used any more.
Change-Id: Id9da40fdbf7078f3ac647d1368237d6601f5a2ba
2012-06-26 17:36:47 +09:00
Jean Chalard
d9df8094e6
Neutralize AndroidSpellChecker.SuggestionsGatherer#addWords (A13)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: Ia54e1e44e1fd4e8ba2c9316928c0595cbe3f933c
2012-06-26 17:36:47 +09:00
Jean Chalard
7830476022
Neutralize Suggest#addWords (A12)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: Id923367342a62a650a5f1d38e2fa0e913030dca8
2012-06-26 17:36:47 +09:00
Jean Chalard
fd998bd37a
Refactoring (A11)
...
Change-Id: I86bd7587dd80773a51ba6db312ba55dc41e7c8c7
2012-06-26 17:36:47 +09:00
Jean Chalard
64dad2d5a9
Remove an unused method and inline another (A10)
...
Change-Id: Ifd71ce79711b0c15c7764e97351dbb1b8e4c0c2d
2012-06-26 17:36:47 +09:00
Jean Chalard
d522ddefc2
Merge "Merge the interface of two methods that do the same thing (A9)"
2012-06-26 01:35:15 -07:00
Jean Chalard
90981e423a
Merge "Change the return type of getWords and getBigrams (A8)"
2012-06-26 01:33:04 -07:00
Jean Chalard
9053862470
Merge "Remove dependency on WordCallback from BinaryDictionary (A7)"
2012-06-26 01:16:43 -07:00
Jean Chalard
b9f99c8679
Merge "Remove useless code and storage (A6)"
2012-06-26 01:16:32 -07:00
Jean Chalard
8fb0ff00b1
Merge "Remove a duplicate processing (A5)"
2012-06-26 01:16:19 -07:00
Tadashi G. Takaoka
1c6a9cc44d
Merge "Update current key reference in PointerTracker when keyboard is changed"
2012-06-26 00:58:16 -07:00
Jean Chalard
28eeb35d14
Merge the interface of two methods that do the same thing (A9)
...
Change-Id: Ia5701d713d0fd5bb646b54a03a1a5602dad0a9e6
2012-06-26 16:55:09 +09:00
Jean Chalard
d82898c5a9
Change the return type of getWords and getBigrams (A8)
...
This only returns stuff, but it doesn't change yet how the data
is really passed. It merely adds a way of getting the same data.
Later, the old way will be removed.
Change-Id: If3a064de362175fc5a6781b7a97b65d8730aaf3c
2012-06-26 16:44:26 +09:00
Jean Chalard
bda7eaa63a
Remove dependency on WordCallback from BinaryDictionary (A7)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: I8245698fbd170e0f5cbad3c0109774bcaddc0614
2012-06-26 16:42:48 +09:00
Jean Chalard
17111afcd6
Remove useless code and storage (A6)
...
This is only used as temporary storage to be then added to
the other variable, relying on the fact that it is hopefully
sorted. It's better to just add it right away to the final
storage.
Change-Id: I5da702ac9dc579593ab21feb2021a01e5dfdf4dc
2012-06-26 16:39:32 +09:00
Jean Chalard
5e0545d69d
Remove a duplicate processing (A5)
...
This filtering is already done in native code. It's useless (and
costly) to do it again here.
Change-Id: Ide6794d7a8682a881f097f33e222f10d30f297bd
2012-06-26 16:37:05 +09:00
Jean Chalard
fac8a16c6f
Merge "Remove another dependency to WordCallback (A4)"
2012-06-25 23:31:39 -07:00
Tadashi G. Takaoka
8a092b4ede
Update current key reference in PointerTracker when keyboard is changed
...
This change also checks that the current key is the same key that
started the key repeat, when key repeat timer is fired.
Bug: 6722052
Change-Id: Id69880ded3338a5a3cbe7f8bf951f94f2651119c
2012-06-26 15:00:12 +09:00
Kurt Partridge
3ec249c6d1
Merge "fix IllegalOutOfBoundsException"
2012-06-25 22:52:36 -07:00
Kurt Partridge
01106f6a10
fix IllegalOutOfBoundsException
...
StringUtils.toCodePointArray() had thrown IllegalOutOfBoundsException if
passed an empty string. change to just return an empty int[].
Bug: 6188932
Change-Id: Ic41c628c0d407f49fc98cd48cb7ea13d8d5bdd77
2012-06-25 22:40:56 -07:00
Jean Chalard
d7b9e8f503
Remove another dependency to WordCallback (A4)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: I5b277124dc9244e78c4a1f4d542a55071eb479bd
2012-06-26 13:12:01 +09:00
Ken Wakasa
9f78eed456
Remove "Key popup dismiss delay" when "Popup on keypress" is suppressed
...
bug: 6714783
Change-Id: Idf674e8e1af80642f2c53f7ae5c03e21c9e04292
2012-06-26 00:40:53 +09:00
Satoshi Kataoka
7368009799
Change JNI for Gesture
...
Change-Id: I774a0052038d16677f60f7efa11fd266cb5f3088
2012-06-25 18:54:37 +09:00
Jean Chalard
5a73d72265
Merge "Refactoring and groundwork to fix a bug with older apps"
2012-06-25 00:42:21 -07:00
Jean Chalard
c3ebf1a43a
Refactoring and groundwork to fix a bug with older apps
...
This has a good, although small, impact on performance : it removes
a two-way IPC call in a most frequent case, while possibly adding
one in a rather unfrequent and less critical case.
Also, this fixes a bug with surrogate pairs. This specific branch
of code now correctly handles surrogate pairs.
Aside from this, it should have no impact on behavior.
However, since it does delay access to the previous character in
the text view by a two-way IPC call, it actually goes a long way
toward fixing bug#6668226. It is not really a fix and the race
condition still exists, but this change makes it much, much
harder to hit.
Bug: 6668226
Change-Id: Id11cc6a0b7488d6bd392227cafdcf3a8d4c62f6c
2012-06-25 16:32:25 +09:00
Jean Chalard
a316a15984
Merge "Tentatively remove a dependency on WordCallback (A3)"
2012-06-24 23:08:13 -07:00
Jean Chalard
dc01bd5ea4
Merge "Improve compatibility for ICS."
2012-06-24 20:41:19 -07:00
Satoshi Kataoka
2cf265b345
Merge "Fix possible NPE from a concurrent problem in LatinIME"
2012-06-21 22:16:48 -07:00
Kurt Partridge
e6a39d5677
Merge "Allow punctuation through privacy filter"
2012-06-21 21:53:48 -07:00
Kurt Partridge
33d9f9b6db
Allow punctuation through privacy filter
...
Also cleaned up the privacy code a bit.
multi-project commit with Change-Id: Ic0919a6929ebb2623ff4124f7adc96d9e5f8df3c
Bug: 6188932
Change-Id: Id470fe7cc6e4a8fb01f1ea5b178a74cd27d59218
2012-06-21 00:17:48 -07:00
Jean Chalard
1b71ff00a2
Merge "Update an outdated comment"
2012-06-20 20:18:51 -07:00
Jean Chalard
9997b44846
Improve compatibility for ICS.
...
ICS didn't have a SHORTCUT column in the user dictionary.
If running on a build under JellyBean, we should not ask
for it lest we crash.
Bug: 6600617
Change-Id: Iac0cbcc63c10064f01e2d51eec5931fd9cdd0922
2012-06-20 18:43:56 -07:00
Jean Chalard
83f4a9866a
Cleanup, part 10 : remove from the code obsolete options (C10)
...
Change-Id: Id0806ad3dc7ccb632713eebaca76f0bab26ece5d
2012-06-21 10:07:05 +09:00
Jean Chalard
7c406ed655
Tentatively remove a dependency on WordCallback (A3)
...
Bug: 6252660
Bug: 6166228
Bug: 2704000
Bug: 6225530
Change-Id: Id5a59eaec2aeefa0ba4524420a8e035d383f6545
2012-06-21 10:03:44 +09:00
Jean Chalard
e8bb8351d6
Cleanup, part 9 (C9)
...
Change-Id: Ifb15553824915d0634aea83689302c2418b093f3
2012-06-21 09:22:32 +09:00
Jean Chalard
ca6b7d5265
Cleanup, part 8 (C8)
...
Change-Id: Iecc9b3d43c191614c2951408e14085cb77eefd4d
2012-06-20 03:45:40 +09:00
Jean Chalard
2f3a694e29
Cleanup, part 7 (C7)
...
Change-Id: I662be9d3b31fb9e157722f38cab1e6fb8a1152ab
2012-06-20 03:17:33 +09:00
Jean Chalard
0e8b1db948
Merge "Cleanup, part 6 (C6)"
2012-06-19 09:25:33 -07:00
Jean Chalard
c03bd090ea
Merge "Cleanup, part 4 (C4)"
2012-06-19 09:24:25 -07:00
Jean Chalard
bd765d3355
Merge "Cleanup, part 3 (C3)"
2012-06-19 09:24:00 -07:00
Jean Chalard
b821b72aa1
Merge "Remove a member (B5)"
2012-06-19 09:15:57 -07:00
Satoshi Kataoka
67b9337b6c
Fix possible NPE from a concurrent problem in LatinIME
...
Bug: 6620746
Change-Id: Icc18de92d7edc6888c712c2cf5ce479a65f8bfad
2012-06-19 03:34:45 +09:00
Svetoslav Ganov
808ba7b8f8
am e6730ac0
: am 5e4df66f
: Merge "Removing implementation of unnecessary APIs taken out of the support lib." into jb-dev
...
* commit 'e6730ac0e89de1cd81b92412751ec3950d8befb4':
Removing implementation of unnecessary APIs taken out of the support lib.
2012-06-18 11:31:43 -07:00
Svetoslav Ganov
5e4df66fce
Merge "Removing implementation of unnecessary APIs taken out of the support lib." into jb-dev
2012-06-18 11:28:04 -07:00
Jean Chalard
b0561ae980
Remove a member (B5)
...
The new call in the test ensures getCurrentInputEditorInfo actually
works.
Change-Id: I2ee407bd9927d22db537d12f339e2b977a38054a
2012-06-19 03:27:37 +09:00
Jean Chalard
56523ce0bf
Merge "Simplification (B4)"
2012-06-18 10:55:59 -07:00
Jean Chalard
64e52051cf
Simplification (B4)
...
Change-Id: Id5abf722a533980ed2d89381dbddc0a71b6f5b6b
2012-06-19 02:54:13 +09:00