Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3a3fad7d authored by Kshitij's avatar Kshitij
Browse files

fix: Add margin to hotseat, prevent clipping

parent 4ed17260
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -190,11 +190,16 @@ public class Hotseat extends CellLayout implements Insettable, OffsetParent {

    @Override
    protected void onLayout(boolean changed, int l, int t, int r, int b) {
        DeviceProfile dp = mActivity.getDeviceProfile();

        MarginLayoutParams lp = ((MarginLayoutParams) getLayoutParams());
        lp.leftMargin = -(dp.edgeMarginPx);
        lp.rightMargin = -(dp.edgeMarginPx);
        setLayoutParams(lp);
        super.onLayout(changed, l, t, r, b);

        int qsbMeasuredWidth = mQsb.getMeasuredWidth();
        int left;
        DeviceProfile dp = mActivity.getDeviceProfile();
        if (dp.isQsbInline) {
            int qsbSpace = dp.hotseatBorderSpace;
            left = Utilities.isRtl(getResources()) ? r - getPaddingRight() + qsbSpace