mirror of
https://gitlab.com/futo-org/fcast.git
synced 2025-06-24 21:25:23 +00:00
Electron: Add additional fullscreen doubleclick handlers
This commit is contained in:
parent
56e10760b8
commit
47b8c1f068
3 changed files with 8 additions and 2 deletions
|
@ -1017,6 +1017,9 @@ document.addEventListener('keyup', (event: KeyboardEvent) => {
|
||||||
|
|
||||||
export {
|
export {
|
||||||
PlayerControlEvent,
|
PlayerControlEvent,
|
||||||
|
idleBackground,
|
||||||
|
thumbnailImage,
|
||||||
|
idleIcon,
|
||||||
videoElement,
|
videoElement,
|
||||||
videoCaptions,
|
videoCaptions,
|
||||||
playerCtrlProgressBar,
|
playerCtrlProgressBar,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { videoElement, PlayerControlEvent, playerCtrlStateUpdate } from 'common/player/Renderer';
|
import { videoElement, PlayerControlEvent, playerCtrlStateUpdate, idleBackground, thumbnailImage, idleIcon } from 'common/player/Renderer';
|
||||||
|
|
||||||
const captionsBaseHeightCollapsed = 75;
|
const captionsBaseHeightCollapsed = 75;
|
||||||
const captionsBaseHeightExpanded = 160;
|
const captionsBaseHeightExpanded = 160;
|
||||||
|
@ -7,6 +7,9 @@ const captionsLineHeight = 34;
|
||||||
const playerCtrlFullscreen = document.getElementById("fullscreen");
|
const playerCtrlFullscreen = document.getElementById("fullscreen");
|
||||||
playerCtrlFullscreen.onclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
playerCtrlFullscreen.onclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
||||||
videoElement.ondblclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
videoElement.ondblclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
||||||
|
idleBackground.ondblclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
||||||
|
thumbnailImage.ondblclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
||||||
|
idleIcon.ondblclick = () => { playerCtrlStateUpdate(PlayerControlEvent.ToggleFullscreen); };
|
||||||
|
|
||||||
export function targetPlayerCtrlStateUpdate(event: PlayerControlEvent): boolean {
|
export function targetPlayerCtrlStateUpdate(event: PlayerControlEvent): boolean {
|
||||||
let handledCase = false;
|
let handledCase = false;
|
||||||
|
|
|
@ -100,4 +100,4 @@
|
||||||
|
|
||||||
<script src="./renderer.js"></script>
|
<script src="./renderer.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue