Merge "Pass the touch event in the top padding of keyboard."
This commit is contained in:
commit
dbf4f2a552
1 changed files with 6 additions and 0 deletions
|
@ -132,6 +132,7 @@ public class KeyboardBuilder<KP extends KeyboardParams> {
|
|||
private int mCurrentY = 0;
|
||||
private Row mCurrentRow = null;
|
||||
private boolean mLeftEdge;
|
||||
private boolean mTopEdge;
|
||||
private Key mRightEdgeKey = null;
|
||||
private final KeyStyles mKeyStyles = new KeyStyles();
|
||||
|
||||
|
@ -650,6 +651,7 @@ public class KeyboardBuilder<KP extends KeyboardParams> {
|
|||
|
||||
private void startKeyboard() {
|
||||
mCurrentY += mParams.mTopPadding;
|
||||
mTopEdge = true;
|
||||
}
|
||||
|
||||
private void startRow(Row row) {
|
||||
|
@ -670,6 +672,7 @@ public class KeyboardBuilder<KP extends KeyboardParams> {
|
|||
setSpacer(mCurrentX, mParams.mHorizontalEdgesPadding);
|
||||
mCurrentY += mCurrentRow.mRowHeight;
|
||||
mCurrentRow = null;
|
||||
mTopEdge = false;
|
||||
}
|
||||
|
||||
private void endKey(Key key) {
|
||||
|
@ -678,6 +681,9 @@ public class KeyboardBuilder<KP extends KeyboardParams> {
|
|||
key.addEdgeFlags(Keyboard.EDGE_LEFT);
|
||||
mLeftEdge = false;
|
||||
}
|
||||
if (mTopEdge) {
|
||||
key.addEdgeFlags(Keyboard.EDGE_TOP);
|
||||
}
|
||||
mRightEdgeKey = key;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue