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

⌈⌋ ⎇ branch:  streamtuner2


Check-in [e667190902]

Overview
Comment:Python3 compatibility: can't use len() on TreeModelRow (Gtk3 doesn't return ListStore row). So use simpler but less exact try/except block to probe for our dict-ListStore and its pixbuf column.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: e667190902b82b7fb0d4c903d86f4f907414478d
User & Date: mario on 2016-10-31 21:52:24
Other Links: manifest | tags
Context
2016-11-01
15:55
Added login capability. check-in: 9f6a662093 user: mario tags: trunk
2016-10-31
21:52
Python3 compatibility: can't use len() on TreeModelRow (Gtk3 doesn't return ListStore row). So use simpler but less exact try/except block to probe for our dict-ListStore and its pixbuf column. check-in: e667190902 user: mario tags: trunk
21:50
Slim down comment (too lengthy contents break gtk tooltip) check-in: 2b17639821 user: mario tags: trunk
Changes

Modified uikit.py from [ffdf4878d3] to [2f76cfbd7b].

544
545
546
547
548
549
550

551
552
553
554
555
556








557
558
559
560
561
562
563
544
545
546
547
548
549
550
551






552
553
554
555
556
557
558
559
560
561
562
563
564
565
566







+
-
-
-
-
-
-
+
+
+
+
+
+
+
+







    # where user_data = (liststore, column #id)
    @staticmethod
    def liststore_edit(cell, row, text, user_data):
        #log.EDIT(cell, row, text, user_data)
        row = int(row)
        liststore, column = user_data
        liststore[row][column] = text
        try:
        # update executable-indicator pixbuf
        if column == 1 and len(liststore[0]) == 3 and liststore[row][2].startswith("gtk-"):
            liststore[row][2] = uikit.app_bin_check(text)
        # add new row when editing last one
        if len(text) and (row + 1) == len(liststore):
            liststore.append(["", "", "gtk-new"])
            # update executable-indicator pixbuf
            if column == 1 and liststore[row][2].startswith("gtk-"):
                liststore[row][2] = uikit.app_bin_check(text)
            # add new row when editing last one
            if len(text) and (row + 1) == len(liststore):
                liststore.append(["", "", "gtk-new"])
        except:
            pass

    # return OK or CANCEL depending on availability of app
    @staticmethod
    def app_bin_check(v):
        bin = re.findall(r"(?<![$(`%-;/$])\b(\w+(?:-\w+)*)", v)
        if bin:
            bin = [find_executable(bin) for bin in bin]