Register a Controller to $ionicHistory

Hey there,

I’m currently heavily customizing the ion-android-drawer (http://ions.ionic.io/ion/ionic-ion-drawer), giving it some of the features that the side-menus directive has (like opening when the drag has a certain velocity etc…). (Based on my earlier topic here: Make ion-side-menu open over ion-side-menu-content)

What I couldn’t figure out, is how I can close the drawer, when the (physical) android back button is pressed. I would think it would be easiest to somehow register the drawer in $ionicHistory-Service, but I can’t figure out how.

Any help or ideas would be appreciated.