Changeset - 581dfd11d9fd
[Not reviewed]
default
0 1 0
drewp@bigasterisk.com - 15 years ago 2010-06-11 07:13:50
drewp@bigasterisk.com
-v for old ascoltami
Ignore-this: 4479304616f754efc7f352d3a58f6307
1 file changed with 5 insertions and 0 deletions:
0 comments (0 inline, 0 general)
bin/ascoltami
Show inline comments
 
@@ -495,51 +495,56 @@ class ControlButtons(tk.Frame):
 

	
 
        colors = {'stop' : 'red',
 
                  'play' : 'blue',
 
                  'pause' : 'green'} # very confusing -- play and pause supply colors
 
                                     # for each other!
 
        for name, button in self.statebuttons.items():
 
            if name == 'pause' and state not in ('stop', 'pause'):
 
                name = 'play'
 

	
 
            if state == name: # name gets changed sometimes for 'pause' -- see right above
 
                button['bg'] = colors.get(name, 'black')
 
            else:
 
                button['bg'] = 'black'
 
        self.goButton.updateStatus()
 

	
 
############################
 

	
 

	
 

	
 
def main():
 
    global graph
 
    parser = OptionParser()
 
    parser.add_option('--show',
 
        help='show URI, like http://light9.bigasterisk.com/show/dance2008')
 
    parser.add_option("-v", "--verbose", action="store_true",
 
                      help="logging.DEBUG")
 
    graph = showconfig.getGraph()
 
    (options, songfiles) = parser.parse_args()
 

	
 
    if options.verbose:
 
        log.setLevel(logging.DEBUG)
 
        
 
    if len(songfiles)<1:
 
        graph = showconfig.getGraph()
 
        if not options.show:
 
            raise ValueError("missing --show http://...")
 
        playList = graph.value(URIRef(options.show), L9['playList'])
 
        if not playList:
 
            raise ValueError("%r has no l9:playList" % options.show)
 
        songs = list(graph.items(playList))
 
    else:
 
        raise NotImplementedError("don't know how to make rdf song nodes from cmdline song paths")
 

	
 

	
 
    root=tk.Tk()
 
    root.wm_title("ascoltami")
 
    toplevelat("ascoltami", root)
 
    root.config(bg="black")
 
    player=Player()
 

	
 
    songlist = buildsonglist(root, graph, songs, player)
 
    songlist.pack(fill='both',exp=1)
 

	
 
    seeker = Seeker(root, player)
 
    
 
    goRow = tk.Frame(root)
0 comments (0 inline, 0 general)