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
6cad198d
Commit
6cad198d
authored
12 years ago
by
Jean Chalard
Browse files
Options
Downloads
Patches
Plain Diff
Remove a useless member (A2)
Change-Id: Ia727ffc2946352bbf79e0c97684f8fa98f428cef
parent
0da9a7c0
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
java/src/com/android/inputmethod/latin/Suggest.java
+6
-7
6 additions, 7 deletions
java/src/com/android/inputmethod/latin/Suggest.java
with
6 additions
and
7 deletions
java/src/com/android/inputmethod/latin/Suggest.java
+
6
−
7
View file @
6cad198d
...
...
@@ -86,8 +86,6 @@ public class Suggest {
private
float
mAutoCorrectionThreshold
;
private
CharSequence
mConsideredWord
;
// TODO: Remove these member variables by passing more context to addWord() callback method
private
boolean
mIsFirstCharCapitalized
;
private
boolean
mIsAllUpperCase
;
...
...
@@ -228,7 +226,6 @@ public class Suggest {
:
typedWord
;
// Treating USER_TYPED as UNIGRAM suggestion for logging now.
LatinImeLogger
.
onAddSuggestedWord
(
typedWord
,
Suggest
.
DIC_USER_TYPED
,
Dictionary
.
UNIGRAM
);
mConsideredWord
=
consideredWord
;
if
(
wordComposer
.
size
()
<=
1
&&
isCorrectionEnabled
)
{
// At first character typed, search only the bigrams
...
...
@@ -251,7 +248,8 @@ public class Suggest {
for
(
final
SuggestedWordInfo
suggestion
:
localSuggestions
)
{
final
String
suggestionStr
=
suggestion
.
mWord
.
toString
();
addWord
(
suggestionStr
.
toCharArray
(),
null
,
0
,
suggestionStr
.
length
(),
suggestion
.
mScore
,
dicTypeId
,
Dictionary
.
BIGRAM
,
suggestions
);
suggestion
.
mScore
,
dicTypeId
,
Dictionary
.
BIGRAM
,
suggestions
,
consideredWord
);
}
}
}
...
...
@@ -277,7 +275,8 @@ public class Suggest {
for
(
final
SuggestedWordInfo
suggestion
:
localSuggestions
)
{
final
String
suggestionStr
=
suggestion
.
mWord
.
toString
();
addWord
(
suggestionStr
.
toCharArray
(),
null
,
0
,
suggestionStr
.
length
(),
suggestion
.
mScore
,
dicTypeId
,
Dictionary
.
UNIGRAM
,
suggestions
);
suggestion
.
mScore
,
dicTypeId
,
Dictionary
.
UNIGRAM
,
suggestions
,
consideredWord
);
}
}
}
...
...
@@ -387,14 +386,14 @@ public class Suggest {
// TODO: Use codepoint instead of char
public
boolean
addWord
(
final
char
[]
word
,
int
[]
indices
,
final
int
offset
,
final
int
length
,
int
score
,
final
int
dicTypeId
,
final
int
dataType
,
final
ArrayList
<
SuggestedWordInfo
>
suggestions
)
{
final
ArrayList
<
SuggestedWordInfo
>
suggestions
,
final
String
consideredWord
)
{
int
dataTypeForLog
=
dataType
;
final
int
prefMaxSuggestions
=
MAX_SUGGESTIONS
;
int
pos
=
0
;
// Check if it's the same word, only caps are different
if
(
StringUtils
.
equalsIgnoreCase
(
mC
onsideredWord
,
word
,
offset
,
length
))
{
if
(
StringUtils
.
equalsIgnoreCase
(
c
onsideredWord
,
word
,
offset
,
length
))
{
// TODO: remove this surrounding if clause and move this logic to
// getSuggestedWordBuilder.
if
(
suggestions
.
size
()
>
0
)
{
...
...
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