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
ebec5259
Commit
ebec5259
authored
13 years ago
by
Tadashi G. Takaoka
Browse files
Options
Downloads
Patches
Plain Diff
Get rid of LatinKeyboardParam class
Change-Id: I8376f4f570e72929679c5e4955986c48881abd75
parent
67394a39
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
java/src/com/android/inputmethod/keyboard/LatinKeyboard.java
+5
-32
5 additions, 32 deletions
java/src/com/android/inputmethod/keyboard/LatinKeyboard.java
with
5 additions
and
32 deletions
java/src/com/android/inputmethod/keyboard/LatinKeyboard.java
+
5
−
32
View file @
ebec5259
...
@@ -77,16 +77,16 @@ public class LatinKeyboard extends Keyboard {
...
@@ -77,16 +77,16 @@ public class LatinKeyboard extends Keyboard {
private
static
final
String
SMALL_TEXT_SIZE_OF_LANGUAGE_ON_SPACEBAR
=
"small"
;
private
static
final
String
SMALL_TEXT_SIZE_OF_LANGUAGE_ON_SPACEBAR
=
"small"
;
private
static
final
String
MEDIUM_TEXT_SIZE_OF_LANGUAGE_ON_SPACEBAR
=
"medium"
;
private
static
final
String
MEDIUM_TEXT_SIZE_OF_LANGUAGE_ON_SPACEBAR
=
"medium"
;
private
LatinKeyboard
(
Context
context
,
Latin
KeyboardParams
params
)
{
private
LatinKeyboard
(
Context
context
,
KeyboardParams
params
)
{
super
(
params
);
super
(
params
);
mRes
=
context
.
getResources
();
mRes
=
context
.
getResources
();
mTheme
=
context
.
getTheme
();
mTheme
=
context
.
getTheme
();
// The index of space key is available only after Keyboard constructor has finished.
// The index of space key is available only after Keyboard constructor has finished.
mSpaceKey
=
params
.
mSpaceKey
;
mSpaceKey
=
getKey
(
CODE_SPACE
)
;
mSpaceIcon
=
(
mSpaceKey
!=
null
)
?
mSpaceKey
.
getIcon
()
:
null
;
mSpaceIcon
=
(
mSpaceKey
!=
null
)
?
mSpaceKey
.
getIcon
()
:
null
;
mShortcutKey
=
params
.
mShortcutKey
;
mShortcutKey
=
getKey
(
CODE_SHORTCUT
)
;
mEnabledShortcutIcon
=
(
mShortcutKey
!=
null
)
?
mShortcutKey
.
getIcon
()
:
null
;
mEnabledShortcutIcon
=
(
mShortcutKey
!=
null
)
?
mShortcutKey
.
getIcon
()
:
null
;
final
int
longPressSpaceKeyTimeout
=
final
int
longPressSpaceKeyTimeout
=
mRes
.
getInteger
(
R
.
integer
.
config_long_press_space_key_timeout
);
mRes
.
getInteger
(
R
.
integer
.
config_long_press_space_key_timeout
);
...
@@ -105,36 +105,9 @@ public class LatinKeyboard extends Keyboard {
...
@@ -105,36 +105,9 @@ public class LatinKeyboard extends Keyboard {
a
.
recycle
();
a
.
recycle
();
}
}
private
static
class
LatinKeyboardParams
extends
KeyboardParams
{
public
static
class
Builder
extends
KeyboardBuilder
<
KeyboardParams
>
{
Key
mSpaceKey
=
null
;
Key
mShortcutKey
=
null
;
LatinKeyboardParams
()
{}
@Override
public
void
onAddKey
(
Key
key
)
{
super
.
onAddKey
(
key
);
switch
(
key
.
mCode
)
{
case
Keyboard
.
CODE_SPACE
:
mSpaceKey
=
key
;
break
;
case
Keyboard
.
CODE_SHORTCUT
:
mShortcutKey
=
key
;
break
;
}
}
}
public
static
class
Builder
extends
KeyboardBuilder
<
LatinKeyboardParams
>
{
public
Builder
(
Context
context
)
{
public
Builder
(
Context
context
)
{
super
(
context
,
new
LatinKeyboardParams
());
super
(
context
,
new
KeyboardParams
());
}
@Override
public
Builder
load
(
int
xmlId
,
KeyboardId
id
)
{
super
.
load
(
xmlId
,
id
);
return
this
;
}
}
@Override
@Override
...
...
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