import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Paint;
+import android.graphics.Rect;
import android.util.AttributeSet;
import android.view.KeyEvent;
import android.view.MotionEvent;
}
@Override
+ protected boolean fitSystemWindows(Rect insets) {
+ if (getFitsSystemWindows()) {
+ setPadding(insets.left, insets.top, insets.right, insets.bottom);
+ } else {
+ setPadding(0, 0, 0, 0);
+ }
+ return true;
+ }
+
+ @Override
protected void onAttachedToWindow () {
super.onAttachedToWindow();