mirror of
https://github.com/yuliskov/LeanKeyboard.git
synced 2026-06-11 09:04:17 -04:00
bugfix
This commit is contained in:
@@ -14,8 +14,8 @@ android {
|
||||
applicationId "org.liskovsoft.leankeykeyboard.pro"
|
||||
minSdkVersion project.properties.minSdkVersion
|
||||
targetSdkVersion project.properties.targetSdkVersion
|
||||
versionCode 135
|
||||
versionName "5.2.35"
|
||||
versionCode 136
|
||||
versionName "5.2.36"
|
||||
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
|
||||
|
||||
@@ -34,9 +34,7 @@
|
||||
|
||||
<activity
|
||||
android:name="com.liskovsoft.leankeyboard.activity.settings.KbSettingsActivity"
|
||||
android:launchMode="singleTop"
|
||||
android:screenOrientation="landscape"
|
||||
android:configChanges="orientation|keyboardHidden">
|
||||
android:launchMode="singleTop">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
@@ -47,9 +45,7 @@
|
||||
</activity>
|
||||
<activity
|
||||
android:name="com.liskovsoft.leankeyboard.activity.settings.KbLayoutActivity"
|
||||
android:launchMode="singleTop"
|
||||
android:screenOrientation="landscape"
|
||||
android:configChanges="orientation|keyboardHidden">
|
||||
android:launchMode="singleTop">
|
||||
</activity>
|
||||
<activity
|
||||
android:name="com.liskovsoft.leankeyboard.activity.PermissionsActivity"
|
||||
|
||||
@@ -28,6 +28,7 @@ import android.view.animation.DecelerateInterpolator;
|
||||
import android.view.animation.Interpolator;
|
||||
import android.view.animation.Transformation;
|
||||
import android.view.inputmethod.EditorInfo;
|
||||
import android.view.inputmethod.InputConnection;
|
||||
import android.widget.Button;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.HorizontalScrollView;
|
||||
@@ -1135,20 +1136,20 @@ public class LeanbackKeyboardContainer {
|
||||
}
|
||||
|
||||
private void fillSuggestions(ArrayList<String> suggestions) {
|
||||
String editorText = LeanbackUtils.getEditorText(mContext.getCurrentInputConnection());
|
||||
InputConnection connection = mContext.getCurrentInputConnection();
|
||||
|
||||
if (editorText.isEmpty()) {
|
||||
editorText = mLabel;
|
||||
}
|
||||
if (connection != null) {
|
||||
String editorText = LeanbackUtils.getEditorText(connection);
|
||||
|
||||
if (editorText == null) {
|
||||
return;
|
||||
}
|
||||
if (editorText.isEmpty()) {
|
||||
editorText = mLabel;
|
||||
}
|
||||
|
||||
if (suggestions.size() == 0) {
|
||||
suggestions.add(editorText);
|
||||
} else {
|
||||
suggestions.set(0, editorText);
|
||||
if (suggestions.size() == 0) {
|
||||
suggestions.add(editorText);
|
||||
} else {
|
||||
suggestions.set(0, editorText);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user