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

Commit 68dab67d authored by Udam Saini's avatar Udam Saini
Browse files

Calling setIsDrawerPresent(false) twice causes a crash.

We should only call setDrawerLockMode(...) if mDrawerLayout isn't
null.

bug:26288300
Change-Id: I8a1b77e03414360f9cd7e3fa6e6c98ef0e139ebf
parent 160222a4
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -155,10 +155,12 @@ public class SettingsDrawerActivity extends Activity {
            mDrawerLayout = (DrawerLayout) findViewById(R.id.drawer_layout);
            updateDrawer();
        } else {
            if (mDrawerLayout != null) {
                mDrawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_LOCKED_CLOSED);
                mDrawerLayout = null;
            }
        }
    }

    public void openDrawer() {
        if (mDrawerLayout != null) {