title: Keeping system in phone correct orientation when disabling 'auto-rotate' in Android
body: <p>It looks like a bug in the Android system but i'm note sure :<br>
  in my app i use <code>Settings.System.putInt</code> to disable auto-rotate, sometimes whenever i fire the command, the orientation changes to another one (and the auto rotate is locked).<br>
  I wasn't able to determine to which orientation it will change (sometimes when the phone in portrait and i fire it, it stays in portrait and sometimes changes to landscape, similar thing happens in landscape)<br>
  It looks like the orientation in each the application was started in has an effect of the 'target' orientation in each the system will be 'locked' in, but i wasn't able to determine it for sure.<br>
  Is anyone aware of this issue ? Anything i can do so it won't happen ? </p>
  
  <p>Thank you !</p>