Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VLC
Manage
Activity
Members
Labels
Plan
Issues
4k
Issue boards
Milestones
Code
Merge requests
440
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
VideoLAN
VLC
Commits
bf8e6301
Commit
bf8e6301
authored
3 years ago
by
Fatih Uzunoğlu
Committed by
Jean-Baptiste Kempf
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
qml: make miniplayer invisible when out of view
parent
d2e59e71
No related branches found
Branches containing commit
No related tags found
1 merge request
!920
qml: make miniplayer invisible when out of view
Pipeline
#166272
passed with stage
in 35 minutes and 16 seconds
Changes
2
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
modules/gui/qt/maininterface/qml/MainDisplay.qml
+9
-6
9 additions, 6 deletions
modules/gui/qt/maininterface/qml/MainDisplay.qml
modules/gui/qt/player/qml/MiniPlayer.qml
+14
-4
14 additions, 4 deletions
modules/gui/qt/player/qml/MiniPlayer.qml
with
23 additions
and
10 deletions
modules/gui/qt/maininterface/qml/MainDisplay.qml
+
9
−
6
View file @
bf8e6301
...
...
@@ -62,7 +62,7 @@ FocusScope {
stackView
.
currentItem
.
Navigation
.
upItem
=
sourcesBanner
stackView
.
currentItem
.
Navigation
.
rightItem
=
playlistColumn
stackView
.
currentItem
.
Navigation
.
downItem
=
Qt
.
binding
(
function
()
{
return
miniPlayer
.
expanded
?
miniPlayer
:
medialibId
return
miniPlayer
.
visible
?
miniPlayer
:
medialibId
})
sourcesBanner
.
localMenuDelegate
=
Qt
.
binding
(
function
()
{
return
!!
stackView
.
currentItem
.
localMenuDelegate
?
stackView
.
currentItem
.
localMenuDelegate
:
null
})
...
...
@@ -331,7 +331,7 @@ FocusScope {
Navigation.parentItem
:
medialibId
Navigation.upItem
:
sourcesBanner
Navigation.downItem
:
miniPlayer
.
expanded
?
miniPlayer
:
null
Navigation.downItem
:
miniPlayer
.
visible
?
miniPlayer
:
null
Navigation.leftAction
:
function
()
{
stackView
.
currentItem
.
setCurrentItemFocus
(
Qt
.
TabFocusReason
);
...
...
@@ -435,7 +435,10 @@ FocusScope {
Player.MiniPlayer
{
id
:
miniPlayer
visible
:
!
root
.
_inhibitMiniPlayer
Binding
on
state
{
when
:
root
.
_inhibitMiniPlayer
&&
!
miniPlayer
.
visible
value
:
""
}
anchors.left
:
parent
.
left
anchors.right
:
parent
.
right
...
...
@@ -445,12 +448,12 @@ FocusScope {
Navigation.parentItem
:
medialibId
Navigation.upItem
:
stackView
Navigation.cancelItem
:
sourcesBanner
on
Expanded
Changed
:
{
if
(
!
expanded
&&
miniPlayer
.
activeFocus
)
on
Visible
Changed
:
{
if
(
!
visible
&&
miniPlayer
.
activeFocus
)
stackView
.
forceActiveFocus
()
}
mainContent
:
mainColumn
effectSource
:
mainColumn
}
Connections
{
...
...
This diff is collapsed.
Click to expand it.
modules/gui/qt/player/qml/MiniPlayer.qml
+
14
−
4
View file @
bf8e6301
...
...
@@ -14,17 +14,21 @@ FocusScope {
implicitHeight
:
controlBar
.
implicitHeight
height
:
0
readonly
property
bool
expanded
:
(
height
!==
0
)
visible
:
false
property
var
mainContent
:
undefined
property
alias
effectSource
:
effect
.
source
state
:
(
player
.
playingState
===
PlayerController
.
PLAYING_STATE_STOPPED
)
?
""
:
"
expanded
"
states
:
State
{
id
:
stateExpanded
name
:
"
expanded
"
PropertyChanges
{
target
:
root
visible
:
true
}
PropertyChanges
{
target
:
root
height
:
implicitHeight
...
...
@@ -34,7 +38,12 @@ FocusScope {
transitions
:
Transition
{
from
:
""
;
to
:
"
expanded
"
reversible
:
true
NumberAnimation
{
property
:
"
height
"
;
easing.type
:
Easing
.
InOutSine
;
duration
:
VLCStyle
.
duration_normal
;
}
SequentialAnimation
{
// visible should change first, in order for inner layouts to calculate implicitHeight correctly
PropertyAction
{
property
:
"
visible
"
}
NumberAnimation
{
property
:
"
height
"
;
easing.type
:
Easing
.
InOutSine
;
duration
:
VLCStyle
.
duration_normal
;
}
}
}
// this MouseArea prevents mouse events to be sent below miniplayer
...
...
@@ -45,6 +54,7 @@ FocusScope {
}
Widgets.FrostedGlassEffect
{
id
:
effect
anchors.fill
:
controlBar
source
:
mainContent
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment