Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LatinIME
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
keyboard
LatinIME
Commits
e0d06fa7
Commit
e0d06fa7
authored
12 years ago
by
Tadashi G. Takaoka
Committed by
Android (Google) Code Review
12 years ago
Browse files
Options
Downloads
Plain Diff
Merge "Use InputMethodInfo.getSubtypeAt() to list all subtype in test"
parents
1bdc2ca1
52d50f9b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/src/com/android/inputmethod/latin/InputLogicFrenchTests.java
+0
-2
0 additions, 2 deletions
.../com/android/inputmethod/latin/InputLogicFrenchTests.java
tests/src/com/android/inputmethod/latin/InputTestsBase.java
+8
-5
8 additions, 5 deletions
tests/src/com/android/inputmethod/latin/InputTestsBase.java
with
8 additions
and
7 deletions
tests/src/com/android/inputmethod/latin/InputLogicFrenchTests.java
+
0
−
2
View file @
e0d06fa7
...
...
@@ -16,8 +16,6 @@
package
com.android.inputmethod.latin
;
import
com.android.inputmethod.keyboard.Keyboard
;
public
class
InputLogicFrenchTests
extends
InputTestsBase
{
public
void
testAutoCorrectForFrench
()
{
...
...
This diff is collapsed.
Click to expand it.
tests/src/com/android/inputmethod/latin/InputTestsBase.java
+
8
−
5
View file @
e0d06fa7
...
...
@@ -138,17 +138,20 @@ public class InputTestsBase extends ServiceTestCase<LatinIME> {
final
InputMethodManager
imm
=
(
InputMethodManager
)
mLatinIME
.
getSystemService
(
Context
.
INPUT_METHOD_SERVICE
);
final
String
packageName
=
mLatinIME
.
getPackageName
();
for
(
final
InputMethodInfo
imi
:
imm
.
getEnabledInputMethodList
())
{
// The IMEs and subtypes don't need to be enabled to run this test because IMF isn't
// involved here.
for
(
final
InputMethodInfo
imi
:
imm
.
getInputMethodList
())
{
if
(
imi
.
getPackageName
().
equals
(
packageName
))
{
for
(
final
InputMethodSubtype
ims
:
imm
.
getEnabledInputMethodSubtypeList
(
imi
,
true
))
{
final
int
subtypeCount
=
imi
.
getSubtypeCount
();
for
(
int
i
=
0
;
i
<
subtypeCount
;
i
++)
{
final
InputMethodSubtype
ims
=
imi
.
getSubtypeAt
(
i
);
final
String
locale
=
ims
.
getLocale
();
mSubtypeMap
.
put
(
locale
,
ims
);
}
return
;
}
}
fail
(
"LatinIME is
disable
d"
);
fail
(
"LatinIME is
not foun
d"
);
}
// We need to run the messages added to the handler from LatinIME. The only way to do
...
...
@@ -176,7 +179,7 @@ public class InputTestsBase extends ServiceTestCase<LatinIME> {
// The only way to get out of Looper#loop() is to call #quit() on it (or on its queue).
// Once #quit() is called remaining messages are not processed, which is why we post
// a message that calls it instead of calling it directly.
l
ooper
.
loop
();
L
ooper
.
loop
();
// Once #quit() has been called, the message queue has an "mQuiting" field that prevents
// any subsequent post in this queue. However the queue itself is still fully functional!
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment