merge from open-source master

Change-Id: If72ad6758c9e1bf77c38c4afec6b00ec9d5b89e4
This commit is contained in:
The Android Open Source Project
2010-05-03 16:19:19 -07:00
4 changed files with 48 additions and 24 deletions

View File

@@ -1988,15 +1988,19 @@ public class InputMethodService extends AbstractInputMethodService {
ei.inputType != InputType.TYPE_NULL);
if (hasAction) {
mExtractAccessories.setVisibility(View.VISIBLE);
if (ei.actionLabel != null) {
mExtractAction.setText(ei.actionLabel);
} else {
mExtractAction.setText(getTextForImeAction(ei.imeOptions));
if (mExtractAction != null) {
if (ei.actionLabel != null) {
mExtractAction.setText(ei.actionLabel);
} else {
mExtractAction.setText(getTextForImeAction(ei.imeOptions));
}
mExtractAction.setOnClickListener(mActionClickListener);
}
mExtractAction.setOnClickListener(mActionClickListener);
} else {
mExtractAccessories.setVisibility(View.GONE);
mExtractAction.setOnClickListener(null);
if (mExtractAction != null) {
mExtractAction.setOnClickListener(null);
}
}
}