Browse Source

palabotx xtv

Ivars 6 years ago
parent
commit
3311b59a17
2 changed files with 121 additions and 104 deletions
  1. 116
    99
      project.wpr
  2. 5
    5
      sources/xtv.py

+ 116
- 99
project.wpr View File

712
                                 'top-node': [('generic attribute',
712
                                 'top-node': [('generic attribute',
713
         loc('sources/ltc.py'),
713
         loc('sources/ltc.py'),
714
         'cmd')]},
714
         'cmd')]},
715
+        loc('sources/play24.py'): {'expanded-nodes': [],
716
+                                   'selected-nodes': [],
717
+                                   'top-node': [('generic attribute',
718
+        loc('sources/play24.py'),
719
+        'API_URL')]},
715
         loc('sources/replay.py'): {'expanded-nodes': [],
720
         loc('sources/replay.py'): {'expanded-nodes': [],
716
                                    'selected-nodes': [[('class def',
721
                                    'selected-nodes': [[('class def',
717
         loc('sources/replay.py'),
722
         loc('sources/replay.py'),
719
                                    'top-node': [('generic attribute',
724
                                    'top-node': [('generic attribute',
720
         loc('sources/replay.py'),
725
         loc('sources/replay.py'),
721
         'API_URL')]},
726
         'API_URL')]},
727
+        loc('sources/serialguru.py'): {'expanded-nodes': [],
728
+                                       'selected-nodes': [],
729
+                                       'top-node': [('generic attribute',
730
+        loc('sources/serialguru.py'),
731
+        'data')]},
722
         loc('sources/tmp/SourceBase.py'): {'expanded-nodes': [],
732
         loc('sources/tmp/SourceBase.py'): {'expanded-nodes': [],
723
         'selected-nodes': [],
733
         'selected-nodes': [],
724
         'top-node': [('generic attribute',
734
         'top-node': [('generic attribute',
908
                                None)],
918
                                None)],
909
                  'primary_view_state': {'area': 'wide',
919
                  'primary_view_state': {'area': 'wide',
910
         'constraint': None,
920
         'constraint': None,
911
-        'current_pages': [4,
921
+        'current_pages': [2,
912
                           0],
922
                           0],
913
-        'notebook_display': 'normal',
923
+        'notebook_display': 'tabs only',
914
         'notebook_percent': 0.32265812650120096,
924
         'notebook_percent': 0.32265812650120096,
915
         'override_title': None,
925
         'override_title': None,
916
         'pagelist': [('debug-breakpoints',
926
         'pagelist': [('debug-breakpoints',
1097
                             143L,
1107
                             143L,
1098
                             166L,
1108
                             166L,
1099
                             284L],
1109
                             284L],
1100
-         'sel-line': 52L,
1101
-         'sel-line-start': 1776L,
1102
-         'selection_end': 1835L,
1103
-         'selection_start': 1831L,
1110
+         'sel-line': 57L,
1111
+         'sel-line-start': 2327L,
1112
+         'selection_end': 2398L,
1113
+         'selection_start': 2394L,
1104
          'zoom': 0L},
1114
          'zoom': 0L},
1105
-        1548541029.557],
1106
-        [loc('sources/replay.py'),
1107
-         {'attrib-starts': [('Source',
1108
-                             31),
1109
-                            ('Source.get_content',
1110
-                             42)],
1111
-          'first-line': 41L,
1112
-          'folded-linenos': [70L,
1113
-                             89L,
1114
-                             143L,
1115
-                             166L,
1116
-                             284L],
1117
-          'sel-line': 53L,
1118
-          'sel-line-start': 1866L,
1119
-          'selection_end': 1947L,
1120
-          'selection_start': 1943L,
1121
-          'zoom': 0L},
1122
-         1548541029.854],
1123
-        [loc('sources/replay.py'),
1124
-         {'attrib-starts': [('Source',
1125
-                             31),
1126
-                            ('Source.get_content',
1127
-                             42)],
1128
-          'first-line': 41L,
1129
-          'folded-linenos': [70L,
1130
-                             89L,
1131
-                             143L,
1132
-                             166L,
1133
-                             284L],
1134
-          'sel-line': 54L,
1135
-          'sel-line-start': 1981L,
1136
-          'selection_end': 2055L,
1137
-          'selection_start': 2051L,
1138
-          'zoom': 0L},
1139
-         1548541030.064],
1140
-        [loc('sources/replay.py'),
1141
-         {'attrib-starts': [('Source',
1142
-                             31),
1143
-                            ('Source.get_content',
1144
-                             42)],
1145
-          'first-line': 41L,
1146
-          'folded-linenos': [70L,
1147
-                             89L,
1148
-                             143L,
1149
-                             166L,
1150
-                             284L],
1151
-          'sel-line': 55L,
1152
-          'sel-line-start': 2097L,
1153
-          'selection_end': 2165L,
1154
-          'selection_start': 2161L,
1155
-          'zoom': 0L},
1156
-         1548541030.285],
1157
-        [loc('sources/replay.py'),
1158
-         {'attrib-starts': [('Source',
1159
-                             31),
1160
-                            ('Source.get_content',
1161
-                             42)],
1162
-          'first-line': 41L,
1163
-          'folded-linenos': [70L,
1164
-                             89L,
1165
-                             143L,
1166
-                             166L,
1167
-                             284L],
1168
-          'sel-line': 56L,
1169
-          'sel-line-start': 2207L,
1170
-          'selection_end': 2291L,
1171
-          'selection_start': 2287L,
1172
-          'zoom': 0L},
1173
-         1548541030.467],
1174
-        [loc('sources/replay.py'),
1175
-         {'attrib-starts': [('Source',
1176
-                             31),
1177
-                            ('Source.get_content',
1178
-                             42)],
1179
-          'first-line': 41L,
1180
-          'folded-linenos': [70L,
1181
-                             89L,
1182
-                             143L,
1183
-                             166L,
1184
-                             284L],
1185
-          'sel-line': 57L,
1186
-          'sel-line-start': 2327L,
1187
-          'selection_end': 2398L,
1188
-          'selection_start': 2394L,
1189
-          'zoom': 0L},
1190
-         1548541030.645],
1115
+        1548541030.645],
1191
         [loc('sources/replay.py'),
1116
         [loc('sources/replay.py'),
1192
          {'attrib-starts': [('Source',
1117
          {'attrib-starts': [('Source',
1193
                              31),
1118
                              31),
1407
           'selection_end': 2659L,
1332
           'selection_end': 2659L,
1408
           'selection_start': 2653L,
1333
           'selection_start': 2653L,
1409
           'zoom': 0L},
1334
           'zoom': 0L},
1410
-         1548541115.158]],
1335
+         1548541115.158],
1336
+        [loc('sources/xtv.py'),
1337
+         {'attrib-starts': [('Source',
1338
+                             32),
1339
+                            ('Source.get_content',
1340
+                             41)],
1341
+          'first-line': 57L,
1342
+          'folded-linenos': [],
1343
+          'sel-line': 61L,
1344
+          'sel-line-start': 2525L,
1345
+          'selection_end': 2600L,
1346
+          'selection_start': 2600L,
1347
+          'zoom': 0L},
1348
+         1548541304.939],
1349
+        [loc('sources/xtv.py'),
1350
+         {'attrib-starts': [('Source',
1351
+                             32),
1352
+                            ('Source.get_streams',
1353
+                             105)],
1354
+          'first-line': 83L,
1355
+          'folded-linenos': [],
1356
+          'sel-line': 116L,
1357
+          'sel-line-start': 5003L,
1358
+          'selection_end': 5080L,
1359
+          'selection_start': 5080L,
1360
+          'zoom': 0L},
1361
+         1548541391.034],
1362
+        [loc('sources/serialguru.py'),
1363
+         {'attrib-starts': [('Source',
1364
+                             25),
1365
+                            ('Source.__init__',
1366
+                             27)],
1367
+          'first-line': 15L,
1368
+          'folded-linenos': [],
1369
+          'sel-line': 28L,
1370
+          'sel-line-start': 817L,
1371
+          'selection_end': 882L,
1372
+          'selection_start': 825L,
1373
+          'zoom': 0L},
1374
+         1548541402.338],
1375
+        [loc('sources/xtv.py'),
1376
+         {'attrib-starts': [('Source',
1377
+                             32),
1378
+                            ('Source.get_streams',
1379
+                             105)],
1380
+          'first-line': 83L,
1381
+          'folded-linenos': [],
1382
+          'sel-line': 116L,
1383
+          'sel-line-start': 5003L,
1384
+          'selection_end': 5080L,
1385
+          'selection_start': 5080L,
1386
+          'zoom': 0L},
1387
+         1548541425.101],
1388
+        [loc('sources/play24.py'),
1389
+         {'attrib-starts': [('Source',
1390
+                             28),
1391
+                            ('Source.__init__',
1392
+                             30)],
1393
+          'first-line': 21L,
1394
+          'folded-linenos': [],
1395
+          'sel-line': 31L,
1396
+          'sel-line-start': 1014L,
1397
+          'selection_end': 1079L,
1398
+          'selection_start': 1079L,
1399
+          'zoom': 0L},
1400
+         1548541509.117]],
1411
         20),
1401
         20),
1412
         'current-loc': loc('sources/xtv.py'),
1402
         'current-loc': loc('sources/xtv.py'),
1413
         'editor-state-list': [(loc('run.py'),
1403
         'editor-state-list': [(loc('run.py'),
1490
         32),
1480
         32),
1491
         ('Source.get_content',
1481
         ('Source.get_content',
1492
          41)],
1482
          41)],
1493
-                                'first-line': 48L,
1483
+                                'first-line': 42L,
1494
                                 'folded-linenos': [],
1484
                                 'folded-linenos': [],
1495
-                                'sel-line': 61L,
1496
-                                'sel-line-start': 2525L,
1497
-                                'selection_end': 2600L,
1498
-                                'selection_start': 2600L,
1485
+                                'sel-line': 55L,
1486
+                                'sel-line-start': 2276L,
1487
+                                'selection_end': 2346L,
1488
+                                'selection_start': 2346L,
1499
                                 'zoom': 0L}),
1489
                                 'zoom': 0L}),
1500
                               (loc('sources/euronews.py'),
1490
                               (loc('sources/euronews.py'),
1501
                                {'attrib-starts': [('Source',
1491
                                {'attrib-starts': [('Source',
1575
                                 'sel-line-start': 3497L,
1565
                                 'sel-line-start': 3497L,
1576
                                 'selection_end': 3536L,
1566
                                 'selection_end': 3536L,
1577
                                 'selection_start': 3536L,
1567
                                 'selection_start': 3536L,
1568
+                                'zoom': 0L}),
1569
+                              (loc('sources/play24.py'),
1570
+                               {'attrib-starts': [('Source',
1571
+        28),
1572
+        ('Source.__init__',
1573
+         30)],
1574
+                                'first-line': 21L,
1575
+                                'folded-linenos': [],
1576
+                                'sel-line': 31L,
1577
+                                'sel-line-start': 1014L,
1578
+                                'selection_end': 1079L,
1579
+                                'selection_start': 1079L,
1578
                                 'zoom': 0L})],
1580
                                 'zoom': 0L})],
1579
         'has-focus': True,
1581
         'has-focus': True,
1580
         'locked': False},
1582
         'locked': False},
1590
          loc('sources/filmix.py'),
1592
          loc('sources/filmix.py'),
1591
          loc('../../../../../Python27/Lib/site-packages/PIL/Image.py'),
1593
          loc('../../../../../Python27/Lib/site-packages/PIL/Image.py'),
1592
          loc('sources/lmt.py'),
1594
          loc('sources/lmt.py'),
1593
-         loc('ContentSources.py')]),
1595
+         loc('ContentSources.py'),
1596
+         loc('sources/play24.py')]),
1594
                                'open_files': [u'changelog.md',
1597
                                'open_files': [u'changelog.md',
1595
         u'run.py',
1598
         u'run.py',
1596
         u'sources/config.py',
1599
         u'sources/config.py',
1603
         u'util.py',
1606
         u'util.py',
1604
         u'sources/replay.py',
1607
         u'sources/replay.py',
1605
         u'sources/tvplay.py',
1608
         u'sources/tvplay.py',
1609
+        u'sources/play24.py',
1606
         u'sources/xtv.py']},
1610
         u'sources/xtv.py']},
1607
         'saved_notebook_display': None,
1611
         'saved_notebook_display': None,
1608
         'split_percents': {0: 0.44890202702702703},
1612
         'split_percents': {0: 0.44890202702702703},
1619
                          2432,
1623
                          2432,
1620
                          1440)}]}
1624
                          1440)}]}
1621
 guimgr.recent-documents = [loc('sources/xtv.py'),
1625
 guimgr.recent-documents = [loc('sources/xtv.py'),
1626
+                           loc('sources/play24.py'),
1622
                            loc('sources/tvplay.py'),
1627
                            loc('sources/tvplay.py'),
1623
                            loc('sources/replay.py'),
1628
                            loc('sources/replay.py'),
1624
                            loc('util.py'),
1629
                            loc('util.py'),
2047
         'sel-line-start': 5306L,
2052
         'sel-line-start': 5306L,
2048
         'selection_end': 5306L,
2053
         'selection_end': 5306L,
2049
         'selection_start': 5306L,
2054
         'selection_start': 5306L,
2055
+        'zoom': 0L},
2056
+                       loc('sources/serialguru.py'): {'attrib-starts': [('So'\
2057
+        'urce',
2058
+        25),
2059
+        ('Source.__init__',
2060
+         27)],
2061
+        'first-line': 15L,
2062
+        'folded-linenos': [],
2063
+        'sel-line': 28L,
2064
+        'sel-line-start': 817L,
2065
+        'selection_end': 882L,
2066
+        'selection_start': 825L,
2050
         'zoom': 0L},
2067
         'zoom': 0L},
2051
                        loc('sources/tmp/SourceBase.py'): {'attrib-starts': [],
2068
                        loc('sources/tmp/SourceBase.py'): {'attrib-starts': [],
2052
         'first-line': 11L,
2069
         'first-line': 11L,

+ 5
- 5
sources/xtv.py View File

50
                 ("Jaunākie", "xtv::latest", self.img,"Jaunākie video"),
50
                 ("Jaunākie", "xtv::latest", self.img,"Jaunākie video"),
51
                 ("Populārajie", "xtv::popular",self.img,"Populāraie video"),
51
                 ("Populārajie", "xtv::popular",self.img,"Populāraie video"),
52
                 ("Visi raidijumi", "xtv::programs",self.img,"Visi raidījumi"),
52
                 ("Visi raidijumi", "xtv::programs",self.img,"Visi raidījumi"),
53
-                ("Izklaide", "xtv::category/gnPBGaJp8or-izklaide?page=2",self.img,"Izklaides raidījumi un sižeti"),
54
-                ("Ziņas", "xtv::category/6blmNmLpOPR-zinas?page=2",self.img,"Ziņu raidījumi un sižeti"),
55
-                ("Diskusijas", "category/AZoQGEwNX89-diskusijas?page=2",self.img,"Diskusiju raidījumi un sižeti"),
56
-                ("Sports", "xtv::category/Lymz7BwGXEk-sports?page=2",self.img,"Sporta raidījumi un sižeti"),
53
+                ("Izklaide", "xtv::category/gnPBGaJp8or-izklaide/full_show?page=1",self.img,"Izklaides raidījumi un sižeti"),
54
+                ("Ziņas", "xtv::category/6blmNmLpOPR-zinas/full_show?page=1",self.img,"Ziņu raidījumi un sižeti"),
55
+                ("Diskusijas", "category/AZoQGEwNX89-diskusijas/full_show?page=1",self.img,"Diskusiju raidījumi un sižeti"),
56
+                ("Sports", "xtv::category/Lymz7BwGXEk-sports/full_show?page=1",self.img,"Sporta raidījumi un sižeti"),
57
                 ("Meklēt", "xtv::search?q={0}",self.img,"Meklēt raidījumus un sižetus"),
57
                 ("Meklēt", "xtv::search?q={0}",self.img,"Meklēt raidījumus un sižetus"),
58
              ])
58
              ])
59
             return content
59
             return content
66
                 title = util.unescape(re_search("<h5>([^<]+)<", r2))
66
                 title = util.unescape(re_search("<h5>([^<]+)<", r2))
67
                 data2 = re_search('href="/(.+?)"', r2)
67
                 data2 = re_search('href="/(.+?)"', r2)
68
                 if "/program/" in data2:
68
                 if "/program/" in data2:
69
-                    data2 += "?page=1"
69
+                    data2 += "/full_show?page=1"
70
                 img = re_search('src="(.+?)"', r2)
70
                 img = re_search('src="(.+?)"', r2)
71
                 duration = re_search('<span class="duration">(.+?)</span>', r2)
71
                 duration = re_search('<span class="duration">(.+?)</span>', r2)
72
                 when = re_search('<span>([^<]+)</span>', r2)
72
                 when = re_search('<span>([^<]+)</span>', r2)