Android Question how to hide some buttons from Exoplayer?

omarruben

Active Member
Licensed User
Longtime User
Is there any way to hide some buttons? lets say the next button and the previous only
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
B4X:
Dim r As Reflector
r.Target = SimpleExoPlayerView1
Dim controller As B4XView = r.GetField("controller")
controller.GetView(0).Color = xui.Color_Green
For Each v As JavaObject In controller.GetAllViewsRecursive
    Dim id As Int = v.RunMethod("getId", Null)
    If id > -1 Then
        Dim entry As String = v.RunMethodJO("getResources", Null).RunMethod("getResourceEntryName", Array(id)).As(String)
        Log(entry)
        If entry = "exo_prev" Or entry = "exo_next" Then
            v.As(B4XView).RemoveViewFromParent
        End If
    End If
Next
 
Upvote 0
Top