mirror of
https://github.com/fankes/termux-app.git
synced 2025-09-07 03:05:18 +08:00
Merge pull request #132 from michalbednarski/extrakeysview-alignment
Make ExtraKeysView work on Android 5
This commit is contained in:
@@ -165,8 +165,8 @@ public final class ExtraKeysView extends GridLayout {
|
|||||||
param.rightMargin = param.topMargin = 0;
|
param.rightMargin = param.topMargin = 0;
|
||||||
param.setGravity(Gravity.LEFT);
|
param.setGravity(Gravity.LEFT);
|
||||||
float weight = "▲▼◀▶".contains(buttonText) ? 0.7f : 1.f;
|
float weight = "▲▼◀▶".contains(buttonText) ? 0.7f : 1.f;
|
||||||
param.columnSpec = GridLayout.spec(col, weight);
|
param.columnSpec = GridLayout.spec(col, GridLayout.FILL, weight);
|
||||||
param.rowSpec = GridLayout.spec(row, 1.f);
|
param.rowSpec = GridLayout.spec(row, GridLayout.FILL, 1.f);
|
||||||
button.setLayoutParams(param);
|
button.setLayoutParams(param);
|
||||||
|
|
||||||
addView(button);
|
addView(button);
|
||||||
|
Reference in New Issue
Block a user