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

Commit 4d227268 authored by Maurice Lam's avatar Maurice Lam
Browse files

Remove top padding only if illustration is present

Bug: 28469515
Change-Id: Ifc41b09b2b1675b696291753ff68fe4a801c76c2
parent aee8d8c7
Loading
Loading
Loading
Loading
+7 −4
Original line number Diff line number Diff line
@@ -35,6 +35,7 @@ import android.widget.TextView;

import com.android.settings.R;
import com.android.setupwizardlib.SetupWizardLayout;
import com.android.setupwizardlib.view.Illustration;

import java.text.NumberFormat;
import java.util.List;
@@ -119,11 +120,13 @@ public abstract class StorageWizardBase extends Activity {
        scrollView.setVerticalFadingEdgeEnabled(true);
        scrollView.setFadingEdgeLength(scrollView.getVerticalFadingEdgeLength() * 2);

        // Our header assets already have padding baked in
        if (findViewById(R.id.suw_layout_decor) instanceof Illustration) {
            // Our header illustration already have padding baked in
            final View title = findViewById(R.id.suw_layout_title);
            title.setPadding(title.getPaddingLeft(), 0, title.getPaddingRight(),
                    title.getPaddingBottom());
        }
    }

    @Override
    protected void onDestroy() {