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
90c072a5
Commit
90c072a5
authored
11 years ago
by
Jean Chalard
Committed by
Android (Google) Code Review
11 years ago
Browse files
Options
Downloads
Plain Diff
Merge "[IL105] Remove more useless arguments"
parents
362779d6
fa707576
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
java/src/com/android/inputmethod/latin/LatinIME.java
+6
-6
6 additions, 6 deletions
java/src/com/android/inputmethod/latin/LatinIME.java
java/src/com/android/inputmethod/latin/inputlogic/InputLogic.java
+2
-3
2 additions, 3 deletions
.../com/android/inputmethod/latin/inputlogic/InputLogic.java
with
8 additions
and
9 deletions
java/src/com/android/inputmethod/latin/LatinIME.java
+
6
−
6
View file @
90c072a5
...
...
@@ -189,7 +189,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
case
MSG_SHOW_GESTURE_PREVIEW_AND_SUGGESTION_STRIP:
if
(
msg
.
arg1
==
ARG1_NOT_GESTURE_INPUT
)
{
final
SuggestedWords
suggestedWords
=
(
SuggestedWords
)
msg
.
obj
;
latinIme
.
showSuggestionStrip
(
suggestedWords
,
suggestedWords
.
mTypedWord
);
latinIme
.
showSuggestionStrip
(
suggestedWords
);
}
else
{
latinIme
.
showGesturePreviewAndSuggestionStrip
((
SuggestedWords
)
msg
.
obj
,
msg
.
arg1
==
ARG1_DISMISS_GESTURE_FLOATING_PREVIEW_TEXT
);
...
...
@@ -1254,7 +1254,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
// This method must run on the UI Thread.
private
void
showGesturePreviewAndSuggestionStrip
(
final
SuggestedWords
suggestedWords
,
final
boolean
dismissGestureFloatingPreviewText
)
{
showSuggestionStrip
(
suggestedWords
,
suggestedWords
.
mTypedWord
);
showSuggestionStrip
(
suggestedWords
);
final
MainKeyboardView
mainKeyboardView
=
mKeyboardSwitcher
.
getMainKeyboardView
();
mainKeyboardView
.
showGestureFloatingPreviewText
(
suggestedWords
);
if
(
dismissGestureFloatingPreviewText
)
{
...
...
@@ -1390,8 +1390,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
}
// TODO[IL]: Define a clean interface for this
public
void
showSuggestionStrip
(
final
SuggestedWords
sourceSuggestedWords
,
final
String
typedWord
)
{
public
void
showSuggestionStrip
(
final
SuggestedWords
sourceSuggestedWords
)
{
final
SuggestedWords
suggestedWords
=
sourceSuggestedWords
.
isEmpty
()
?
SuggestedWords
.
EMPTY
:
sourceSuggestedWords
;
final
String
autoCorrection
;
...
...
@@ -1400,7 +1399,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
}
else
{
// We can't use suggestedWords.getWord(SuggestedWords.INDEX_OF_TYPED_WORD)
// because it may differ from mWordComposer.mTypedWord.
autoCorrection
=
t
ypedWord
;
autoCorrection
=
sourceSuggestedWords
.
mT
ypedWord
;
}
if
(
SuggestedWords
.
EMPTY
!=
suggestedWords
)
{
mInputLogic
.
mWordComposer
.
setAutoCorrection
(
autoCorrection
);
...
...
@@ -1408,7 +1407,8 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
setSuggestedWords
(
suggestedWords
,
isSuggestionsStripVisible
());
// Cache the auto-correction in accessibility code so we can speak it if the user
// touches a key that will insert it.
AccessibilityUtils
.
getInstance
().
setAutoCorrection
(
suggestedWords
,
typedWord
);
AccessibilityUtils
.
getInstance
().
setAutoCorrection
(
suggestedWords
,
sourceSuggestedWords
.
mTypedWord
);
}
// Called from {@link SuggestionStripView} through the {@link SuggestionStripView#Listener}
...
...
This diff is collapsed.
Click to expand it.
java/src/com/android/inputmethod/latin/inputlogic/InputLogic.java
+
2
−
3
View file @
90c072a5
...
...
@@ -1120,7 +1120,7 @@ public final class InputLogic {
final
SuggestedWords
suggestedWords
=
holder
.
get
(
null
,
Constants
.
GET_SUGGESTED_WORDS_TIMEOUT
);
if
(
suggestedWords
!=
null
)
{
mLatinIME
.
showSuggestionStrip
(
suggestedWords
,
suggestedWords
.
mTypedWord
);
mLatinIME
.
showSuggestionStrip
(
suggestedWords
);
}
}
...
...
@@ -1620,8 +1620,7 @@ public final class InputLogic {
mConnection
.
commitText
(
batchInputText
.
substring
(
0
,
indexOfLastSpace
),
1
);
final
SuggestedWords
suggestedWordsForLastWordOfPhraseGesture
=
suggestedWords
.
getSuggestedWordsForLastWordOfPhraseGesture
();
mLatinIME
.
showSuggestionStrip
(
suggestedWordsForLastWordOfPhraseGesture
,
suggestedWordsForLastWordOfPhraseGesture
.
mTypedWord
);
mLatinIME
.
showSuggestionStrip
(
suggestedWordsForLastWordOfPhraseGesture
);
}
final
String
lastWord
=
batchInputText
.
substring
(
indexOfLastSpace
);
mWordComposer
.
setBatchInputWord
(
lastWord
);
...
...
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