New issue
Advanced search Search tips

Issue 787874 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Nov 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

locking screen orientation gives an error

Reported by vasco.go...@gmail.com, Nov 22 2017

Issue description

<b>Chrome Version       : <Copy from: 'about:version'></b>
URLs (if applicable) :
Other browsers tested:
  Add OK or FAIL, along with the version, after other browsers where you
have tested this issue:
     Safari:
    Firefox:
       Edge:

What steps will reproduce the problem?
(1) try to lock the screen orientation
(2) window.screen.orientation.lock('portrait')
(3)

What is the expected result?
it locks the screen on portrait or landscape

What happens instead?
Gives an error: DOMException: screen.orientation.lock() is not available on this device.
Tested on Windows 10. It should give this error on Win/Mac/Linux.


Please provide any additional information below. Attach a screenshot if
possible.

 
Status: WontFix (was: Unconfirmed)
This is working as expected. We do not allow screen orientation lock on non-mobile platforms.
That doesn't make any sense and it's against the API:
https://w3c.github.io/screen-orientation/

Besides if I open the Developer Tools -> More Tools -> Sensors -> Orientation -> Portrait/Landscape
It doesn't change the value on window.screen.orientation.type
It remains always the same.

But if I go to toggle to mobile device and change the orientation to portrait or landscape the variable is changed: window.screen.orientation.type

This is important because CSS looks to this specific variable and Chrome is crippled on evaluating this behavior.

Please take a look at this. At least to the Sensor's bug.
 

Sign in to add a comment