In testing the toolbar addition through screen rotation, I found that my app does not adjust to the changed screen orientation (i.e., it’s stuck in portrait). The app does not crash, and I verified that the state is maintained by adding text in on the crime activity, rotating through the emulator, and verifying that the text remains. I added xml files to the layout-land directory as we did in chapter 3.
Any help on where to start to troubleshoot would be most welcome. I’ve tried to debug through at the various OnCreate method calls without any insight into why the views aren’t adjusting to screen changes.
UPDATE: Went back to starting board and reconstructed the Criminal Intent from scratch to determine at what point the orientation stopped working. Implemented just the baseline code from the book. Found that the app NEVER rotated (reoriented to landscape). Tested using both emulator and device.
UPDATE 2: ID10T Error Alert: I had somehow set auto-rotation lock on BOTH emulator and hard device. Correction identified and fixed.