apache / apache/cordova-plugin-screen-orientation
Calling .unlock() causes screen to rotate twice in iOS
- Dominant language
- JavaScript
- Stars
- 219
- Forks
- 234
- PR merge metrics
- No merged PRs in 30d
Description
# Bug Report
## There is issue with .unlock() which causes the app to rotate twice in iOS
### What is expected to happen?
The device should rotate once to landscape-primary(90) degree and also able to rotate to landscape-secondary(-90).
### What does actually happen?
The device rotates twice at once. First to landscape-primary(90) and to landscape-secondary(-90) and stays there.
## Information
There is already a bug report for this [here](https://github.com/apache/cordova-plugin-screen-orientation/pull/107#issue-1393446662) but even with the latest version the issue is still there.
### Command or Code
screen.orientation.unlock();
### Environment, Platform, Device
iPadOS version - 17.2
IPad 10th gen
### Version information
## Checklist
- [x] I searched for existing GitHub issues
- [x] I updated all Cordova tooling to most recent version
- [x] I included all the necessary information above
Contributor guide
Research direction
Start by reproducing screen.orientation.unlock() on the reported iPadOS 17.2 device and review the existing report in pull request #107. Trace the rotation sequence and confirm that unlocking rotates once to the requested landscape orientation, including both primary and secondary orientations.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, javascript
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100