Internet radio browser GUI for music/video streams from various directory services.

⌈⌋ ⎇ branch:  streamtuner2


Diff

Differences From Artifact [7f53cc759c]:

To Artifact [0405b0c427]:

  • File config.py — part of check-in [ffaf262c43] at 2015-04-28 17:35:15 on branch trunk — Move `state.json` and .current restoration into GenericChannel.gui(). Current category is reselected by TreeView traversal on instantion now. Previous state now load through config.state() for channels/__init__, not in main/init_app_state anymore (just row:expand / winsizes now). Disable .currentcat() overwriting, redundant now in display_categories(). Still need to avoid second .select_current() call in first_show(). (user: mario, size: 18633) [annotate] [blame] [check-ins using]

250
251
252
253
254
255
256









257
258
259
260
261
262
263
        # 2.1.1
        if "audio/mp3" in self.play:
            self.play["audio/mpeg"] = self.play["audio/mp3"]
            del self.play["audio/mp3"]
        if self.tmp == "/tmp":
            self.tmp = "/tmp/streamtuner2"










         
    # check for existing filename in directory list
    def find_in_dirs(self, dirs, file):
        for d in dirs:
            if os.path.exists(d+"/"+file):
                return d+"/"+file








>
>
>
>
>
>
>
>
>







250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
        # 2.1.1
        if "audio/mp3" in self.play:
            self.play["audio/mpeg"] = self.play["audio/mp3"]
            del self.play["audio/mp3"]
        if self.tmp == "/tmp":
            self.tmp = "/tmp/streamtuner2"

            
    # Shortcut to `state.json` loading (currently selected categories etc.)
    def state(self, module=None, d={}):
        if not d:
            d.update(conf.load("state"))
        if module:
            return d.get(module, {})
        return d

         
    # check for existing filename in directory list
    def find_in_dirs(self, dirs, file):
        for d in dirs:
            if os.path.exists(d+"/"+file):
                return d+"/"+file