Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

NullPointerException when trying to do locking on multiple drawers.

$
0
0

I've got dual navigation drawers on my View. I need to be able to lock one closed when the other is open. My approach is to try and extend the DrawerToggler to support multiple drawers, but when I add the conditional checks

        if (drawerView == _rightDrawerView)
        {
            _drawerLayout.SetDrawerLockMode(DrawerLayout.LockModeUnlocked, _leftDrawerView);
        }
        else
        {
            _drawerLayout.SetDrawerLockMode(DrawerLayout.LockModeUnlocked, _rightDrawerView);
        }

The app quits without a break, and throws a NullPointerException

Here's a complete Gist with the included exception.


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>