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

Commit 6e6c6470 authored by Yorke Lee's avatar Yorke Lee Committed by Android (Google) Code Review
Browse files

Merge "Pass button index into inflateButton" into nyc-dev

parents 8d35506e 0681c096
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -182,7 +182,7 @@ public class NavigationBarInflaterView extends FrameLayout implements TunerServi

    private void inflateButtons(String[] buttons, ViewGroup parent, boolean landscape) {
        for (int i = 0; i < buttons.length; i++) {
            inflateButton(buttons[i], parent, landscape);
            inflateButton(buttons[i], parent, landscape, i);
        }
    }

@@ -195,7 +195,8 @@ public class NavigationBarInflaterView extends FrameLayout implements TunerServi
    }

    @Nullable
    protected View inflateButton(String buttonSpec, ViewGroup parent, boolean landscape) {
    protected View inflateButton(String buttonSpec, ViewGroup parent, boolean landscape,
            int indexInParent) {
        LayoutInflater inflater = landscape ? mLandscapeInflater : mLayoutInflater;
        float size = extractSize(buttonSpec);
        String button = extractButton(buttonSpec);