user128511
user128511

Reputation:

How do I test orientation lock in iOS8 simulator?

If I recall correctly I could set the orientation lock in the iOS Simulator before XCode 6. Now it appears this option is no longer available. Is it somewhere else?

Note: I'm testing web apps that adjust to orientation. They need to do different things if the user has the orientation locked vs unlocked and so I need to test. I could have sworn I was able to test this on iOS7.1 simulator in XCode 5 but it seems that option is missing in XCode 6.

Is there a way to test this in the simulator?

Upvotes: 5

Views: 2700

Answers (2)

Max MacLeod
Max MacLeod

Reputation: 26672

Unfortunately, current versions of iOS, this cannot be done. Writing this May 2023, the current version is 16.5.

Moreover, there is no orientation lock. Rather, it is portrait lock. That means that if using an app such as Apple Maps in landscape orientation, on enabling portrait lock, the orientation will change to portrait.

See Rotate the screen on your iPhone or iPod touch.

To complicate matters further, on the simulator, swiping down from top right reveals Control Center but without controls. Only carrier, network, and battery life are visible.

See related question Cannot open iPhone Control Center on simulator.

Upvotes: 0

Jeremy Huddleston Sequoia
Jeremy Huddleston Sequoia

Reputation: 23651

If you slide up control center, you can click on the rotation lock button to lock rotation.

Upvotes: 3

Related Questions