Merge pull request #570 from Helium314/patch-1

Invert space bar swipe direction for RTL languages
This commit is contained in:
Majeur 2022-03-21 11:06:52 +01:00 committed by GitHub
commit 08247bd887
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1393,6 +1393,10 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
@Override
public void onMovePointer(int steps) {
// for RTL languages we want to invert pointer movement
if (mRichImm.getCurrentSubtype().isRtlSubtype())
steps = -steps;
mInputLogic.finishInput();
if (steps < 0) {
int availableCharacters = mInputLogic.mConnection.getTextBeforeCursor(64, 0).length();