Move hover preview height from settings to theme

This commit is contained in:
miruka 2019-09-17 16:39:45 -04:00
parent 692749e72f
commit f19d337817
3 changed files with 4 additions and 2 deletions

View File

@ -115,7 +115,6 @@ class UISettings(JSONConfigFile):
"autoHideOSDAfterMsec": 3000, "autoHideOSDAfterMsec": 3000,
"defaultVolume": 100, "defaultVolume": 100,
"startMuted": False, "startMuted": False,
"hoverPreviewHeight": 192,
}, },
"keys": { "keys": {
"startPythonDebugger": "Alt+Shift+D", "startPythonDebugger": "Alt+Shift+D",

View File

@ -97,7 +97,7 @@ HColumnLayout {
contentItem: VideoPreview { contentItem: VideoPreview {
id: preview id: preview
implicitHeight: Math.min( implicitHeight: Math.min(
window.settings.media.hoverPreviewHeight, theme.mediaPlayer.hoverPreview.maxHeight,
media.height - osd.height - theme.spacing media.height - osd.height - theme.spacing
) )
implicitWidth: Math.min( implicitWidth: Math.min(

View File

@ -359,6 +359,9 @@ chat:
mediaPlayer: mediaPlayer:
hoverPreview:
int maxHeight: 192
progress: progress:
int height: 8 int height: 8
color background: hsluv(0, 0, 0, 0.5) color background: hsluv(0, 0, 0, 0.5)