Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Geoffrey Métais
VLC-Android
Commits
0d3958d5
Commit
0d3958d5
authored
Apr 20, 2018
by
Geoffrey Métais
Browse files
Displaymanager: Fix logic fail
parent
cb509f79
Changes
1
Hide whitespace changes
Inline
Side-by-side
vlc-android/src/org/videolan/vlc/gui/video/DisplayManager.kt
View file @
0d3958d5
...
...
@@ -122,11 +122,11 @@ class DisplayManager(private val activity: Activity, cloneMode: Boolean) {
mediaRouterCallback
=
object
:
MediaRouter
.
SimpleCallback
()
{
override
fun
onRoutePresentationDisplayChanged
(
router
:
MediaRouter
,
info
:
MediaRouter
.
RouteInfo
)
{
if
(
BuildConfig
.
DEBUG
)
Log
.
d
(
TAG
,
"onRoutePresentationDisplayChanged: info=
"
+
info
)
if
(
BuildConfig
.
DEBUG
)
Log
.
d
(
TAG
,
"onRoutePresentationDisplayChanged: info=
$
info
"
)
val
newDisplayId
=
info
.
presentationDisplay
?.
displayId
?:
-
1
if
(
newDisplayId
==
presentationDisplayId
)
return
presentationDisplayId
=
newDisplayId
if
(
presentation
DisplayId
!
=
-
1
)
removePresentation
()
else
updateDisplayType
()
if
(
new
DisplayId
=
=
-
1
)
removePresentation
()
else
updateDisplayType
()
}
}
mediaRouter
?.
addCallback
(
MediaRouter
.
ROUTE_TYPE_LIVE_VIDEO
,
mediaRouterCallback
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment