EN
Ce contenu n’est pas disponible dans votre langue. Voici la version anglaise.

msOrientation property

Gets the orientation of the screen.

This property is read-only.

IE11

 

Syntax

JavaScript
ptr = object.msOrientation

 

Property values

Type: DOMString

ValueCondition
portrait-primary

The screen is in portrait mode, and the host device is right side up (if its normal orientation is in portrait mode), or the host device is rotated 90 degrees clockwise (if its normal orientation is in landscape mode).

landscape-primary

The screen is in landscape mode, and the host device is right side up (if its normal orientation is in landscape mode), or the host device is rotated 90 degrees counter-clockwise (if its normal orientation is in portrait mode).

portrait-secondary

The screen is in portrait mode, and the host device is upside down (if its normal orientation is in portrait mode), or the host device is rotated 90 degrees counter-clockwise (if its normal orientation is in landscape mode).

landscape-secondary

The screen is in landscape mode, and the host device is upside down (if its normal orientation is in landscape mode), or the host device is rotated 90 degrees clockwise (if its normal orientation is in portrait mode).

 

Standards information

See also

Screen

 

 

Afficher:
© 2014 Microsoft