Port moved height to android STK

This commit is contained in:
Benau
2020-07-12 08:34:59 +08:00
parent 8cc4dd3383
commit f4233977e5
12 changed files with 44 additions and 50 deletions

View File

@@ -36,6 +36,8 @@ public class SuperTuxKartActivity extends SDLActivity
// ------------------------------------------------------------------------
private native void saveKeyboardHeight(int height);
// ------------------------------------------------------------------------
private native void saveMovedHeight(int height);
// ------------------------------------------------------------------------
private native static void addDNSSrvRecords(String name, int weight);
// ------------------------------------------------------------------------
private void hideKeyboardNative(final boolean clear_text)
@@ -106,6 +108,7 @@ public class SuperTuxKartActivity extends SDLActivity
int margin = screen_height - m_bottom_y;
if (keyboard_height > margin)
moved_height = -keyboard_height + margin;
saveMovedHeight(-moved_height);
SDLActivity.moveView(moved_height);
}
});