Compare commits

...

13 Commits

Author SHA1 Message Date
Yuriy Liskov
a4d615bbf2 persian fix 2018-08-29 15:59:25 +03:00
Yuriy Liskov
5e8e68de44 persian fix; enter in editor fix 2018-08-20 16:05:06 +03:00
Yuriy Liskov
48e12a21d1 ESC fix #2 2018-08-10 18:42:20 +03:00
Yuriy Liskov
6a8b9c63e5 ESC and Go fixes (see github > issues) 2018-08-07 20:39:07 +03:00
Yuriy Liskov
95ab858296 bugfixes 2018-08-04 18:19:57 +03:00
Yuriy Liskov
37243e4d11 hide soft kbd on physical key 2018-08-03 19:00:34 +03:00
Yuriy Liskov
0c7052be55 Swedish translate fix 2018-07-19 00:02:24 +03:00
Yuriy Liskov
5bf9563011 Swedish translate fix 2018-07-18 22:25:27 +03:00
Yuriy Liskov
abe60af6a6 add bunch of the new translations 2018-07-18 21:31:24 +03:00
Yuriy Liskov
13bc09cfcd Swedish translation (early phase) 2018-07-18 18:18:50 +03:00
Yuriy Liskov
e53316842c fix2: remember selected kbd 2018-07-18 17:34:47 +03:00
Yuriy Liskov
c16cc2525a fix: remember selected kbd 2018-07-18 14:29:08 +03:00
Yuriy Liskov
a1f7c7959a add Swedish kbd 2018-07-08 23:13:43 +03:00
47 changed files with 574 additions and 84 deletions

View File

@@ -14,14 +14,14 @@ buildscript {
// https://stackoverflow.com/questions/20404476/how-to-define-common-android-properties-for-all-modules-using-gradle // https://stackoverflow.com/questions/20404476/how-to-define-common-android-properties-for-all-modules-using-gradle
// Gradle constants example: https://github.com/google/ExoPlayer // Gradle constants example: https://github.com/google/ExoPlayer
ext { ext {
compileSdkVersion = 27 compileSdkVersion = 26
buildToolsVersion = "27.0.3" buildToolsVersion = "26.0.2"
minSdkVersion = 14 minSdkVersion = 14
targetSdkVersion = 27 targetSdkVersion = 26
appCompatVersion = 'com.android.support:appcompat-v7:27.+' appCompatVersion = 'com.android.support:appcompat-v7:26.+'
espressoCoreVersion = 'com.android.support.test.espresso:espresso-core:2.2.2' espressoCoreVersion = 'com.android.support.test.espresso:espresso-core:2.2.2'
junitVersion = 'junit:junit:4.12' junitVersion = 'junit:junit:4.12'
supportVersion = 'com.android.support:support-v4:27.+' supportVersion = 'com.android.support:support-v4:26.+'
robolectricVersion = 'org.robolectric:robolectric:3.5.1' robolectricVersion = 'org.robolectric:robolectric:3.5.1'
crashlyticsVersion = 'com.crashlytics.sdk.android:crashlytics:2.8.0@aar' crashlyticsVersion = 'com.crashlytics.sdk.android:crashlytics:2.8.0@aar'
} }

View File

@@ -8,8 +8,8 @@ android {
applicationId "org.liskovsoft.leankeykeyboard.pro" applicationId "org.liskovsoft.leankeykeyboard.pro"
minSdkVersion project.properties.minSdkVersion minSdkVersion project.properties.minSdkVersion
targetSdkVersion project.properties.targetSdkVersion targetSdkVersion project.properties.targetSdkVersion
versionCode 62 versionCode 76
versionName "4.3.12" versionName "4.3.26"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

View File

@@ -14,7 +14,9 @@
<category android:name="android.intent.category.LEANBACK_LAUNCHER"/> <category android:name="android.intent.category.LEANBACK_LAUNCHER"/>
</intent-filter> </intent-filter>
</activity> </activity>
<service android:label="@string/ime_service_name" android:name="com.google.leanback.ime.LeanbackImeService" android:permission="android.permission.BIND_INPUT_METHOD"> <service android:label="@string/ime_service_name"
android:name="com.google.leanback.ime.LeanbackImeService"
android:permission="android.permission.BIND_INPUT_METHOD">
<intent-filter> <intent-filter>
<action android:name="android.view.InputMethod"/> <action android:name="android.view.InputMethod"/>
</intent-filter> </intent-filter>

View File

@@ -166,7 +166,6 @@ public class LeanbackKeyboardContainer {
mAlphaIn = res.getFraction(R.fraction.alpha_in, 1, 1); mAlphaIn = res.getFraction(R.fraction.alpha_in, 1, 1);
mAlphaOut = res.getFraction(R.fraction.alpha_out, 1, 1); mAlphaOut = res.getFraction(R.fraction.alpha_out, 1, 1);
mVoiceAnimator = new LeanbackKeyboardContainer.VoiceIntroAnimator(mVoiceEnterListener, mVoiceExitListener); mVoiceAnimator = new LeanbackKeyboardContainer.VoiceIntroAnimator(mVoiceEnterListener, mVoiceExitListener);
initKeyboards();
mRootView = (RelativeLayout) mContext.getLayoutInflater().inflate(R.layout.root_leanback, null); mRootView = (RelativeLayout) mContext.getLayoutInflater().inflate(R.layout.root_leanback, null);
mKeyboardsContainer = mRootView.findViewById(R.id.keyboard); mKeyboardsContainer = mRootView.findViewById(R.id.keyboard);
mSuggestionsBg = mRootView.findViewById(R.id.candidate_background); mSuggestionsBg = mRootView.findViewById(R.id.candidate_background);
@@ -208,6 +207,7 @@ public class LeanbackKeyboardContainer {
LeanbackKeyboardContainer.this.cancelVoiceRecording(); LeanbackKeyboardContainer.this.cancelVoiceRecording();
} }
}); });
initKeyboards();
} }
private void configureFocus(LeanbackKeyboardContainer.KeyFocus focus, Rect rect, int index, int type) { private void configureFocus(LeanbackKeyboardContainer.KeyFocus focus, Rect rect, int index, int type) {
@@ -320,10 +320,10 @@ public class LeanbackKeyboardContainer {
* Init currently displayed keyboard<br/> * Init currently displayed keyboard<br/>
* Note: all keyboard settings applied here<br/> * Note: all keyboard settings applied here<br/>
* Note: this method is called constantly on new field * Note: this method is called constantly on new field
* @param resources resources (not used) * @param res resources (not used)
* @param info current ime attributes * @param info current ime attributes
*/ */
private void setImeOptions(Resources resources, EditorInfo info) { private void setImeOptions(Resources res, EditorInfo info) {
// do not erase last keyboard // do not erase last keyboard
if (mInitialMainKeyboard == null) { if (mInitialMainKeyboard == null) {
mInitialMainKeyboard = mAbcKeyboard; mInitialMainKeyboard = mAbcKeyboard;
@@ -868,7 +868,7 @@ public class LeanbackKeyboardContainer {
setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH); setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH);
return true; return true;
} else if (keyCode == LeanbackKeyboardView.ASCII_SPACE) { } else if (keyCode == LeanbackKeyboardView.ASCII_SPACE) {
switchToNextKeyboard(); onLangKeyPress();
setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH); setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH);
return true; return true;
} else if (keyCode == LeanbackKeyboardView.KEYCODE_LANG_TOGGLE) { } else if (keyCode == LeanbackKeyboardView.KEYCODE_LANG_TOGGLE) {
@@ -1117,20 +1117,23 @@ public class LeanbackKeyboardContainer {
* Switch to next keyboard (looped). * Switch to next keyboard (looped).
* {@link KeyboardManager KeyboardManager} is the source behind all keyboard implementations * {@link KeyboardManager KeyboardManager} is the source behind all keyboard implementations
*/ */
public void switchToNextKeyboard() { public void onLangKeyPress() {
switchToNextKeyboard();
showRunOnceDialog();
}
private void switchToNextKeyboard() {
LeanbackKeyboardView keyboardView = mMainKeyboardView; LeanbackKeyboardView keyboardView = mMainKeyboardView;
Keyboard keyboard = mKeyboardManager.getNextKeyboard(); Keyboard keyboard = mKeyboardManager.getNextKeyboard();
mInitialMainKeyboard = keyboard; mInitialMainKeyboard = keyboard;
mAbcKeyboard = keyboard; mAbcKeyboard = keyboard;
keyboardView.setKeyboard(keyboard); keyboardView.setKeyboard(keyboard);
showRunOnceDialog();
} }
public void updateAddonKeyboard() { public void updateAddonKeyboard() {
KeyboardManager manager = new KeyboardManager(mContext, mAbcKeyboard); mKeyboardManager = new KeyboardManager(mContext, mAbcKeyboard);
mKeyboardManager = manager; switchToNextKeyboard();
mInitialMainKeyboard = manager.getNextKeyboard();
} }
public void updateSuggestions(ArrayList<String> suggestions) { public void updateSuggestions(ArrayList<String> suggestions) {
@@ -1158,7 +1161,7 @@ public class LeanbackKeyboardContainer {
} }
public void onLangKeyClick() { public void onLangKeyClick() {
switchToNextKeyboard(); onLangKeyPress();
// setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH); // setTouchState(LeanbackKeyboardContainer.TOUCH_STATE_NO_TOUCH);
} }

View File

@@ -5,6 +5,7 @@ import android.graphics.Rect;
import android.inputmethodservice.InputMethodService; import android.inputmethodservice.InputMethodService;
import android.inputmethodservice.Keyboard.Key; import android.inputmethodservice.Keyboard.Key;
import android.os.Handler; import android.os.Handler;
import android.support.annotation.NonNull;
import android.text.InputType; import android.text.InputType;
import android.util.Log; import android.util.Log;
import android.view.KeyEvent; import android.view.KeyEvent;
@@ -30,6 +31,7 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
private static final int KEY_CHANGE_HISTORY_SIZE = 10; private static final int KEY_CHANGE_HISTORY_SIZE = 10;
private static final long KEY_CHANGE_REVERT_TIME_MS = 100L; private static final long KEY_CHANGE_REVERT_TIME_MS = 100L;
private static final String TAG = "LbKbController"; private static final String TAG = "LbKbController";
public static final String TAG_GO = "Go";
private boolean clickConsumed; private boolean clickConsumed;
private long lastClickTime; private long lastClickTime;
private LeanbackKeyboardContainer mContainer; private LeanbackKeyboardContainer mContainer;
@@ -51,6 +53,8 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
private LeanbackKeyboardController.TouchEventListener mTouchEventListener; private LeanbackKeyboardController.TouchEventListener mTouchEventListener;
private long prevTime; private long prevTime;
private boolean mShowInput; private boolean mShowInput;
private int mLastEditorIdPhysicalKeyboardWasUsed;
private boolean mHideKeyboardWhenPhysicalKeyboardUsed = true;
public LeanbackKeyboardController(final InputMethodService context, final LeanbackKeyboardController.InputListener listener) { public LeanbackKeyboardController(final InputMethodService context, final LeanbackKeyboardController.InputListener listener) {
this(context, listener, new TouchNavSpaceTracker(), new LeanbackKeyboardContainer(context)); this(context, listener, new TouchNavSpaceTracker(), new LeanbackKeyboardContainer(context));
@@ -108,7 +112,7 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
private boolean applyLETVFixesUp(int keyCode) { private boolean applyLETVFixesUp(int keyCode) {
switch (keyCode) { switch (keyCode) {
case KeyEvent.KEYCODE_MENU: case KeyEvent.KEYCODE_MENU:
this.mContainer.switchToNextKeyboard(); this.mContainer.onLangKeyPress();
break; break;
case KeyEvent.KEYCODE_MEDIA_PLAY_PAUSE: case KeyEvent.KEYCODE_MEDIA_PLAY_PAUSE:
this.fakeKeyIndex(0, 2); this.fakeKeyIndex(0, 2);
@@ -151,14 +155,19 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
this.commitKey(this.mContainer.getCurrFocus()); this.commitKey(this.mContainer.getCurrFocus());
} }
/**
* NOTE: where all magic happens. Input from virtual kbd is processed here.
* @param focus current key
*/
private void commitKey(LeanbackKeyboardContainer.KeyFocus focus) { private void commitKey(LeanbackKeyboardContainer.KeyFocus focus) {
if (mContainer != null && focus != null) { if (mContainer != null && focus != null) {
switch (focus.type) { switch (focus.type) {
case KeyFocus.TYPE_VOICE: case KeyFocus.TYPE_VOICE:
mContainer.onVoiceClick(); mContainer.onVoiceClick();
return; return;
case KeyFocus.TYPE_ACTION: case KeyFocus.TYPE_ACTION: // NOTE: user presses Go, Send, Search etc
mInputListener.onEntry(InputListener.ENTRY_TYPE_ACTION, 0, null); mInputListener.onEntry(InputListener.ENTRY_TYPE_ACTION, 0, null);
// mContext.hideWindow(); // SmartYouTubeTV fix: force hide keyboard
return; return;
case KeyFocus.TYPE_SUGGESTION: case KeyFocus.TYPE_SUGGESTION:
mInputListener.onEntry(InputListener.ENTRY_TYPE_SUGGESTION, 0, mContainer.getSuggestionText(focus.index)); mInputListener.onEntry(InputListener.ENTRY_TYPE_SUGGESTION, 0, mContainer.getSuggestionText(focus.index));
@@ -434,7 +443,8 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
private boolean handleKeyUpEvent(int keyCode, long currTime) { private boolean handleKeyUpEvent(int keyCode, long currTime) {
keyCode = getSimplifiedKey(keyCode); keyCode = getSimplifiedKey(keyCode);
boolean handled; boolean handled;
if (keyCode == KeyEvent.KEYCODE_BACK) {
if (keyCode == KeyEvent.KEYCODE_BACK || keyCode == KeyEvent.KEYCODE_ESCAPE) {
handled = false; handled = false;
} else if (mContainer.isVoiceVisible()) { } else if (mContainer.isVoiceVisible()) {
handled = true; handled = true;
@@ -604,7 +614,7 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
Button button = mContainer.getGoButton(); Button button = mContainer.getGoButton();
button.setOnTouchListener(this); button.setOnTouchListener(this);
button.setOnHoverListener(this); button.setOnHoverListener(this);
button.setTag("Go"); button.setTag(TAG_GO);
return view; return view;
} else { } else {
return null; return null;
@@ -647,7 +657,12 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
* @param event {@link KeyEvent KeyEvent} * @param event {@link KeyEvent KeyEvent}
* @return is event handled * @return is event handled
*/ */
public boolean onKeyDown(int keyCode, KeyEvent event) { public boolean onKeyDown(int keyCode, @NonNull KeyEvent event) {
//greater than zero means it is a physical keyboard.
//we also want to hide the view if it's a glyph (for example, not physical volume-up key)
//if (event.getDeviceId() > 0 && event.isPrintingKey()) onPhysicalKeyboardKeyPressed();
if (event.isPrintingKey()) onPhysicalKeyboardKeyPressed();
mDownFocus.set(mContainer.getCurrFocus()); mDownFocus.set(mContainer.getCurrFocus());
if (mSpaceTracker != null && mSpaceTracker.onKeyDown(keyCode, event)) { if (mSpaceTracker != null && mSpaceTracker.onKeyDown(keyCode, event)) {
return true; return true;
@@ -663,6 +678,24 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
} }
} }
private void onPhysicalKeyboardKeyPressed() {
EditorInfo editorInfo = mContext.getCurrentInputEditorInfo();
mLastEditorIdPhysicalKeyboardWasUsed = editorInfo == null ? 0 : editorInfo.fieldId;
if (mHideKeyboardWhenPhysicalKeyboardUsed) {
mContext.hideWindow();
}
// For all other keys, if we want to do transformations on
// text being entered with a hard keyboard, we need to process
// it and do the appropriate action.
// using physical keyboard is more annoying with candidate view in
// the way
// so we disable it.
// stopping any soft-keyboard prediction
//abortCorrectionAndResetPredictionState(false);
}
public boolean onKeyUp(int keyCode, KeyEvent keyEvent) { public boolean onKeyUp(int keyCode, KeyEvent keyEvent) {
if (mSpaceTracker != null && mSpaceTracker.onKeyUp(keyCode, keyEvent)) { if (mSpaceTracker != null && mSpaceTracker.onKeyUp(keyCode, keyEvent)) {
return true; return true;
@@ -718,31 +751,37 @@ public class LeanbackKeyboardController implements LeanbackKeyboardContainer.Voi
@Override @Override
public boolean onTouch(View view, MotionEvent event) { public boolean onTouch(View view, MotionEvent event) {
Object tag = view.getTag(); Object tag = view.getTag();
if (tag != null && "Go".equals(tag)) { boolean isEnterKey = TAG_GO.equals(tag);
fakeKeyIndex(0, KeyFocus.TYPE_ACTION); switch (event.getAction()) {
} else { case MotionEvent.ACTION_DOWN:
switch (event.getAction()) { if (isEnterKey) {
case MotionEvent.ACTION_DOWN:
moveSelectorToPoint(event.getX(), event.getY());
fakeClickDown();
beginLongClickCountdown();
break; break;
case MotionEvent.ACTION_UP: }
if (!clickConsumed) {
clickConsumed = true;
if (isDoubleClick()) {
mContainer.onKeyLongPress();
break;
}
fakeClickUp(); moveSelectorToPoint(event.getX(), event.getY());
fakeClickDown();
beginLongClickCountdown();
break;
case MotionEvent.ACTION_UP:
if (isEnterKey) {
fakeKeyIndex(0, KeyFocus.TYPE_ACTION);
break;
}
if (!clickConsumed) {
clickConsumed = true;
if (isDoubleClick()) {
mContainer.onKeyLongPress();
break;
} }
fakeLongClickUp(); fakeClickUp();
break; }
default:
return false; fakeLongClickUp();
} break;
default:
return false;
} }
return true; return true;

View File

@@ -1,6 +1,7 @@
package com.google.leanback.ime; package com.google.leanback.ime;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.app.Service;
import android.content.Intent; import android.content.Intent;
import android.inputmethodservice.InputMethodService; import android.inputmethodservice.InputMethodService;
import android.os.Handler; import android.os.Handler;
@@ -161,8 +162,15 @@ public class LeanbackImeService extends InputMethodService {
connection.commitText(text, 1); connection.commitText(text, 1);
mEnterSpaceBeforeCommitting = true; mEnterSpaceBeforeCommitting = true;
case InputListener.ENTRY_TYPE_ACTION: case InputListener.ENTRY_TYPE_ACTION: // NOTE: user presses Go, Send, Search etc
sendDefaultEditorAction(false); boolean result = sendDefaultEditorAction(true);
if (result) {
hideWindow(); // NOTE: SmartYouTubeTV hide kbd on search page fix
} else {
sendEnterKey(connection);
}
updateSuggestions = false; updateSuggestions = false;
break; break;
case InputListener.ENTRY_TYPE_LEFT: case InputListener.ENTRY_TYPE_LEFT:
@@ -210,6 +218,10 @@ public class LeanbackImeService extends InputMethodService {
} }
} }
private void sendEnterKey(InputConnection connection) {
connection.sendKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_ENTER));
}
@Override @Override
public View onCreateInputView() { public View onCreateInputView() {
mInputView = mKeyboardController.getView(); mInputView = mKeyboardController.getView();
@@ -271,14 +283,39 @@ public class LeanbackImeService extends InputMethodService {
@Override @Override
public boolean onKeyDown(int keyCode, KeyEvent event) { public boolean onKeyDown(int keyCode, KeyEvent event) {
// NOTE: hide keyboard on ESC key
// https://github.com/yuliskov/SmartYouTubeTV/issues/142
event = mapEscToBack(event);
keyCode = mapEscToBack(keyCode);
return isInputViewShown() && mKeyboardController.onKeyDown(keyCode, event) || super.onKeyDown(keyCode, event); return isInputViewShown() && mKeyboardController.onKeyDown(keyCode, event) || super.onKeyDown(keyCode, event);
} }
@Override @Override
public boolean onKeyUp(int keyCode, KeyEvent event) { public boolean onKeyUp(int keyCode, KeyEvent event) {
// NOTE: hide keyboard on ESC key
// https://github.com/yuliskov/SmartYouTubeTV/issues/142
event = mapEscToBack(event);
keyCode = mapEscToBack(keyCode);
return isInputViewShown() && mKeyboardController.onKeyUp(keyCode, event) || super.onKeyUp(keyCode, event); return isInputViewShown() && mKeyboardController.onKeyUp(keyCode, event) || super.onKeyUp(keyCode, event);
} }
private KeyEvent mapEscToBack(KeyEvent event) {
if (event.getKeyCode() == KeyEvent.KEYCODE_ESCAPE) {
// pay attention, you must pass the same action
event = new KeyEvent(event.getAction(), KeyEvent.KEYCODE_BACK);
}
return event;
}
private int mapEscToBack(int keyCode) {
if (keyCode == KeyEvent.KEYCODE_ESCAPE) {
keyCode = KeyEvent.KEYCODE_BACK;
}
return keyCode;
}
// FireTV fix // FireTV fix
//@Override //@Override
//public boolean onShowInputRequested(int flags, boolean configChange) { //public boolean onShowInputRequested(int flags, boolean configChange) {
@@ -298,7 +335,7 @@ public class LeanbackImeService extends InputMethodService {
} }
} }
return 1; return Service.START_STICKY;
} }
@Override @Override

View File

@@ -2,7 +2,7 @@ package com.liskovsoft.keyboardaddons;
import android.content.Context; import android.content.Context;
import android.inputmethodservice.Keyboard; import android.inputmethodservice.Keyboard;
import com.liskovsoft.keyboardaddons.reslangfactory.ResKeyboardFactory; import com.liskovsoft.keyboardaddons.reskbdfactory.ResKeyboardFactory;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
@@ -10,9 +10,11 @@ import java.util.List;
public class KeyboardManager { public class KeyboardManager {
private final Keyboard mEnglishKeyboard; private final Keyboard mEnglishKeyboard;
private final Context mContext; private final Context mContext;
private final KeyboardStateManager mStateManager;
private List<? extends KeyboardBuilder> mKeyboardBuilders; private List<? extends KeyboardBuilder> mKeyboardBuilders;
private List<Keyboard> mAllKeyboards; private List<Keyboard> mAllKeyboards;
private KeyboardFactory mKeyboardFactory; private KeyboardFactory mKeyboardFactory;
private int mKeyboardIndex = 0; private int mKeyboardIndex = 0;
public KeyboardManager(Context ctx, int keyboardResId) { public KeyboardManager(Context ctx, int keyboardResId) {
@@ -22,6 +24,8 @@ public class KeyboardManager {
public KeyboardManager(Context ctx, Keyboard englishKeyboard) { public KeyboardManager(Context ctx, Keyboard englishKeyboard) {
mContext = ctx; mContext = ctx;
mEnglishKeyboard = englishKeyboard; mEnglishKeyboard = englishKeyboard;
mStateManager = new KeyboardStateManager(mContext, this);
mStateManager.restore();
init(); init();
} }
@@ -42,6 +46,13 @@ public class KeyboardManager {
return keyboards; return keyboards;
} }
/**
* Performs callback to event handlers
*/
private void onNextKeyboard() {
mStateManager.onNextKeyboard();
}
/** /**
* Get next keyboard from internal source (looped) * Get next keyboard from internal source (looped)
* @return keyboard * @return keyboard
@@ -58,8 +69,18 @@ public class KeyboardManager {
throw new IllegalStateException(String.format("Keyboard %s not initialized", mKeyboardIndex)); throw new IllegalStateException(String.format("Keyboard %s not initialized", mKeyboardIndex));
} }
onNextKeyboard();
++mKeyboardIndex; ++mKeyboardIndex;
return kbd; return kbd;
} }
public int getKeyboardIndex() {
return mKeyboardIndex;
}
public void setKeyboardIndex(int idx) {
mKeyboardIndex = idx;
}
} }

View File

@@ -0,0 +1,25 @@
package com.liskovsoft.keyboardaddons;
import android.content.Context;
import com.liskovsoft.utils.LeanKeyPreferences;
public class KeyboardStateManager {
private final Context mContext;
private final KeyboardManager mManager;
private final LeanKeyPreferences mPrefs;
public KeyboardStateManager(Context context, KeyboardManager manager) {
mContext = context;
mManager = manager;
mPrefs = LeanKeyPreferences.instance(mContext);
}
public void restore() {
int idx = mPrefs.getKeyboardIndex();
mManager.setKeyboardIndex(idx);
}
public void onNextKeyboard() {
mPrefs.setKeyboardIndex(mManager.getKeyboardIndex());
}
}

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.addons; package com.liskovsoft.keyboardaddons.apkkbdfactory.addons;
import android.content.Context; import android.content.Context;
import android.support.annotation.NonNull; import android.support.annotation.NonNull;

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.addons; package com.liskovsoft.keyboardaddons.apkkbdfactory.addons;
import android.content.Context; import android.content.Context;
import android.content.pm.PackageManager.NameNotFoundException; import android.content.pm.PackageManager.NameNotFoundException;
@@ -23,7 +23,7 @@ import android.support.annotation.Nullable;
import android.support.v4.util.SparseArrayCompat; import android.support.v4.util.SparseArrayCompat;
import android.util.SparseIntArray; import android.util.SparseIntArray;
import com.liskovsoft.keyboardaddons.apklangfactory.utils.Logger; import com.liskovsoft.keyboardaddons.apkkbdfactory.utils.Logger;
import java.lang.ref.WeakReference; import java.lang.ref.WeakReference;
import java.util.Arrays; import java.util.Arrays;

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.addons; package com.liskovsoft.keyboardaddons.apkkbdfactory.addons;
import android.content.Context; import android.content.Context;
import android.content.Intent; import android.content.Intent;
@@ -27,7 +27,7 @@ import android.util.AttributeSet;
import android.util.Xml; import android.util.Xml;
//import com.liskovsoft.keyboardaddons.apklangfactory.AnySoftKeyboard; //import com.liskovsoft.keyboardaddons.apklangfactory.AnySoftKeyboard;
import com.liskovsoft.keyboardaddons.apklangfactory.utils.Logger; import com.liskovsoft.keyboardaddons.apkkbdfactory.utils.Logger;
import org.xmlpull.v1.XmlPullParser; import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException; import org.xmlpull.v1.XmlPullParserException;

View File

@@ -1,11 +1,11 @@
package com.liskovsoft.keyboardaddons.apklangfactory.addons; package com.liskovsoft.keyboardaddons.apkkbdfactory.addons;
import android.content.Context; import android.content.Context;
import android.content.res.Resources; import android.content.res.Resources;
import android.support.annotation.NonNull; import android.support.annotation.NonNull;
import android.util.SparseIntArray; import android.util.SparseIntArray;
import com.liskovsoft.keyboardaddons.apklangfactory.utils.Logger; import com.liskovsoft.keyboardaddons.apkkbdfactory.utils.Logger;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

View File

@@ -14,14 +14,14 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.keyboards; package com.liskovsoft.keyboardaddons.apkkbdfactory.keyboards;
import android.content.Context; import android.content.Context;
import android.support.annotation.Nullable; import android.support.annotation.Nullable;
import com.liskovsoft.keyboardaddons.KeyboardBuilder; import com.liskovsoft.keyboardaddons.KeyboardBuilder;
import com.liskovsoft.keyboardaddons.apklangfactory.addons.AddOn; import com.liskovsoft.keyboardaddons.apkkbdfactory.addons.AddOn;
import com.liskovsoft.keyboardaddons.apklangfactory.addons.AddOnImpl; import com.liskovsoft.keyboardaddons.apkkbdfactory.addons.AddOnImpl;
public class ApkKeyboardAddOnAndBuilder extends AddOnImpl implements KeyboardBuilder { public class ApkKeyboardAddOnAndBuilder extends AddOnImpl implements KeyboardBuilder {

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.keyboards; package com.liskovsoft.keyboardaddons.apkkbdfactory.keyboards;
import android.content.Context; import android.content.Context;
import android.content.SharedPreferences; import android.content.SharedPreferences;
@@ -25,9 +25,9 @@ import android.util.AttributeSet;
import com.liskovsoft.keyboardaddons.KeyboardBuilder; import com.liskovsoft.keyboardaddons.KeyboardBuilder;
import com.liskovsoft.keyboardaddons.KeyboardFactory; import com.liskovsoft.keyboardaddons.KeyboardFactory;
import com.liskovsoft.keyboardaddons.apklangfactory.addons.AddOn; import com.liskovsoft.keyboardaddons.apkkbdfactory.addons.AddOn;
import com.liskovsoft.keyboardaddons.apklangfactory.addons.AddOnsFactory; import com.liskovsoft.keyboardaddons.apkkbdfactory.addons.AddOnsFactory;
import com.liskovsoft.keyboardaddons.apklangfactory.utils.Logger; import com.liskovsoft.keyboardaddons.apkkbdfactory.utils.Logger;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

View File

@@ -1,4 +1,4 @@
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
public class BuildConfig { public class BuildConfig {
public final static boolean TESTING_BUILD = true; public final static boolean TESTING_BUILD = true;

View File

@@ -1,4 +1,4 @@
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
import android.os.Build; import android.os.Build;
import android.util.Log; import android.util.Log;

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
public interface LogProvider { public interface LogProvider {

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
import android.support.annotation.NonNull; import android.support.annotation.NonNull;

View File

@@ -1,4 +1,4 @@
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
/** /**
* Doesn't do anything. For release. * Doesn't do anything. For release.

View File

@@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
import android.util.Xml; import android.util.Xml;

View File

@@ -15,7 +15,7 @@
* limitations under the License. * limitations under the License.
*/ */
package com.liskovsoft.keyboardaddons.apklangfactory.utils; package com.liskovsoft.keyboardaddons.apkkbdfactory.utils;
import java.io.File; import java.io.File;
import java.io.FileWriter; import java.io.FileWriter;

View File

@@ -1,10 +1,10 @@
package com.liskovsoft.keyboardaddons.reslangfactory; package com.liskovsoft.keyboardaddons.reskbdfactory;
import android.inputmethodservice.Keyboard; import android.inputmethodservice.Keyboard;
import android.support.annotation.Nullable; import android.support.annotation.Nullable;
import com.liskovsoft.keyboardaddons.KeyboardBuilder; import com.liskovsoft.keyboardaddons.KeyboardBuilder;
public class ResKeyboardBuilder implements KeyboardBuilder { class ResKeyboardBuilder implements KeyboardBuilder {
@Nullable @Nullable
@Override @Override
public Keyboard createKeyboard() { public Keyboard createKeyboard() {

View File

@@ -1,4 +1,4 @@
package com.liskovsoft.keyboardaddons.reslangfactory; package com.liskovsoft.keyboardaddons.reskbdfactory;
import android.content.Context; import android.content.Context;
import android.content.res.Resources; import android.content.res.Resources;
@@ -7,7 +7,6 @@ import android.support.annotation.Nullable;
import com.liskovsoft.keyboardaddons.KeyboardBuilder; import com.liskovsoft.keyboardaddons.KeyboardBuilder;
import com.liskovsoft.keyboardaddons.KeyboardFactory; import com.liskovsoft.keyboardaddons.KeyboardFactory;
import com.liskovsoft.keyboardaddons.KeyboardInfo; import com.liskovsoft.keyboardaddons.KeyboardInfo;
import com.liskovsoft.leankeykeyboard.R;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

View File

@@ -1,4 +1,4 @@
package com.liskovsoft.keyboardaddons.reslangfactory; package com.liskovsoft.keyboardaddons.reskbdfactory;
import android.content.Context; import android.content.Context;
import android.content.SharedPreferences; import android.content.SharedPreferences;

View File

@@ -1,10 +1,10 @@
package com.liskovsoft.keyboardaddons.reslangfactory; package com.liskovsoft.keyboardaddons.reskbdfactory;
import com.liskovsoft.keyboardaddons.KeyboardInfo; import com.liskovsoft.keyboardaddons.KeyboardInfo;
import java.util.List; import java.util.List;
public class ResKeyboardManager { class ResKeyboardManager {
public List<KeyboardInfo> getAllKeyboardInfos() { public List<KeyboardInfo> getAllKeyboardInfos() {
return null; return null;
} }

View File

@@ -16,7 +16,7 @@ import android.view.Window;
import android.view.WindowManager; import android.view.WindowManager;
import android.widget.CheckedTextView; import android.widget.CheckedTextView;
import com.liskovsoft.keyboardaddons.KeyboardInfo; import com.liskovsoft.keyboardaddons.KeyboardInfo;
import com.liskovsoft.keyboardaddons.reslangfactory.ResKeyboardInfo; import com.liskovsoft.keyboardaddons.reskbdfactory.ResKeyboardInfo;
import com.liskovsoft.leankeykeyboard.R; import com.liskovsoft.leankeykeyboard.R;
import java.util.ArrayList; import java.util.ArrayList;

View File

@@ -7,6 +7,7 @@ import android.preference.PreferenceManager;
public final class LeanKeyPreferences { public final class LeanKeyPreferences {
private static final String APP_RUN_ONCE = "appRunOnce"; private static final String APP_RUN_ONCE = "appRunOnce";
private static final String BOOTSTRAP_SELECTED_LANGUAGE = "bootstrapSelectedLanguage"; private static final String BOOTSTRAP_SELECTED_LANGUAGE = "bootstrapSelectedLanguage";
private static final String APP_KEYBOARD_INDEX = "appKeyboardIndex";
private static LeanKeyPreferences sInstance; private static LeanKeyPreferences sInstance;
private final Context mContext; private final Context mContext;
private SharedPreferences mPrefs; private SharedPreferences mPrefs;
@@ -42,4 +43,15 @@ public final class LeanKeyPreferences {
String name = mPrefs.getString(BOOTSTRAP_SELECTED_LANGUAGE, ""); String name = mPrefs.getString(BOOTSTRAP_SELECTED_LANGUAGE, "");
return name; return name;
} }
public int getKeyboardIndex() {
int idx = mPrefs.getInt(APP_KEYBOARD_INDEX, 0);
return idx;
}
public void setKeyboardIndex(int idx) {
mPrefs.edit()
.putInt(APP_KEYBOARD_INDEX, idx)
.apply();
}
} }

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

View File

@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Leanback Keyboard</string>
<string name="ime_service_name">Leanback Keyboard</string>
<string name="word_separators">" .,;:!?
()[]*&amp;@{}/&lt;>_+=|"</string>
<string name="label_go_key">Go</string>
<string name="label_next_key">Next</string>
<string name="label_send_key">Send</string>
<string name="label_search_key">Search</string>
<string name="label_done_key">Done</string>
<string name="settings_title">Keyboard Options</string>
<string name="title_movement_sensitivity">Movement sensitivity</string>
<string name="btn_on">On</string>
<string name="btn_off">Off</string>
<string name="keyboardview_keycode_space">Space</string>
<string name="keyboardview_keycode_delete">Delete</string>
<string name="keyboardview_keycode_mode_change">Mode change</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Left</string>
<string name="keyboardview_keycode_right">Right</string>
<string name="keyboard_headset_required_to_hear_password">Plug in a headset to hear password keys spoken.</string>
<string name="keyboard_password_character_no_headset">Dot.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">لوحة مفاتيح Leanback</string>
<string name="ime_service_name">لوحة مفاتيح Leanback</string>
<string name="label_go_key">انتقال</string>
<string name="label_next_key">التالي</string>
<string name="label_send_key">إرسال</string>
<string name="label_search_key">بحث</string>
<string name="label_done_key">تم</string>
<string name="settings_title">خيارات لوحة المفاتيح</string>
<string name="title_movement_sensitivity">حساسية الحركة</string>
<string name="btn_on">تشغيل</string>
<string name="btn_off">إيقاف</string>
<string name="keyboardview_keycode_space">مسافة</string>
<string name="keyboardview_keycode_delete">حذف</string>
<string name="keyboardview_keycode_mode_change">تغيير الوضع</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">لليسار</string>
<string name="keyboardview_keycode_right">لليمين</string>
<string name="keyboard_headset_required_to_hear_password">يمكنك توصيل سماعة رأس لسماع مفاتيح كلمة المرور عندما يتم نطقها.</string>
<string name="keyboard_password_character_no_headset">نقطة</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Клавиатура за Leanback</string>
<string name="ime_service_name">Клавиатура за Leanback</string>
<string name="label_go_key">Старт</string>
<string name="label_next_key">Напред</string>
<string name="label_send_key">Изпращане</string>
<string name="label_search_key">Търсене</string>
<string name="label_done_key">Готово</string>
<string name="settings_title">Опции за клавиатурата</string>
<string name="title_movement_sensitivity">Чувствителност на движението</string>
<string name="btn_on">Включено</string>
<string name="btn_off">Изключено</string>
<string name="keyboardview_keycode_space">Space</string>
<string name="keyboardview_keycode_delete">Изтриване</string>
<string name="keyboardview_keycode_mode_change">Промяна на режима</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Left</string>
<string name="keyboardview_keycode_right">Right</string>
<string name="keyboard_headset_required_to_hear_password">Включете слушалки, за да чуете изговарянето на клавишите за паролата.</string>
<string name="keyboard_password_character_no_headset">Точка.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Leanback-Tastatur</string>
<string name="ime_service_name">Leanback-Tastatur</string>
<string name="label_go_key">Los</string>
<string name="label_next_key">Weiter</string>
<string name="label_send_key">Senden</string>
<string name="label_search_key">Suchen</string>
<string name="label_done_key">Fertig</string>
<string name="settings_title">Tastaturoptionen</string>
<string name="title_movement_sensitivity">Bewegungsempfindlichkeit</string>
<string name="btn_on">An</string>
<string name="btn_off">Aus</string>
<string name="keyboardview_keycode_space">Leertaste</string>
<string name="keyboardview_keycode_delete">Löschen</string>
<string name="keyboardview_keycode_mode_change">Modusänderung</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Feststelltaste</string>
<string name="keyboardview_keycode_left">Nach links</string>
<string name="keyboardview_keycode_right">Nach rechts</string>
<string name="keyboard_headset_required_to_hear_password">Schließen Sie ein Headset an, um das Passwort gesprochen zu hören.</string>
<string name="keyboard_password_character_no_headset">Punkt.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Πληκτρολόγιο Leanback</string>
<string name="ime_service_name">Πληκτρολόγιο Leanback</string>
<string name="label_go_key">Μετάβαση</string>
<string name="label_next_key">Επόμενο</string>
<string name="label_send_key">Αποστολή</string>
<string name="label_search_key">Αναζήτηση</string>
<string name="label_done_key">Τέλος</string>
<string name="settings_title">Επιλογές πληκτρολογίου</string>
<string name="title_movement_sensitivity">Ευαισθησία κίνησης</string>
<string name="btn_on">Ενεργοποίηση</string>
<string name="btn_off">Απενεργοποίηση</string>
<string name="keyboardview_keycode_space">Πλήκτρο διαστήματος</string>
<string name="keyboardview_keycode_delete">Διαγραφή</string>
<string name="keyboardview_keycode_mode_change">Αλλαγή τρόπου</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Αριστερά</string>
<string name="keyboardview_keycode_right">Δεξιά</string>
<string name="keyboard_headset_required_to_hear_password">Συνδέστε ακουστικά για να ακούσετε τα πλήκτρα του κωδικού πρόσβασης να εκφωνούνται.</string>
<string name="keyboard_password_character_no_headset">Τελεία.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">صفحه‌کلید Leanback</string>
<string name="ime_service_name">صفحه‌کلید Leanback</string>
<string name="label_go_key">برو</string>
<string name="label_next_key">بعدی</string>
<string name="label_send_key">ارسال</string>
<string name="label_search_key">جستجو</string>
<string name="label_done_key">انجام شد</string>
<string name="settings_title">گزینه‌های صفحه‌کلید</string>
<string name="title_movement_sensitivity">حساسیت حرکت</string>
<string name="btn_on">فعال</string>
<string name="btn_off">خاموش</string>
<string name="keyboardview_keycode_space">فاصله</string>
<string name="keyboardview_keycode_delete">حذف</string>
<string name="keyboardview_keycode_mode_change">تغییر حالت</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">چپ</string>
<string name="keyboardview_keycode_right">راست</string>
<string name="keyboard_headset_required_to_hear_password">هدست را برای شنیدن کلیدهای گذرواژه که خوانده می‌شوند، وصل کنید.</string>
<string name="keyboard_password_character_no_headset">نقطه.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Clavier Leanback</string>
<string name="ime_service_name">Clavier Leanback</string>
<string name="label_go_key">OK</string>
<string name="label_next_key">Suivant</string>
<string name="label_send_key">Envoyer</string>
<string name="label_search_key">Rechercher</string>
<string name="label_done_key">OK</string>
<string name="settings_title">Options de clavier</string>
<string name="title_movement_sensitivity">Sensibilité du déplacement</string>
<string name="btn_on">Activer</string>
<string name="btn_off">Désactiver</string>
<string name="keyboardview_keycode_space">Espace</string>
<string name="keyboardview_keycode_delete">Supprimer</string>
<string name="keyboardview_keycode_mode_change">Changement de mode</string>
<string name="keyboardview_keycode_shift">Maj</string>
<string name="keyboardview_keycode_caps">Verrouillage des majuscules</string>
<string name="keyboardview_keycode_left">Gauche</string>
<string name="keyboardview_keycode_right">Droite</string>
<string name="keyboard_headset_required_to_hear_password">"Branchez un casque pour entendre l'énoncé des touches lors de la saisie du mot de passe."</string>
<string name="keyboard_password_character_no_headset">Point.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Leanback lyklaborð</string>
<string name="ime_service_name">Leanback lyklaborð</string>
<string name="label_go_key">Áfram</string>
<string name="label_next_key">Næsta</string>
<string name="label_send_key">Senda</string>
<string name="label_search_key">Leita</string>
<string name="label_done_key">Lokið</string>
<string name="settings_title">Valkostir lyklaborðs</string>
<string name="title_movement_sensitivity">Hreyfinæmi</string>
<string name="btn_on">Kveikt</string>
<string name="btn_off">Slökkt</string>
<string name="keyboardview_keycode_space">Bil</string>
<string name="keyboardview_keycode_delete">Eyða</string>
<string name="keyboardview_keycode_mode_change">Breyta stillingu</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Hástafalás</string>
<string name="keyboardview_keycode_left">Vinstri</string>
<string name="keyboardview_keycode_right">Hægri</string>
<string name="keyboard_headset_required_to_hear_password">Tengdu heyrnartól til að heyra stafi aðgangsorðsins lesna upphátt.</string>
<string name="keyboard_password_character_no_headset">Punktur.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Tastiera Leanback</string>
<string name="ime_service_name">Tastiera Leanback</string>
<string name="label_go_key">Vai</string>
<string name="label_next_key">Avanti</string>
<string name="label_send_key">Invia</string>
<string name="label_search_key">Cerca</string>
<string name="label_done_key">Fine</string>
<string name="settings_title">Opzioni tastiera</string>
<string name="title_movement_sensitivity">Sensibilità movimento</string>
<string name="btn_on">Attiva</string>
<string name="btn_off">Disattiva</string>
<string name="keyboardview_keycode_space">Spazio</string>
<string name="keyboardview_keycode_delete">Elimina</string>
<string name="keyboardview_keycode_mode_change">Cambio modalità</string>
<string name="keyboardview_keycode_shift">Maiusc</string>
<string name="keyboardview_keycode_caps">Bloc Maiusc</string>
<string name="keyboardview_keycode_left">Sinistra</string>
<string name="keyboardview_keycode_right">Destra</string>
<string name="keyboard_headset_required_to_hear_password">Collega gli auricolari per ascoltare la pronuncia dei tasti premuti per la password.</string>
<string name="keyboard_password_character_no_headset">Punto.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Toetsenbord voor Leanback</string>
<string name="ime_service_name">Toetsenbord voor Leanback</string>
<string name="label_go_key">Gaan</string>
<string name="label_next_key">Volgende</string>
<string name="label_send_key">Verzenden</string>
<string name="label_search_key">Zoeken</string>
<string name="label_done_key">Gereed</string>
<string name="settings_title">Toetsenbordopties</string>
<string name="title_movement_sensitivity">Gevoeligheid beweging</string>
<string name="btn_on">Aan</string>
<string name="btn_off">Uit</string>
<string name="keyboardview_keycode_space">Spatiebalk</string>
<string name="keyboardview_keycode_delete">Verwijderen</string>
<string name="keyboardview_keycode_mode_change">Modus wijzigen</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Links</string>
<string name="keyboardview_keycode_right">Rechts</string>
<string name="keyboard_headset_required_to_hear_password">Sluit een headset aan om wachtwoordtoetsen te laten voorlezen.</string>
<string name="keyboard_password_character_no_headset">Stip.</string>
</resources>

View File

@@ -1,10 +1,25 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources>
<string name="label_go_key">Перейти</string> <string name="ime_name">Клавиатура Leanback</string>
<string name="label_next_key">Следующ</string> <string name="ime_service_name">Клавиатура Leanback</string>
<string name="label_send_key">Послать</string> <string name="label_go_key">ОК</string>
<string name="label_search_key">Искать</string> <string name="label_next_key">Далее</string>
<string name="label_send_key">Отправить</string>
<string name="label_search_key">Поиск</string>
<string name="label_done_key">Готово</string> <string name="label_done_key">Готово</string>
<string name="settings_title">Настройки клавиатуры</string>
<string name="title_movement_sensitivity">Обработка движений</string>
<string name="btn_on">ВКЛ</string>
<string name="btn_off">ВЫКЛ</string>
<string name="keyboardview_keycode_space">Пробел.</string>
<string name="keyboardview_keycode_delete">Удалить</string>
<string name="keyboardview_keycode_mode_change">Смена режима</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Стрелка влево</string>
<string name="keyboardview_keycode_right">Стрелка вправо</string>
<string name="keyboard_headset_required_to_hear_password">Подключите гарнитуру, чтобы услышать пароль.</string>
<string name="keyboard_password_character_no_headset">Точка</string>
<string name="language_dialog_title">Выберите дополнительные раскладки</string> <string name="language_dialog_title">Выберите дополнительные раскладки</string>
<string name="language_dialog_subtitle">Чтобы открыть этот диалог, зажмите кнопку \'земной шар\'</string> <string name="language_dialog_subtitle">Чтобы открыть этот диалог, зажмите кнопку \'земной шар\'</string>
</resources> </resources>

View File

@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Tangentbord för Leanback</string>
<string name="ime_service_name">Tangentbord för Leanback</string>
<string name="label_go_key">Kör</string>
<string name="label_next_key">Nästa</string>
<string name="label_send_key">Skicka</string>
<string name="label_search_key">Sök</string>
<string name="label_done_key">Klar</string>
<string name="settings_title">Tangentbordsinställningar</string>
<string name="title_movement_sensitivity">Rörelsekänslighet</string>
<string name="btn_on"></string>
<string name="btn_off">Av</string>
<string name="keyboardview_keycode_space">Blanksteg</string>
<string name="keyboardview_keycode_delete">Ta bort</string>
<string name="keyboardview_keycode_mode_change">Funktionsändring</string>
<string name="keyboardview_keycode_shift">Skift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Vänster</string>
<string name="keyboardview_keycode_right">Höger</string>
<string name="keyboard_headset_required_to_hear_password">Anslut hörlurar om du vill höra lösenordet tecken för tecken.</string>
<string name="keyboard_password_character_no_headset">Punkt.</string>
<string name="keyboardview_keycode_lang">Språk</string>
<string name="language_dialog_title">Välj layouter</string>
<string name="language_dialog_subtitle">"För att öppna dialogen nästa gång, tryck länge på knappen med världsikonen</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">แป้นพิมพ์ Leanback</string>
<string name="ime_service_name">แป้นพิมพ์ Leanback</string>
<string name="label_go_key">ไป</string>
<string name="label_next_key">ถัดไป</string>
<string name="label_send_key">ส่ง</string>
<string name="label_search_key">ค้นหา</string>
<string name="label_done_key">เสร็จสิ้น</string>
<string name="settings_title">ตัวเลือกแป้นพิมพ์</string>
<string name="title_movement_sensitivity">ความไวในการเคลื่อนที่</string>
<string name="btn_on">เปิด</string>
<string name="btn_off">ปิด</string>
<string name="keyboardview_keycode_space">วรรค</string>
<string name="keyboardview_keycode_delete">ลบ</string>
<string name="keyboardview_keycode_mode_change">เปลี่ยนโหมด</string>
<string name="keyboardview_keycode_shift">Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">ซ้าย</string>
<string name="keyboardview_keycode_right">ขวา</string>
<string name="keyboard_headset_required_to_hear_password">เสียบชุดหูฟังเพื่อฟังเสียงรหัสผ่าน</string>
<string name="keyboard_password_character_no_headset">เครื่องหมายจุด</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Leanback Klavyesi</string>
<string name="ime_service_name">Leanback Klavyesi</string>
<string name="label_go_key">Git</string>
<string name="label_next_key">İleri</string>
<string name="label_send_key">Gönder</string>
<string name="label_search_key">Ara</string>
<string name="label_done_key">Bitti</string>
<string name="settings_title">Klavye Seçenekleri</string>
<string name="title_movement_sensitivity">Hareket duyarlılığı</string>
<string name="btn_on"></string>
<string name="btn_off">Kapat</string>
<string name="keyboardview_keycode_space">Boşluk</string>
<string name="keyboardview_keycode_delete">Sil</string>
<string name="keyboardview_keycode_mode_change">Mod değiştir</string>
<string name="keyboardview_keycode_shift">ÜstKrktr</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Sol</string>
<string name="keyboardview_keycode_right">Sağ</string>
<string name="keyboard_headset_required_to_hear_password">Şifre tuşlarının sesli okunmasını dinlemek için mikrofonlu kulaklık takın.</string>
<string name="keyboard_password_character_no_headset">Nokta.</string>
</resources>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="ime_name">Клавіатура додатка Leanback</string>
<string name="ime_service_name">Клавіатура додатка Leanback</string>
<string name="label_go_key">ОК</string>
<string name="label_next_key">Далі</string>
<string name="label_send_key">Надіслати</string>
<string name="label_search_key">Пошук</string>
<string name="label_done_key">Готово</string>
<string name="settings_title">Параметри клавіатури</string>
<string name="title_movement_sensitivity">Чутливість руху</string>
<string name="btn_on">Увімкнути</string>
<string name="btn_off">Вимкнути</string>
<string name="keyboardview_keycode_space">Пробіл</string>
<string name="keyboardview_keycode_delete">Видалити</string>
<string name="keyboardview_keycode_mode_change">Зміна режиму</string>
<string name="keyboardview_keycode_shift">Клавіша Shift</string>
<string name="keyboardview_keycode_caps">Caps Lock</string>
<string name="keyboardview_keycode_left">Ліворуч</string>
<string name="keyboardview_keycode_right">Праворуч</string>
<string name="keyboard_headset_required_to_hear_password">Підключіть гарнітуру, щоб почути символи пароля.</string>
<string name="keyboard_password_character_no_headset">Крапка.</string>
</resources>

View File

@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources>
<string-array name="additional_languages"> <string-array name="additional_languages">
<item>Swedish|sv</item>
<item>Arabic|ar</item> <item>Arabic|ar</item>
<item>Bulgarian|bg</item> <item>Bulgarian|bg</item>
<item>Dutch|nl</item> <item>Dutch|nl</item>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Keyboard android:keyWidth="@dimen/key_width" android:keyHeight="@dimen/key_height" android:horizontalGap="@dimen/keyboard_horizontal_gap" android:verticalGap="@dimen/keyboard_vertical_gap"
xmlns:android="http://schemas.android.com/apk/res/android">
<Row>
<Key android:keyLabel="آ" />
</Row>
</Keyboard>

View File

@@ -37,7 +37,8 @@
<Key android:keyLabel="ی" /> <Key android:keyLabel="ی" />
<Key android:keyLabel="ب" /> <Key android:keyLabel="ب" />
<Key android:keyLabel="ل" /> <Key android:keyLabel="ل" />
<Key android:keyLabel="ا" /> <!-- fix from Shobair Mohammadi <shobairmohammadi@gmail.com> -->
<Key android:keyLabel="ا|آ" android:popupKeyboard="@xml/accent_fa_a" />
<Key android:keyLabel="ت" /> <Key android:keyLabel="ت" />
<Key android:keyLabel="ن" /> <Key android:keyLabel="ن" />
<Key android:keyLabel="م" /> <Key android:keyLabel="م" />

View File

@@ -56,7 +56,8 @@
<Row android:rowEdgeFlags="bottom"> <Row android:rowEdgeFlags="bottom">
<Key android:codes="-2" android:keyEdgeFlags="left" android:keyLabel="@string/keyboardview_keycode_mode_change" android:keyIcon="@drawable/ic_ime_symbols" /> <Key android:codes="-2" android:keyEdgeFlags="left" android:keyLabel="@string/keyboardview_keycode_mode_change" android:keyIcon="@drawable/ic_ime_symbols" />
<Key android:codes="-1" android:keyLabel="@string/keyboardview_keycode_shift" android:keyIcon="@drawable/ic_ime_shift_off" /> <Key android:codes="-1" android:keyLabel="@string/keyboardview_keycode_shift" android:keyIcon="@drawable/ic_ime_shift_off" />
<Key android:keyWidth="@dimen/space_key_width" android:codes="32" android:keyLabel="@string/keyboardview_keycode_space" android:keyIcon="@drawable/ic_ime_space" /> <Key android:codes="-9" android:keyLabel="@string/keyboardview_keycode_lang" android:keyIcon="@drawable/ic_ime_world" />
<Key android:keyWidth="@dimen/space_key_width" android:codes="32" android:keyLabel="@string/keyboardview_keycode_space" android:keyIcon="@drawable/ic_ime_space_sv" />
<Key android:codes="-3" android:keyLabel="@string/keyboardview_keycode_left" android:keyIcon="@drawable/ic_ime_left_arrow" /> <Key android:codes="-3" android:keyLabel="@string/keyboardview_keycode_left" android:keyIcon="@drawable/ic_ime_left_arrow" />
<Key android:codes="-4" android:keyEdgeFlags="right" android:keyLabel="@string/keyboardview_keycode_right" android:keyIcon="@drawable/ic_ime_right_arrow" /> <Key android:codes="-4" android:keyEdgeFlags="right" android:keyLabel="@string/keyboardview_keycode_right" android:keyIcon="@drawable/ic_ime_right_arrow" />
</Row> </Row>