5
0
mirror of https://github.com/wailsapp/wails.git synced 2025-05-02 20:21:01 +08:00
wails/v3/internal/runtime/desktop/screens.js
2023-03-31 20:37:50 +11:00

44 lines
755 B
JavaScript

/*
_ __ _ __
| | / /___ _(_) /____
| | /| / / __ `/ / / ___/
| |/ |/ / /_/ / / (__ )
|__/|__/\__,_/_/_/____/
The electron alternative for Go
(c) Lea Anthony 2019-present
*/
/* jshint esversion: 9 */
/**
* @typedef {import("./api/types").Screen} Screen
*/
import {newRuntimeCaller} from "./runtime";
let call = newRuntimeCaller("screens");
/**
* Gets all screens.
* @returns {Promise<Screen[]>}
*/
export function GetAll() {
return call("GetAll");
}
/**
* Gets the primary screen.
* @returns {Promise<Screen>}
*/
export function GetPrimary() {
return call("GetPrimary");
}
/**
* Gets the current active screen.
* @returns {Promise<Screen>}
* @constructor
*/
export function GetCurrent() {
return call("GetCurrent");
}