Python Forum
create actionbar within screen that plays video
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
create actionbar within screen that plays video
#1
I have screen that plays video. the video plays but there no option to return back when the video finishes playing. I want
to create a button to go back and other 2 button for another purpose or an actionbar with three items. please explain in details


def playingv(self):
        
        print(theoption3)
        
        if theoption3 == str('imperative sentences to passive voice',).strip("()"):
            video= VideoPlayer()
            
            self.add_widget(video)
            
            video.source='can.mp4'
            video.state='play'
            video.allow_fullscreen
            video.fullscreen=True
            video.options={'eos':'loop'}
            
        elif theoption3 == str('would you mind',).strip("()"):
            video= VideoPlayer()
            
            self.add_widget(video)
            
            video.source='adjectives.mp4'
            video.state='play'
            video.allow_fullscreen=True
            video.fullscreen=True
            video.options={'eos':'loop'}
I am trying to add actionbar but does not show

<Playvideo>:
     name:"video"
     id:video
     FloatLayout:
          
          ActionBar:
               pos_hint:{'top':1}
               ActionView:
                    use_separator:True
                    ActionPrevious:
                         title:'   Go Back'
                         on_press:
                              app.root.current="home_screen"
                         with_previous:False
                    ActionGroup:
                         mode:'spinner'
                         text:'Menu'
                         ActionButton:
                              text:'play video 2'
                         ActionButton
                              text:'read text file'
                         ActionButton
                              text:'Go Back'
                         
     
     VideoPlayer:
          id:'v'
          source:
          pos_hint:{'top':1}
          state:'play'
class Playvideo(Screen):
    
    pass
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  [Kivy] video plays in the background only Gorashy 3 1,630 Jun-19-2024, 02:00 AM
Last Post: menator01
  [Tkinter] Button Plays Random .MP3 File From Folder blufacebaby 2 2,991 Feb-05-2021, 02:19 AM
Last Post: BashBedlam
  [PyQt] Embedding a Video in Video Player WhatsupSmiley 0 7,217 Jan-28-2019, 06:24 PM
Last Post: WhatsupSmiley

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020