nsISupports
Last changed in Gecko 1.9 (Firefox 3)Implemented by: @mozilla.org/gfx/screenmanager;1 as a service:
var screenManager = Components.classes["@mozilla.org/gfx/screenmanager;1"]
.getService(Components.interfaces.nsIScreenManager);
nsIScreen screenForNativeWidget( in voidPtr nativeWidget ); Native code only! |
nsIScreen screenForRect( in long left, in long top, in long width, in long height ); |
| Attribute | Type | Description |
numberOfScreens | unsigned long | The number of screens on the user's computer. Read only. |
primaryScreen | | The primary display screen; this is the screen with the menu bar (on the Mac) or taskbar or equivalent on Windows or Linux. Read only. |
Returns the nsIScreen instance for the native widget pointer. This pointer's definition is specific to the platform's native widget implementation, and is typically of the same type as NS_NATIVE_WINDOW.
nsIScreen screenForNativeWidget( in voidPtr nativeWidget );
nativeWidgetnsIScreen instance.The nsIScreen instance for the native widget pointer.
Returns the nsIScreen containing the specified rectangle. If the rectangle overlaps multiple screens, the screen containing the majority of the rectangle's area is selected and returned.
The coordinates must be specified using global (screen) coordinates, and are in pixels.
nsIScreen screenForRect( in long left, in long top, in long width, in long height );
lefttopwidthheightThe nsIScreen containing the majority of the rectangle's area.