Esempio n. 1
0
    def focuschanged(self, event):
        if self.hasfocus():
            sbar = statusbar.generatedescription("general", "volumedown")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("general", "volumeup")
            sbar += statusbar.terminate

            hub.notify(events.statusbar_update(0, sbar))
Esempio n. 2
0
    def focuschanged(self, event):
        if self.hasfocus():
            sbar = statusbar.generatedescription("general", "volumedown")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("general", "volumeup")
            sbar += statusbar.terminate

            hub.notify(events.statusbar_update(0, sbar))
Esempio n. 3
0
    def updatestatusbar(self):
        sbar = []
        if self.playlist.selected is not None:
            sbar += statusbar.generatedescription("playlistwindow", "deleteitem")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("playlistwindow", "moveitemup")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("playlistwindow", "moveitemdown")
            sbar += statusbar.separator

        sbar += statusbar.generatedescription("playlistwindow", "activatefilelist")
        hub.notify(events.statusbar_update(0, sbar))
Esempio n. 4
0
    def updatestatusbar(self):
        sbar = []
        if len(self.items.shistory)>0:
            sbar += statusbar.generatedescription("filelistwindow", "dirup")
            sbar += statusbar.separator
        if self.items.isdirselected():
            sbar += statusbar.generatedescription("filelistwindow", "dirdown")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("filelistwindow", "adddirtoplaylist")
            sbar += statusbar.separator
        elif self.items.issongselected():
            sbar += statusbar.generatedescription("filelistwindow", "addsongtoplaylist")
            sbar += statusbar.separator

        sbar += statusbar.generatedescription("filelistwindow", "activateplaylist")
        hub.notify(events.statusbar_update(0, sbar))
Esempio n. 5
0
    def updatestatusbar(self):
        sbar = []
        if len(self.items.shistory)>0:
            sbar += statusbar.generatedescription("filelistwindow", "dirup")
            sbar += statusbar.separator
        if self.items.isdirselected():
            sbar += statusbar.generatedescription("filelistwindow", "dirdown")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("filelistwindow", "adddirtoplaylist")
            sbar += statusbar.separator
        elif self.items.issongselected():
            sbar += statusbar.generatedescription("filelistwindow", "addsongtoplaylist")
            sbar += statusbar.separator

        sbar += statusbar.generatedescription("filelistwindow", "activateplaylist")
        hub.notify(events.statusbar_update(0, sbar))
Esempio n. 6
0
    def updatestatusbar(self):
        sbar = []
        if self.playlist.selected is not None:
            sbar += statusbar.generatedescription("playlistwindow",
                                                  "deleteitem")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("playlistwindow",
                                                  "moveitemup")
            sbar += statusbar.separator
            sbar += statusbar.generatedescription("playlistwindow",
                                                  "moveitemdown")
            sbar += statusbar.separator

        sbar += statusbar.generatedescription("playlistwindow",
                                              "activatefilelist")
        hub.notify(events.statusbar_update(0, sbar))
Esempio n. 7
0
    def __init__(self, screen, maxh, maxw, channel):
        messagewin.messagewin.__init__(self, screen, maxh, maxw, channel,
                                       config.colors.helpwindow,
                                       _("PyTone Help"), [],
                                       config.helpwindow.autoclosetime)

        sbar = statusbar.generatedescription("general", "showhelp")
        hub.notify(events.statusbar_update(2, sbar))
Esempio n. 8
0
    def __init__(self, screen, maxh, maxw, channel):
        messagewin.messagewin.__init__(self, screen, maxh, maxw, channel,
                                       config.colors.helpwindow,
                                       _("PyTone Help"), [],
                                       config.helpwindow.autoclosetime)

        sbar = statusbar.generatedescription("general", "showhelp")
        hub.notify(events.statusbar_update(2, sbar))
Esempio n. 9
0
 def updatestatusbar(self):
     if self.song and not self.paused and self.keybindings["playerpause"]:
         sbar = statusbar.generatedescription("general", "playerpause")
     else:
         sbar = statusbar.generatedescription("general", "playerstart")
     hub.notify(events.statusbar_update(1, sbar))
Esempio n. 10
0
 def updatestatusbar(self):
     if self.song and not self.paused and self.keybindings["playerpause"]:
         sbar = statusbar.generatedescription("general", "playerpause")
     else:
         sbar = statusbar.generatedescription("general", "playerstart")
     hub.notify(events.statusbar_update(1, sbar))