Cleaning up some orientation code

Fixed some issues with changing orientation and floating toolbars