1 diff --git a/mytube/meta/plugin_mytube.xml b/mytube/meta/plugin_mytube.xml
2 index eb2a0fd..56e1686 100644
3 --- a/mytube/meta/plugin_mytube.xml
4 +++ b/mytube/meta/plugin_mytube.xml
6 <hardware type="dm8000" />
7 <hardware type="dm800" />
8 <hardware type="dm800se" />
9 - <hardware type="dm500hd" />
10 + <hardware type="dm500hd" />
11 + <hardware type="dm7020hd" />
12 <tag type="Multimedia" />
15 diff --git a/mytube/po/de.po b/mytube/po/de.po
16 index b487673..c56c84e 100644
19 @@ -7,9 +7,9 @@ msgid ""
21 "Project-Id-Version: tuxbox-enigma 0.0.1\n"
22 "Report-Msgid-Bugs-To: \n"
23 -"POT-Creation-Date: 2009-05-29 17:38+0200\n"
24 -"PO-Revision-Date: 2008-05-16 17:15+0100\n"
25 -"Last-Translator: Stefan Pluecken <mladen.horvat@multimedia-labs.de>\n"
26 +"POT-Creation-Date: 2011-06-12 19:07+0100\n"
27 +"PO-Revision-Date: 2011-06-12 19:22+0100\n"
28 +"Last-Translator: JuSt611 <Software@Strasdas.de>\n"
29 "Language-Team: none\n"
31 "Content-Type: text/plain; charset=UTF-8\n"
32 @@ -18,448 +18,690 @@ msgstr ""
33 "X-Poedit-Language: German\n"
34 "X-Poedit-Country: GERMANY\n"
35 "X-Poedit-SourceCharset: iso-8859-15\n"
36 +"X-Poedit-Basepath: .\n"
37 +"X-Poedit-SearchPath-0: ../src\n"
41 +#: ../src/MyTubeSearch.py:161
42 +#: ../src/plugin.py:52
47 -msgstr "Hinzugefügt: "
48 +#: ../src/MyTubeSearch.py:162
49 +#: ../src/plugin.py:53
55 +#: ../src/MyTubeSearch.py:163
56 +#: ../src/plugin.py:54
58 +msgstr "Veröffentlicht"
60 +#: ../src/MyTubeSearch.py:164
61 +#: ../src/plugin.py:55
65 +#: ../src/MyTubeSearch.py:168
66 +#: ../src/plugin.py:59
71 -msgid "An error occured."
72 -msgstr "Es ist ein Fehler aufgetreten."
73 +#: ../src/MyTubeSearch.py:169
74 +#: ../src/plugin.py:60
76 +msgstr "Diesen Monat"
80 +#: ../src/MyTubeSearch.py:170
81 +#: ../src/plugin.py:61
86 -msgstr "Nutzer fragen"
87 +#: ../src/MyTubeSearch.py:171
88 +#: ../src/plugin.py:62
94 +#: ../src/MyTubeSearch.py:175
95 +#: ../src/plugin.py:66
96 +#: ../src/plugin.py:619
97 +#: ../src/plugin.py:625
98 +#: ../src/plugin.py:1743
104 +#: ../src/MyTubeSearch.py:176
105 +#: ../src/plugin.py:67
106 +#: ../src/plugin.py:620
107 +#: ../src/plugin.py:626
111 +#: ../src/MyTubeSearch.py:180
112 +#: ../src/MyTubeSearch.py:200
113 +#: ../src/plugin.py:71
114 +#: ../src/plugin.py:91
118 +#: ../src/MyTubeSearch.py:181
119 +#: ../src/plugin.py:72
120 +msgid "Film & Animation"
121 +msgstr "Film & Animation"
123 +#: ../src/MyTubeSearch.py:182
124 +#: ../src/plugin.py:73
125 msgid "Autos & Vehicles"
126 msgstr "Autos und Fahrzeuge"
130 +#: ../src/MyTubeSearch.py:183
131 +#: ../src/plugin.py:74
137 +#: ../src/MyTubeSearch.py:184
138 +#: ../src/plugin.py:75
139 +msgid "Pets & Animals"
142 -msgid "Choose target folder"
143 -msgstr "Wähle Zielverzeichnis"
144 +#: ../src/MyTubeSearch.py:185
145 +#: ../src/plugin.py:76
149 -msgid "Clear history on Exit:"
150 -msgstr "Verlauf beim Verlassen löschen:"
151 +#: ../src/MyTubeSearch.py:186
152 +#: ../src/plugin.py:77
153 +msgid "Travel & Events"
154 +msgstr "Reisen & Events"
158 +#: ../src/MyTubeSearch.py:187
159 +#: ../src/plugin.py:78
160 +msgid "Short Movies"
163 +#: ../src/MyTubeSearch.py:188
164 +#: ../src/plugin.py:79
168 +#: ../src/MyTubeSearch.py:189
169 +#: ../src/plugin.py:80
173 -msgid "Czech Republic"
179 -msgid "Display search results by:"
180 -msgstr "Suchergebnisse anzeigen:"
182 -msgid "Do you want to see more entries?"
183 -msgstr "Weitere Videos?"
185 -msgid "Download Video"
186 -msgstr "Video runterladen"
188 -msgid "Download location"
189 -msgstr "Download Verzeichnis:"
190 +#: ../src/MyTubeSearch.py:190
191 +#: ../src/plugin.py:81
192 +msgid "People & Blogs"
193 +msgstr "Leute & Blogs"
195 -msgid "Downloading screenshots. Please wait..."
196 -msgstr "Bilder werden geladen. Bitte warten..."
197 +#: ../src/MyTubeSearch.py:191
198 +#: ../src/plugin.py:82
199 +msgid "News & Politics"
200 +msgstr "Nachrichten & Politik"
204 +#: ../src/MyTubeSearch.py:192
205 +#: ../src/plugin.py:83
206 +msgid "Entertainment"
207 +msgstr "Unterhaltung"
209 +#: ../src/MyTubeSearch.py:193
210 +#: ../src/plugin.py:84
214 -msgid "Enter your search term(s)"
215 -msgstr "Suchbegriff eingeben"
216 +#: ../src/MyTubeSearch.py:194
217 +#: ../src/plugin.py:85
218 +msgid "Howto & Style"
219 +msgstr "Tipps & Tricks"
221 -msgid "Entertainment"
222 -msgstr "Unterhaltung"
223 +#: ../src/MyTubeSearch.py:195
224 +#: ../src/plugin.py:86
225 +msgid "Nonprofits & Activism"
228 -msgid "Fetching feed entries"
230 +#: ../src/MyTubeSearch.py:196
231 +#: ../src/plugin.py:87
232 +msgid "Science & Technology"
233 +msgstr "Wissenschaft & Technik"
235 -msgid "Fetching search entries"
236 -msgstr "Lade Suchergebnisse"
237 +#: ../src/MyTubeSearch.py:201
238 +#: ../src/MyTubeSearch.py:208
239 +#: ../src/plugin.py:92
240 +#: ../src/plugin.py:99
244 -msgid "Film & Animation"
245 -msgstr "Film & Animation"
246 +#: ../src/MyTubeSearch.py:202
247 +#: ../src/plugin.py:93
251 +#: ../src/MyTubeSearch.py:203
252 +#: ../src/plugin.py:94
256 +#: ../src/MyTubeSearch.py:204
257 +#: ../src/plugin.py:95
258 +msgid "Czech Republic"
261 +#: ../src/MyTubeSearch.py:205
262 +#: ../src/plugin.py:96
269 +#: ../src/MyTubeSearch.py:206
270 +#: ../src/plugin.py:97
274 +#: ../src/MyTubeSearch.py:207
275 +#: ../src/plugin.py:98
276 msgid "Great Britain"
288 +#: ../src/MyTubeSearch.py:209
289 +#: ../src/plugin.py:100
293 +#: ../src/MyTubeSearch.py:210
294 +#: ../src/plugin.py:101
298 -msgid "Howto & Style"
299 -msgstr "Tipps & Tricks"
301 +#: ../src/MyTubeSearch.py:211
302 +#: ../src/plugin.py:102
306 +#: ../src/MyTubeSearch.py:212
307 +#: ../src/plugin.py:103
311 +#: ../src/MyTubeSearch.py:213
312 +#: ../src/plugin.py:104
316 +#: ../src/MyTubeSearch.py:214
317 +#: ../src/plugin.py:105
321 +#: ../src/MyTubeSearch.py:215
322 +#: ../src/plugin.py:106
326 -msgid "Load feed on startup:"
327 -msgstr "Feed beim Starten laden:"
329 +#: ../src/MyTubeSearch.py:216
330 +#: ../src/plugin.py:107
334 -msgid "More video entries."
335 -msgstr "Weitere Video Einträge."
336 +#: ../src/MyTubeSearch.py:217
337 +#: ../src/plugin.py:108
341 +#: ../src/MyTubeSearch.py:218
342 +#: ../src/plugin.py:109
346 +#: ../src/MyTubeSearch.py:219
347 +#: ../src/plugin.py:110
351 +#: ../src/MyTubeSearch.py:220
352 +#: ../src/plugin.py:111
356 +#: ../src/MyTubeSearch.py:221
357 +#: ../src/plugin.py:112
361 +#: ../src/MyTubeSearch.py:222
362 +#: ../src/plugin.py:113
366 +#: ../src/MyTubeSearch.py:223
367 +#: ../src/plugin.py:114
371 +#: ../src/MyTubeSearch.py:224
372 +#: ../src/plugin.py:115
373 +msgid "United States"
376 +#: ../src/MyTubeSearch.py:228
377 +#: ../src/plugin.py:119
379 +msgstr "Aufsteigend"
381 +#: ../src/MyTubeSearch.py:229
382 +#: ../src/plugin.py:120
386 +#: ../src/MyTubeSearch.py:237
387 +#: ../src/plugin.py:128
388 +#: ../src/plugin.py:790
392 +#: ../src/MyTubeSearch.py:238
393 +#: ../src/plugin.py:129
394 +#: ../src/plugin.py:794
396 +msgstr "Meistgesehen"
398 +#: ../src/MyTubeSearch.py:239
399 +#: ../src/plugin.py:130
400 +#: ../src/plugin.py:792
402 +msgstr "Beste Bewertung"
404 +#: ../src/MyTubeSearch.py:240
405 +#: ../src/plugin.py:131
406 +#: ../src/plugin.py:799
407 +msgid "Recently featured"
408 +msgstr "Kürzlich featured"
410 +#: ../src/MyTubeSearch.py:241
411 +#: ../src/plugin.py:132
412 +#: ../src/plugin.py:797
413 msgid "Most discussed"
414 msgstr "Heiß diskutiert"
416 +#: ../src/MyTubeSearch.py:242
417 +#: ../src/plugin.py:133
418 +#: ../src/plugin.py:793
419 +msgid "Top favorites"
420 +msgstr "Top-Favoriten"
422 +#: ../src/MyTubeSearch.py:243
423 +#: ../src/plugin.py:134
424 +#: ../src/plugin.py:798
426 msgstr "Am meisten verlinkt"
428 -msgid "Most popular"
429 -msgstr "Beliebteste Videos"
430 +#: ../src/MyTubeSearch.py:244
431 +#: ../src/plugin.py:135
432 +#: ../src/plugin.py:800
433 +msgid "Most responded"
434 +msgstr "Meiste Antworten"
436 +#: ../src/MyTubeSearch.py:245
437 +#: ../src/plugin.py:136
438 +#: ../src/plugin.py:796
440 msgstr "Neueste Videos"
442 -msgid "Most responded"
443 -msgstr "Meiste Antworten"
446 -msgstr "Meistgesehen"
447 +#: ../src/MyTubeSearch.py:249
448 +#: ../src/MyTubeSearch.py:252
449 +#: ../src/plugin.py:139
450 +#: ../src/plugin.py:142
452 +msgstr "Nutzer fragen"
456 +#: ../src/MyTubeSearch.py:249
457 +#: ../src/MyTubeSearch.py:252
458 +#: ../src/plugin.py:139
459 +#: ../src/plugin.py:142
460 +msgid "Return to movie list"
461 +msgstr "Zurück zur Videoliste"
463 -msgid "My TubePlayer"
464 -msgstr "MyTube Player"
465 +#: ../src/MyTubeSearch.py:249
466 +#: ../src/plugin.py:139
467 +msgid "Play next video"
468 +msgstr "nächstes Video"
470 -msgid "MyTube Settings"
471 -msgstr "MyTube Einstellungen"
472 +#: ../src/MyTubeSearch.py:249
473 +#: ../src/plugin.py:139
474 +msgid "Play video again"
475 +msgstr "Video noch mal abspielen"
477 -msgid "MyTubePlayer"
478 -msgstr "MyTube Player"
479 +#: ../src/MyTubeSearch.py:314
481 +msgstr " Ergebnisse"
483 -msgid "MyTubePlayer Help"
484 -msgstr "MyTube Player Hilfe"
485 +#: ../src/MyTubeSearch.py:398
486 +#: ../src/MyTubeSearch.py:562
487 +#: ../src/plugin.py:281
488 +#: ../src/plugin.py:1280
489 +#: ../src/plugin.py:1466
493 -msgid "MyTubePlayer active video downloads"
494 -msgstr "aktive Video downloads"
495 +#: ../src/MyTubeSearch.py:399
499 +#: ../src/MyTubeSearch.py:412
500 +#: ../src/MyTubeSearch.py:415
501 msgid "MyTubePlayer settings"
502 msgstr "MyTube Player Einstellungen"
504 -msgid "MyTubeVideoInfoScreen"
505 -msgstr "MyTubeVideoInfoScreen"
506 +#: ../src/MyTubeSearch.py:419
507 +msgid "Display search results by:"
508 +msgstr "Suchergebnisse anzeigen:"
510 -msgid "MyTubeVideohelpScreen"
511 -msgstr "MyTubeVideohelpScreen"
512 +#: ../src/MyTubeSearch.py:420
513 +msgid "Search restricted content:"
514 +msgstr "Suche ohne Altersbeschränkung:"
517 -msgstr "Neu Seeland"
518 +#: ../src/MyTubeSearch.py:421
519 +msgid "Search category:"
520 +msgstr "Such-Kategorie:"
522 -msgid "News & Politics"
523 -msgstr "Nachrichten & Politik"
524 +#: ../src/MyTubeSearch.py:422
525 +msgid "Search region:"
526 +msgstr "Such-Region:"
530 +#: ../src/MyTubeSearch.py:423
531 +msgid "Load feed on startup:"
532 +msgstr "Feed beim Starten laden:"
534 -msgid "No playable video found! Stop playing this movie?"
535 -msgstr "Kein abspielbares Video gefunden! Wiedergabe beenden?"
536 +#: ../src/MyTubeSearch.py:426
537 +msgid "Start with following feed:"
538 +msgstr "Beginne mit folgendem feed:"
540 -msgid "No videos to display"
541 -msgstr "Keine Videos zum anzeigen"
542 +#: ../src/MyTubeSearch.py:427
543 +msgid "Videoplayer stop/exit behavior:"
544 +msgstr "Verhalten beim Drücken der STOPP/EXIT-Taste:"
546 -msgid "No, but play video again"
547 -msgstr "Nein, aber Video noch mal abspielen"
548 +#: ../src/MyTubeSearch.py:428
549 +msgid "Videobrowser exit behavior:"
550 +msgstr "Verhalten nach Verlassen der Videoliste:"
552 -msgid "No, but switch to video entries."
553 -msgstr "Nein, aber zu den Videos zurück."
554 +#: ../src/MyTubeSearch.py:435
555 +msgid "Download location"
556 +msgstr "Download Verzeichnis:"
558 -msgid "No, but switch to video search."
559 -msgstr "Nein, aber zur Videosuche zurück"
560 +#: ../src/MyTubeSearch.py:438
561 +msgid "Clear history on Exit:"
562 +msgstr "Verlauf beim Verlassen löschen:"
564 -msgid "Nonprofits & Activism"
566 +#: ../src/MyTubeSearch.py:459
567 +msgid "Choose target folder"
568 +msgstr "Wähle Zielverzeichnis"
570 -msgid "Not fetching feed entries"
571 -msgstr "Lade keine feed Einträge"
573 -msgid "People & Blogs"
574 -msgstr "Leute & Blogs"
576 -msgid "Pets & Animals"
579 -msgid "Play YouTube movies"
580 -msgstr "YouTube Videos abspielen"
582 -msgid "Play next video"
583 -msgstr "nächstes Video"
585 -msgid "Play video again"
586 -msgstr "Video noch mal abspielen"
587 +#: ../src/MyTubeSearch.py:575
588 +#: ../src/MyTubeSearch.py:591
589 +msgid "MyTubePlayer active video downloads"
590 +msgstr "aktive Video downloads"
592 -msgid "Please enter your search term."
593 -msgstr "Bitte geben Sie einen Suchbegriff ein."
594 +#: ../src/plugin.py:271
596 +"Welcome to the MyTube Youtube Player.\n"
598 +"While entering your search term(s) you will get suggestions displayed matching your search term.\n"
600 +"To select a suggestion press DOWN on your remote, select the desired result and press OK on your remote to start the search.\n"
602 +"Press exit to get back to the input field."
604 +"Herzlich Willkommen beim MyTube YouTube Player.\n"
606 +"Während der Eingabe Ihres Suchwortes erhalten Sie passende Vorschläge zu Ihrer Sucheingabe.\n"
608 +"Um einen Vorschlag auszuwählen, drücken Sie die NACH UNTEN-Taste, wählen den entsprechenden Eintrag aus und drücken die OK-Taste um die Suche zu starten.\n"
610 +"Um zur Such-Eingabemaske zurück zu gelangen, drücken Sie die EXIT-Taste."
612 -msgid "Please select a standard feed or try searching for videos."
613 -msgstr "Wählen Sie einen Standard Feed oder suchen Sie nach Videos."
614 +#: ../src/plugin.py:272
616 +"Welcome to the MyTube Youtube Player.\n"
618 +"Use the Bouqet+ button to navigate to the search field and the Bouqet- to navigate to the video entries.\n"
620 +"To play a movie just press OK on your remote control.\n"
622 +"Press info to see the movie description.\n"
624 +"Press the Menu button for additional options.\n"
626 +"The Help button shows this help again."
628 +"Herzlich Willkommen beim MyTube YouTube Player.\n"
630 +"Nutzen Sie die Bouqet+ Taste um zur Sucheingabe zu gelangen und die Bouqet- Taste für die Video Einträge.\n"
632 +"Um ein Video abzuspielen drücken Sie die OK-Taste auf Ihrer Fernbedienung.\n"
634 +"Mit der Info-Taste erhalten Sie die erweiterte Beschreibung zu einem Video.\n"
636 +"Für weitere Einstellungen drücken Sie die Menü-Taste.\n"
638 +"Um diese Hilfe erneut anzuzeigen, drücken Sie die Hilfe-Taste."
642 +#: ../src/plugin.py:282
647 -msgstr "Veröffentlicht"
648 +#: ../src/plugin.py:283
654 +#: ../src/plugin.py:398
655 +#: ../src/plugin.py:422
656 +#: ../src/plugin.py:464
657 +msgid "Genuine Dreambox validation failed!"
658 +msgstr "Prüfung auf Original-Dreambox gescheitert!"
661 -msgstr "Bewertungen: "
662 +#: ../src/plugin.py:398
663 +#: ../src/plugin.py:422
664 +#: ../src/plugin.py:464
665 +msgid "Verify your Dreambox authenticity by running the genuine dreambox plugin!"
666 +msgstr "Bitte mit dem \"Genuine Dreambox Plugin\" auf Echtheit prüfen!"
668 -msgid "Really quit MyTube Player?"
669 -msgstr "MyTube Player wirklich beenden?"
670 +#: ../src/plugin.py:417
671 +#: ../src/plugin.py:476
672 +msgid "Fetching feed entries"
675 -msgid "Recently featured"
676 -msgstr "Kürzlich featured"
677 +#: ../src/plugin.py:417
678 +#: ../src/plugin.py:476
679 +msgid "Trying to download the Youtube feed entries. Please wait..."
680 +msgstr "YouTube feeds werden geladen, bitte warten..."
682 -msgid "Related video entries."
683 -msgstr "Ähnliche Videos"
684 +#: ../src/plugin.py:434
685 +msgid "MyTubePlayer"
686 +msgstr "MyTube Player"
690 +#: ../src/plugin.py:438
691 +msgid "Search Term(s)"
692 +msgstr "Suchwort(e)"
694 -msgid "Response video entries."
695 -msgstr "Video Antworten"
696 +#: ../src/plugin.py:478
697 +msgid "Fetching search entries"
698 +msgstr "Lade Suchergebnisse"
700 -msgid "Return to movie list"
701 -msgstr "Zurück zur Videoliste"
702 +#: ../src/plugin.py:478
703 +msgid "Trying to download the Youtube search results. Please wait..."
704 +msgstr "YouTube Suchergebnisse werden geladen, bitte warten..."
708 +#: ../src/plugin.py:480
709 +msgid "An error occured."
710 +msgstr "Es ist ein Fehler aufgetreten."
714 +#: ../src/plugin.py:480
715 +msgid "There was an error getting the feed entries. Please try again."
716 +msgstr "Fehler beim Laden der Suchergebnisse. Noch mal probieren."
718 -msgid "Science & Technology"
719 -msgstr "Wissenschaft & Technik"
720 +#: ../src/plugin.py:483
721 +msgid "No videos to display"
722 +msgstr "Keine Videos zum anzeigen"
724 -msgid "Search Term(s)"
725 -msgstr "Suchwort(e)"
726 +#: ../src/plugin.py:483
727 +msgid "Please select a standard feed or try searching for videos."
728 +msgstr "Wählen Sie einen Standard Feed oder suchen Sie nach Videos."
730 -msgid "Search category:"
731 -msgstr "Such-Kategorie:"
732 +#: ../src/plugin.py:485
733 +msgid "Not fetching feed entries"
734 +msgstr "Lade keine feed Einträge"
736 -msgid "Search region:"
737 -msgstr "Such-Region:"
738 +#: ../src/plugin.py:485
739 +msgid "Please enter your search term."
740 +msgstr "Bitte geben Sie einen Suchbegriff ein."
742 -msgid "Search restricted content:"
743 -msgstr "Suche ohne Altersbeschränkung:"
744 +#: ../src/plugin.py:504
745 +#: ../src/plugin.py:506
746 +#: ../src/plugin.py:513
747 +msgid "MyTubePlayer Help"
748 +msgstr "MyTube Player Hilfe"
750 -msgid "Select new feed to view."
751 -msgstr "Neuen feed auswählen"
752 +#: ../src/plugin.py:525
753 +#: ../src/plugin.py:531
754 +msgid "MyTube Settings"
755 +msgstr "MyTube Einstellungen"
757 +#: ../src/plugin.py:528
758 +#: ../src/plugin.py:543
759 msgid "Select your choice."
760 msgstr "Treffen Sie Ihre Wahl."
762 -msgid "Short Movies"
765 -msgid "Sorry, video is not available!"
766 -msgstr "Video nicht verfügbar!"
777 -msgid "Start with following feed:"
778 -msgstr "Beginne mit folgendem feed:"
779 +#: ../src/plugin.py:533
780 +msgid "View related videos"
781 +msgstr "Ähnliche Videos"
785 +#: ../src/plugin.py:534
786 +msgid "View response videos"
787 +msgstr "Video Antworten"
789 -msgid "Stop playing this movie?"
790 -msgstr "Wiedergabe beenden?"
791 +#: ../src/plugin.py:538
792 +msgid "Download Video"
793 +msgstr "Video runterladen"
797 +#: ../src/plugin.py:539
798 +msgid "View active downloads"
799 +msgstr "Aktive Downloads anzeigen"
803 +#: ../src/plugin.py:577
804 +msgid "Enter your search term(s)"
805 +msgstr "Suchbegriff eingeben"
809 +#: ../src/plugin.py:621
810 +msgid "No, but switch to video entries."
811 +msgstr "Nein, aber zu den Videos zurück."
813 -msgid "There was an error getting the feed entries. Please try again."
814 -msgstr "Fehler beim Laden der Suchergebnisse. Noch mal probieren."
815 +#: ../src/plugin.py:627
816 +msgid "No, but switch to video search."
817 +msgstr "Nein, aber zur Videosuche zurück"
820 -msgstr "Diesen Monat"
821 +#: ../src/plugin.py:629
822 +msgid "Really quit MyTube Player?"
823 +msgstr "MyTube Player wirklich beenden?"
826 -msgstr "Diese Woche"
827 +#: ../src/plugin.py:722
828 +msgid "Sorry, video is not available!"
829 +msgstr "Video nicht verfügbar!"
831 -msgid "This is the help screen. Feed me with something to display."
833 +#: ../src/plugin.py:757
834 +msgid "Do you want to see more entries?"
835 +msgstr "Weitere Videos?"
839 +#: ../src/plugin.py:795
840 +msgid "Most popular"
841 +msgstr "Beliebteste Videos"
843 -msgid "Top favorites"
844 -msgstr "Top-Favoriten"
845 +#: ../src/plugin.py:802
846 +msgid "Select new feed to view."
847 +msgstr "Neuen feed auswählen"
850 -msgstr "Beste Bewertung"
851 +#: ../src/plugin.py:968
852 +msgid "More video entries."
853 +msgstr "Weitere Video Einträge."
855 -msgid "Travel & Events"
856 -msgstr "Reisen & Events"
857 +#: ../src/plugin.py:976
858 +msgid "Related video entries."
859 +msgstr "Ähnliche Videos"
861 -msgid "Trying to download the Youtube feed entries. Please wait..."
862 -msgstr "YouTube feeds werden geladen, bitte warten..."
863 +#: ../src/plugin.py:984
864 +msgid "Response video entries."
865 +msgstr "Video Antworten"
867 -msgid "Trying to download the Youtube search results. Please wait..."
868 -msgstr "YouTube Suchergebnisse werden geladen, bitte warten..."
869 +#: ../src/plugin.py:1103
870 +#: ../src/plugin.py:1341
872 +msgstr "Hinzugefügt: "
874 -msgid "United States"
876 +#: ../src/plugin.py:1103
877 +#: ../src/plugin.py:1344
881 -msgid "Videobrowser exit behavior:"
882 -msgstr "Verhalten nach Verlassen der Videoliste:"
883 +#: ../src/plugin.py:1103
884 +#: ../src/plugin.py:1335
888 -msgid "Videoplayer stop/exit behavior:"
889 -msgstr "Verhalten beim Drücken der STOPP/EXIT-Taste:"
890 +#: ../src/plugin.py:1103
892 +msgstr "Bewertungen: "
896 +#: ../src/plugin.py:1309
897 +msgid "Downloading screenshots. Please wait..."
898 +msgstr "Bilder werden geladen. Bitte warten..."
900 -msgid "View active downloads"
901 -msgstr "Aktive Downloads anzeigen"
902 +#: ../src/plugin.py:1338
906 -msgid "View related videos"
907 -msgstr "Ähnliche Videos"
908 +#: ../src/plugin.py:1347
912 -msgid "View response videos"
913 -msgstr "Video Antworten"
914 +#: ../src/plugin.py:1350
915 +msgid "MyTubeVideoInfoScreen"
916 +msgstr "MyTubeVideoInfoScreen"
920 +#: ../src/plugin.py:1484
925 -"Welcome to the MyTube Youtube Player.\n"
927 -"Use the Bouqet+ button to navigate to the search field and the Bouqet- to "
928 -"navigate to the video entries.\n"
930 -"To play a movie just press OK on your remote control.\n"
932 -"Press info to see the movie description.\n"
934 -"Press the Menu button for additional options.\n"
936 -"The Help button shows this help again."
938 -"Herzlich Willkommen beim MyTube YouTube Player.\n"
940 -"Nutzen Sie die Bouqet+ Taste um zur Sucheingabe zu gelangen und die Bouqet- "
941 -"Taste für die Video Einträge.\n"
943 -"Um ein Video abzuspielen drücken Sie die OK-Taste auf Ihrer Fernbedienung.\n"
945 -"Mit der Info-Taste erhalten Sie die erweiterte Beschreibung zu einem Video.\n"
947 -"Für weitere Einstellungen drücken Sie die Menü-Taste.\n"
949 -"Um diese Hilfe erneut anzuzeigen, drücken Sie die Hilfe-Taste."
950 +#: ../src/plugin.py:1488
951 +msgid "This is the help screen. Feed me with something to display."
952 +msgstr "Dies ist die MyTube Hilfe. Bitte ausfüllen."
955 -"Welcome to the MyTube Youtube Player.\n"
957 -"While entering your search term(s) you will get suggestions displayed "
958 -"matching your search term.\n"
960 -"To select a suggestion press DOWN on your remote, select the desired result "
961 -"and press OK on your remote to start the search.\n"
963 -"Press exit to get back to the input field."
965 -"Herzlich Willkommen beim MyTube YouTube Player.\n"
967 -"Während der Eingabe Ihres Suchwortes erhalten Sie passende Vorschläge zu "
968 -"Ihrer Sucheingabe.\n"
970 -"Um einen Vorschlag auszuwählen drücken Sie die NACH UNTEN-Taste, wählen den "
971 -"entsprechenden Eintrag aus und drücken die OK-Taste um die Suche zu "
974 -"Um zur Such-Eingabemaske zurück zu gelangen drücken Sie die EXIT-Taste."
975 +#: ../src/plugin.py:1493
976 +msgid "MyTubeVideohelpScreen"
977 +msgstr "MyTubeVideohelpScreen"
981 +#: ../src/plugin.py:1744
982 +msgid "No, but play video again"
983 +msgstr "Nein, aber Video noch mal abspielen"
985 +#: ../src/plugin.py:1745
986 msgid "Yes, but play next video"
987 msgstr "Ja, aber nächstes Video abspielen"
989 +#: ../src/plugin.py:1746
990 msgid "Yes, but play previous video"
991 msgstr "Ja, aber vorheriges Video abspielen"
993 +#: ../src/plugin.py:1749
994 +msgid "Stop playing this movie?"
995 +msgstr "Wiedergabe beenden?"
997 +#: ../src/plugin.py:1751
998 +msgid "No playable video found! Stop playing this movie?"
999 +msgstr "Kein abspielbares Video gefunden! Wiedergabe beenden?"
1001 +#: ../src/plugin.py:1797
1002 +msgid "My TubePlayer"
1003 +msgstr "MyTube Player"
1005 +#: ../src/plugin.py:1798
1006 +msgid "Play YouTube movies"
1007 +msgstr "YouTube Videos abspielen"
1009 #~ msgid "View Downloads"
1010 #~ msgstr "Downloads anzeigen"
1011 diff --git a/mytube/src/MyTubeSearch.py b/mytube/src/MyTubeSearch.py
1012 index be63669..a1a324c 100755
1013 --- a/mytube/src/MyTubeSearch.py
1014 +++ b/mytube/src/MyTubeSearch.py
1016 +from enigma import eListboxPythonMultiContent, RT_HALIGN_LEFT, RT_HALIGN_RIGHT, gFont, eTimer
1017 from MyTubeService import GoogleSuggestions
1018 from Screens.Screen import Screen
1019 from Screens.LocationBox import MovieLocationBox
1020 -from Components.config import config, Config, ConfigSelection, ConfigText, getConfigListEntry, ConfigSubsection, ConfigYesNo, ConfigIP, ConfigNumber,ConfigLocations
1021 +from Components.config import config, ConfigText, getConfigListEntry
1022 +from Components.config import KEY_DELETE, KEY_BACKSPACE, KEY_ASCII, KEY_TIMEOUT
1023 from Components.ConfigList import ConfigListScreen
1024 -from Components.config import KEY_DELETE, KEY_BACKSPACE, KEY_LEFT, KEY_RIGHT, KEY_HOME, KEY_END, KEY_TOGGLEOW, KEY_ASCII, KEY_TIMEOUT
1025 from Components.ActionMap import ActionMap
1026 from Components.Button import Button
1027 from Components.Label import Label
1028 -from Components.ScrollLabel import ScrollLabel
1029 from Components.Sources.List import List
1030 -from Components.Pixmap import Pixmap
1031 -from Components.MultiContent import MultiContentEntryText, MultiContentEntryPixmapAlphaTest
1032 -from Components.Task import Task, Job, job_manager
1033 -from enigma import eListboxPythonMultiContent, RT_HALIGN_LEFT, RT_HALIGN_RIGHT, gFont, eListbox,ePoint,eTimer
1034 +from Components.MultiContent import MultiContentEntryText
1035 from Components.Task import job_manager
1036 -from Tools.Directories import pathExists, fileExists, resolveFilename, SCOPE_HDD
1037 +from Tools.Directories import resolveFilename, SCOPE_HDD
1039 from threading import Thread
1040 from threading import Condition
1041 from xml.etree.cElementTree import parse as cet_parse
1042 from StringIO import StringIO
1047 from urllib import FancyURLopener
1049 class MyOpener(FancyURLopener):
1050 version = 'Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.12) Gecko/20070731 Ubuntu/dapper-security Firefox/1.5.0.12'
1053 class ConfigTextWithGoogleSuggestions(ConfigText):
1054 class SuggestionsThread(Thread):
1055 def __init__(self, suggestionsService):
1056 @@ -151,122 +146,14 @@ class ConfigTextWithGoogleSuggestions(ConfigText):
1057 if self.suggestionsWindow is not None:
1058 self.suggestionsWindow.enableSelection(value)
1061 -config.plugins.mytube = ConfigSubsection()
1062 -config.plugins.mytube.search = ConfigSubsection()
1064 -config.plugins.mytube.search.searchTerm = ConfigTextWithGoogleSuggestions("", False, threaded = True)
1065 -config.plugins.mytube.search.orderBy = ConfigSelection(
1067 - ("relevance", _("Relevance")),
1068 - ("viewCount", _("View Count")),
1069 - ("published", _("Published")),
1070 - ("rating", _("Rating"))
1072 -config.plugins.mytube.search.time = ConfigSelection(
1074 - ("all_time", _("All Time")),
1075 - ("this_month", _("This Month")),
1076 - ("this_week", _("This Week")),
1077 - ("today", _("Today"))
1079 -config.plugins.mytube.search.racy = ConfigSelection(
1081 - ("include", _("Yes")),
1082 - ("exclude", _("No"))
1084 -config.plugins.mytube.search.categories = ConfigSelection(
1087 - ("Film", _("Film & Animation")),
1088 - ("Autos", _("Autos & Vehicles")),
1089 - ("Music", _("Music")),
1090 - ("Animals", _("Pets & Animals")),
1091 - ("Sports", _("Sports")),
1092 - ("Travel", _("Travel & Events")),
1093 - ("Shortmov", _("Short Movies")),
1094 - ("Games", _("Gaming")),
1095 - ("Comedy", _("Comedy")),
1096 - ("People", _("People & Blogs")),
1097 - ("News", _("News & Politics")),
1098 - ("Entertainment", _("Entertainment")),
1099 - ("Education", _("Education")),
1100 - ("Howto", _("Howto & Style")),
1101 - ("Nonprofit", _("Nonprofits & Activism")),
1102 - ("Tech", _("Science & Technology"))
1104 -config.plugins.mytube.search.lr = ConfigSelection(
1107 - ("au", _("Australia")),
1108 - ("br", _("Brazil")),
1109 - ("ca", _("Canada")),
1110 - ("cz", _("Czech Republic")),
1111 - ("fr", _("France")),
1112 - ("de", _("Germany")),
1113 - ("gb", _("Great Britain")),
1114 - ("au", _("Australia")),
1115 - ("nl", _("Holland")),
1116 - ("hk", _("Hong Kong")),
1117 - ("in", _("India")),
1118 - ("ie", _("Ireland")),
1119 - ("il", _("Israel")),
1120 - ("it", _("Italy")),
1121 - ("jp", _("Japan")),
1122 - ("mx", _("Mexico")),
1123 - ("nz", _("New Zealand")),
1124 - ("pl", _("Poland")),
1125 - ("ru", _("Russia")),
1126 - ("kr", _("South Korea")),
1127 - ("es", _("Spain")),
1128 - ("se", _("Sweden")),
1129 - ("tw", _("Taiwan")),
1130 - ("us", _("United States"))
1132 -config.plugins.mytube.search.sortOrder = ConfigSelection(
1134 - ("ascending", _("Ascending")),
1135 - ("descending", _("Descending"))
1138 -config.plugins.mytube.general = ConfigSubsection()
1139 -config.plugins.mytube.general.showHelpOnOpen = ConfigYesNo(default = True)
1140 -config.plugins.mytube.general.loadFeedOnOpen = ConfigYesNo(default = True)
1141 -config.plugins.mytube.general.startFeed = ConfigSelection(
1143 - ("hd", _("HD videos")),
1144 - ("most_viewed", _("Most viewed")),
1145 - ("top_rated", _("Top rated")),
1146 - ("recently_featured", _("Recently featured")),
1147 - ("most_discussed", _("Most discussed")),
1148 - ("top_favorites", _("Top favorites")),
1149 - ("most_linked", _("Most linked")),
1150 - ("most_responded", _("Most responded")),
1151 - ("most_recent", _("Most recent"))
1154 -config.plugins.mytube.general.on_movie_stop = ConfigSelection(default = "ask", choices = [
1155 - ("ask", _("Ask user")), ("quit", _("Return to movie list")), ("playnext", _("Play next video")), ("playagain", _("Play video again")) ])
1157 -config.plugins.mytube.general.on_exit = ConfigSelection(default = "ask", choices = [
1158 - ("ask", _("Ask user")), ("quit", _("Return to movie list"))])
1161 default = resolveFilename(SCOPE_HDD)
1162 tmp = config.movielist.videodirs.value
1163 if default not in tmp:
1165 -config.plugins.mytube.general.videodir = ConfigSelection(default = default, choices = tmp)
1166 -config.plugins.mytube.general.history = ConfigText(default="")
1167 -config.plugins.mytube.general.clearHistoryOnClose = ConfigYesNo(default = False)
1169 -#config.plugins.mytube.general.useHTTPProxy = ConfigYesNo(default = False)
1170 -#config.plugins.mytube.general.ProxyIP = ConfigIP(default=[0,0,0,0])
1171 -#config.plugins.mytube.general.ProxyPort = ConfigNumber(default=8080)
1173 class MyTubeSuggestionsListScreen(Screen):
1175 - <screen name="MyTubeSuggestionsListScreen" position="60,93" zPosition="6" size="610,160" flags="wfNoBorder" >
1176 + <screen name="MyTubeSuggestionsListScreen" title="MyTube - Search" position="60,93" zPosition="6" size="610,160" flags="wfNoBorder" >
1177 <ePixmap position="0,0" zPosition="-1" size="610,160" pixmap="/usr/lib/enigma2/python/Plugins/Extensions/MyTube/suggestions_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1178 <widget source="suggestionslist" render="Listbox" position="10,5" zPosition="7" size="580,150" scrollbarMode="showOnDemand" transparent="1" >
1179 <convert type="TemplatedMultiContent">
1180 @@ -366,7 +253,7 @@ class MyTubeSuggestionsListScreen(Screen):
1182 class MyTubeSettingsScreen(Screen, ConfigListScreen):
1184 - <screen name="MyTubeSettingsScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTubePlayerMainScreen..." >
1185 + <screen name="MyTubeSettingsScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTube - Settings" >
1186 <ePixmap position="0,0" zPosition="-1" size="720,576" pixmap="~/mytubemain_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1187 <widget name="title" position="60,50" size="600,50" zPosition="5" valign="center" halign="left" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
1188 <widget name="config" zPosition="2" position="60,120" size="610,370" scrollbarMode="showOnDemand" transparent="1" />
1189 @@ -524,7 +411,7 @@ class MyTubeSettingsScreen(Screen, ConfigListScreen):
1191 class MyTubeTasksScreen(Screen):
1193 - <screen name="MyTubeTasksScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTubePlayerMainScreen..." >
1194 + <screen name="MyTubeTasksScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTube - Tasks" >
1195 <ePixmap position="0,0" zPosition="-1" size="720,576" pixmap="~/mytubemain_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1196 <widget name="title" position="60,50" size="600,50" zPosition="5" valign="center" halign="left" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
1197 <widget source="tasklist" render="Listbox" position="60,120" size="610,370" zPosition="7" scrollbarMode="showOnDemand" transparent="1" >
1198 @@ -610,7 +497,7 @@ class MyTubeTasksScreen(Screen):
1200 class MyTubeHistoryScreen(Screen):
1202 - <screen name="MyTubeHistoryScreen" position="60,93" zPosition="6" size="610,160" flags="wfNoBorder" >
1203 + <screen name="MyTubeHistoryScreen" position="60,93" zPosition="6" size="610,160" flags="wfNoBorder" title="MyTube - History">
1204 <ePixmap position="0,0" zPosition="-1" size="610,160" pixmap="/usr/lib/enigma2/python/Plugins/Extensions/MyTube/suggestions_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1205 <widget source="historylist" render="Listbox" position="10,5" zPosition="7" size="580,150" scrollbarMode="showOnDemand" transparent="1" >
1206 <convert type="TemplatedMultiContent">
1207 diff --git a/mytube/src/MyTubeService.py b/mytube/src/MyTubeService.py
1208 index 246575c..9a1d6fd 100755
1209 --- a/mytube/src/MyTubeService.py
1210 +++ b/mytube/src/MyTubeService.py
1212 # -*- coding: iso-8859-1 -*-
1213 -from __init__ import bin2long, long2bin, rsa_pub1024, decrypt_block
1214 +from enigma import ePythonMessagePump
1216 +from __init__ import decrypt_block
1217 +from ThreadQueue import ThreadQueue
1218 import gdata.youtube
1219 import gdata.youtube.service
1220 from gdata.service import BadAuthentication
1221 -from Tools.LoadPixmap import LoadPixmap
1222 -from Components.config import config, Config, ConfigSelection, ConfigText, getConfigListEntry, ConfigSubsection, ConfigYesNo, ConfigIP, ConfigNumber
1223 -from Components.ConfigList import ConfigListScreen
1224 -from Components.config import KEY_DELETE, KEY_BACKSPACE, KEY_LEFT, KEY_RIGHT, KEY_HOME, KEY_END, KEY_TOGGLEOW, KEY_ASCII, KEY_TIMEOUT
1226 from twisted.web import client
1227 from twisted.internet import reactor
1228 -from urllib2 import Request, URLError, HTTPError, urlopen as urlopen2
1229 -from socket import gaierror,error
1230 -import re, os, sys, socket
1231 +from urllib2 import Request, URLError, urlopen as urlopen2
1232 +from socket import gaierror, error
1234 from urllib import quote, unquote_plus, unquote
1236 -from httplib import HTTPConnection,CannotSendRequest,BadStatusLine,HTTPException
1237 -HTTPConnection.debuglevel = 1
1238 +from httplib import HTTPConnection, CannotSendRequest, BadStatusLine, HTTPException
1240 from urlparse import parse_qs
1241 +from threading import Thread
1243 +HTTPConnection.debuglevel = 1
1245 def validate_cert(cert, key):
1246 buf = decrypt_block(cert[8:], key)
1247 @@ -50,7 +51,7 @@ std_headers = {
1249 class GoogleSuggestions():
1250 def __init__(self, callback, ds = None, json = None, hl = None):
1251 - self.callback = callback
1252 + self.gotFeed = callback
1253 self.conn = HTTPConnection("google.com")
1254 #GET /complete/search?output=toolbar&ds=yt&hl=en&jsonp=self.gotSuggestions&q=s
1255 self.prepQuerry = "/complete/search?output=toolbar&"
1256 @@ -63,7 +64,7 @@ class GoogleSuggestions():
1257 self.prepQuerry = self.prepQuerry + "jsonp=self.gotSuggestions&q="
1259 def gotSuggestions(self, suggestslist):
1260 - self.callback(suggestslist)
1261 + self.gotFeed(suggestslist)
1263 def getSuggestions(self, querryString):
1264 if querryString is not "":
1265 @@ -72,22 +73,22 @@ class GoogleSuggestions():
1266 self.conn.request("GET", querry)
1267 except (CannotSendRequest, gaierror, error):
1268 print "[MyTube] Can not send request for suggestions"
1269 - self.callback(None)
1270 + self.gotFeed(None)
1273 response = self.conn.getresponse()
1274 except BadStatusLine:
1275 print "[MyTube] Can not get a response from google"
1276 - self.callback(None)
1277 + self.gotFeed(None)
1279 if response.status == 200:
1280 data = response.read()
1281 self.gotSuggestions(data)
1283 - self.callback(None)
1284 + self.gotFeed(None)
1287 - self.callback(None)
1288 + self.gotFeed(None)
1291 class MyTubeFeedEntry():
1292 @@ -224,16 +225,16 @@ class MyTubeFeedEntry():
1294 infopage = urlopen2(request).read()
1295 videoinfo = parse_qs(infopage)
1296 - if 'fmt_url_map' in videoinfo:
1297 + if ('url_encoded_fmt_stream_map' or 'fmt_url_map') in videoinfo:
1299 except (URLError, HTTPException, socket.error), err:
1300 print "[MyTube] Error: unable to download video infopage",str(err)
1303 - if 'fmt_url_map' not in videoinfo:
1304 + if ('url_encoded_fmt_stream_map' or 'fmt_url_map') not in videoinfo:
1305 # Attempt to see if YouTube has issued an error message
1306 if 'reason' not in videoinfo:
1307 - print '[MyTube] Error: unable to extract "fmt_url_map" parameter for unknown reason'
1308 + print '[MyTube] Error: unable to extract "fmt_url_map" or "url_encoded_fmt_stream_map" parameter for unknown reason'
1310 reason = unquote_plus(videoinfo['reason'][0])
1311 print '[MyTube] Error: YouTube said: %s' % reason.decode('utf-8')
1312 @@ -241,22 +242,51 @@ class MyTubeFeedEntry():
1316 - tmp_fmtUrlDATA = videoinfo['fmt_url_map'][0].split(',')
1317 + if videoinfo.has_key('url_encoded_fmt_stream_map'):
1318 + tmp_fmtUrlDATA = videoinfo['url_encoded_fmt_stream_map'][0].split(',')
1320 + tmp_fmtUrlDATA = videoinfo['fmt_url_map'][0].split(',')
1321 for fmtstring in tmp_fmtUrlDATA:
1322 - (fmtid,fmturl) = fmtstring.split('|')
1323 - if VIDEO_FMT_PRIORITY_MAP.has_key(fmtid):
1324 + fmturl = fmtid = fmtsig = ""
1325 + if videoinfo.has_key('url_encoded_fmt_stream_map'):
1327 + for arg in fmtstring.split('&'):
1328 + if arg.find('=') >= 0:
1329 + print arg.split('=')
1330 + key, value = arg.split('=')
1332 + if len(value) > 3:
1335 + elif key == 'url':
1337 + elif key == 'sig':
1340 + if fmtid != "" and fmturl != "" and fmtsig != "" and VIDEO_FMT_PRIORITY_MAP.has_key(fmtid):
1341 + video_fmt_map[VIDEO_FMT_PRIORITY_MAP[fmtid]] = { 'fmtid': fmtid, 'fmturl': unquote_plus(fmturl), 'fmtsig': fmtsig }
1342 + fmt_infomap[int(fmtid)] = "%s&signature=%s" %(unquote_plus(fmturl), fmtsig)
1343 + fmturl = fmtid = fmtsig = ""
1346 + print "error parsing fmtstring:",fmtstring
1349 + (fmtid,fmturl) = fmtstring.split('|')
1350 + if VIDEO_FMT_PRIORITY_MAP.has_key(fmtid) and fmtid != "":
1351 video_fmt_map[VIDEO_FMT_PRIORITY_MAP[fmtid]] = { 'fmtid': fmtid, 'fmturl': unquote_plus(fmturl) }
1352 - fmt_infomap[int(fmtid)] = unquote_plus(fmturl)
1353 + fmt_infomap[int(fmtid)] = unquote_plus(fmturl)
1354 print "[MyTube] got",sorted(fmt_infomap.iterkeys())
1355 if video_fmt_map and len(video_fmt_map):
1356 print "[MyTube] found best available video format:",video_fmt_map[sorted(video_fmt_map.iterkeys())[0]]['fmtid']
1357 - video_url = video_fmt_map[sorted(video_fmt_map.iterkeys())[0]]['fmturl']
1358 + best_video = video_fmt_map[sorted(video_fmt_map.iterkeys())[0]]
1359 + video_url = "%s&signature=%s" %(best_video['fmturl'].split(';')[0], best_video['fmtsig'])
1360 print "[MyTube] found best available video url:",video_url
1365 def getRelatedVideos(self):
1366 - print "[MyTubeFeedEntry] getResponseVideos()"
1367 + print "[MyTubeFeedEntry] getRelatedVideos()"
1368 for link in self.entry.link:
1369 #print "Related link: ", link.rel.endswith
1370 if link.rel.endswith("video.related"):
1371 @@ -279,13 +309,14 @@ class MyTubePlayerService():
1372 print "[MyTube] MyTubePlayerService - init"
1373 self.feedentries = []
1377 def startService(self):
1378 print "[MyTube] MyTubePlayerService - startService"
1379 - self.yt_service = gdata.youtube.service.YouTubeService()
1380 - self.yt_service.developer_key = 'AI39si4AjyvU8GoJGncYzmqMCwelUnqjEMWTFCcUtK-VUzvWygvwPO-sadNwW5tNj9DDCHju3nnJEPvFy4WZZ6hzFYCx8rJ6Mw'
1381 - self.yt_service.client_id = 'ytapi-dream-MyTubePlayer-i0kqrebg-0'
1382 - self.loggedIn = False
1383 + self.yt_service = gdata.youtube.service.YouTubeService(
1384 + developer_key = 'AI39si4AjyvU8GoJGncYzmqMCwelUnqjEMWTFCcUtK-VUzvWygvwPO-sadNwW5tNj9DDCHju3nnJEPvFy4WZZ6hzFYCx8rJ6Mw',
1385 + client_id = 'ytapi-dream-MyTubePlayer-i0kqrebg-0'
1387 +# self.loggedIn = False
1388 #os.environ['http_proxy'] = 'http://169.229.50.12:3128'
1389 #proxy = os.environ.get('http_proxy')
1390 #print "FOUND ENV PROXY-->",proxy
1391 @@ -295,23 +326,18 @@ class MyTubePlayerService():
1392 def stopService(self):
1393 print "[MyTube] MyTubePlayerService - stopService"
1395 - self.loggedIn = False
1397 - def isLoggedIn(self):
1398 - return self.loggedIn
1400 - def getFeed(self, url):
1401 + def getFeed(self, url, callback = None, errorback = None):
1402 print "[MyTube] MyTubePlayerService - getFeed:",url
1403 self.feedentries = []
1404 - self.feed = self.yt_service.GetYouTubeVideoFeed(url)
1405 - for entry in self.feed.entry:
1406 - MyFeedEntry = MyTubeFeedEntry(self, entry)
1407 - self.feedentries.append(MyFeedEntry)
1409 + queryThread = YoutubeQueryThread(self.yt_service.GetYouTubeVideoFeed, url, self.gotFeed, self.gotFeedError, callback, errorback)
1410 + queryThread.start()
1411 + return queryThread
1413 def search(self, searchTerms, startIndex = 1, maxResults = 25,
1414 orderby = "relevance", racy = "include",
1415 - author = "", lr = "", categories = "", sortOrder = "ascending"):
1416 + author = "", lr = "", categories = "", sortOrder = "ascending",
1417 + callback = None, errorback = None):
1418 print "[MyTube] MyTubePlayerService - search()"
1419 self.feedentries = []
1420 query = gdata.youtube.service.YouTubeVideoQuery()
1421 @@ -325,17 +351,24 @@ class MyTubePlayerService():
1422 query.categories = categories
1423 query.start_index = startIndex
1424 query.max_results = maxResults
1426 - feed = self.yt_service.YouTubeQuery(query)
1429 + queryThread = YoutubeQueryThread(self.yt_service.YouTubeQuery, query, self.gotFeed, self.gotFeedError, callback, errorback)
1430 + queryThread.start()
1431 + return queryThread
1433 + def gotFeed(self, feed, callback):
1434 if feed is not None:
1436 for entry in self.feed.entry:
1437 MyFeedEntry = MyTubeFeedEntry(self, entry)
1438 self.feedentries.append(MyFeedEntry)
1441 + if callback is not None:
1442 + callback(self.feed)
1444 + def gotFeedError(self, exception, errorback):
1445 + if errorback is not None:
1446 + errorback(exception)
1450 return self.feed.title.text
1452 @@ -354,5 +387,38 @@ class MyTubePlayerService():
1457 +class YoutubeQueryThread(Thread):
1458 + def __init__(self, query, param, gotFeed, gotFeedError, callback, errorback):
1459 + Thread.__init__(self)
1460 + self.messagePump = ePythonMessagePump()
1461 + self.messages = ThreadQueue()
1462 + self.gotFeed = gotFeed
1463 + self.gotFeedError = gotFeedError
1464 + self.callback = callback
1465 + self.errorback = errorback
1466 + self.query = query
1467 + self.param = param
1468 + self.canceled = False
1469 + self.messagePump.recv_msg.get().append(self.finished)
1472 + self.canceled = True
1476 + feed = self.query(self.param)
1477 + self.messages.push((True, feed, self.callback))
1478 + self.messagePump.send(0)
1479 + except Exception, ex:
1480 + self.messages.push((False, ex, self.errorback))
1481 + self.messagePump.send(0)
1483 + def finished(self, val):
1484 + if not self.canceled:
1485 + message = self.messages.pop()
1487 + self.gotFeed(message[1], message[2])
1489 + self.gotFeedError(message[1], message[2])
1491 myTubeService = MyTubePlayerService()
1492 diff --git a/mytube/src/ThreadQueue.py b/mytube/src/ThreadQueue.py
1493 new file mode 100644
1494 index 0000000..ddec604
1496 +++ b/mytube/src/ThreadQueue.py
1498 +from threading import Lock
1501 + def __init__(self):
1503 + self.__lock = Lock()
1505 + def push(self, val):
1506 + lock = self.__lock
1508 + self.__list.append(val)
1512 + lock = self.__lock
1514 + ret = self.__list.pop()
1518 diff --git a/mytube/src/__init__.py b/mytube/src/__init__.py
1519 index c8c21ef..b7b3a56 100755
1520 --- a/mytube/src/__init__.py
1521 +++ b/mytube/src/__init__.py
1523 # -*- coding: ISO-8859-1 -*-
1524 from Components.Language import language
1525 from Tools.Directories import resolveFilename, SCOPE_PLUGINS, SCOPE_LANGUAGE
1528 +import os, gettext, hashlib
1529 PluginLanguageDomain = "MyTube"
1530 PluginLanguagePath = "Extensions/MyTube/locale"
1532 @@ -35,7 +34,7 @@ def decrypt_block(src, mod):
1533 if len(src) != 128 and len(src) != 202:
1535 dest = rsa_pub1024(src[:128], mod)
1536 - hash = sha.new(dest[1:107])
1537 + hash = hashlib.sha1(dest[1:107])
1539 hash.update(src[131:192])
1540 result = hash.digest()
1541 diff --git a/mytube/src/plugin.py b/mytube/src/plugin.py
1542 index 93b54c1..84b98c4 100755
1543 --- a/mytube/src/plugin.py
1544 +++ b/mytube/src/plugin.py
1546 -from Plugins.Plugin import PluginDescriptor
1547 -from MyTubeService import GoogleSuggestions, validate_cert, get_rnd
1548 -from MyTubeSearch import ConfigTextWithGoogleSuggestions
1549 -from Tools.BoundFunction import boundFunction
1550 -from Screens.MessageBox import MessageBox
1551 -from Screens.Screen import Screen
1552 -from Screens.ChoiceBox import ChoiceBox
1553 -from Screens.InfoBar import MoviePlayer
1554 -from Screens.VirtualKeyBoard import VirtualKeyBoard
1555 -from Components.ActionMap import ActionMap, NumberActionMap
1556 +from Components.AVSwitch import AVSwitch
1557 +from Components.ActionMap import ActionMap
1558 +from Components.Button import Button
1559 +from Components.ConfigList import ConfigListScreen
1560 from Components.Label import Label
1561 -from Components.ScrollLabel import ScrollLabel
1562 -from Components.ProgressBar import ProgressBar
1563 +from Components.MultiContent import MultiContentEntryText, MultiContentEntryPixmapAlphaTest
1564 from Components.Pixmap import Pixmap
1565 -from Components.Button import Button
1566 +from Components.ProgressBar import ProgressBar
1567 +from Components.ScrollLabel import ScrollLabel
1568 +from Components.ServiceEventTracker import ServiceEventTracker
1569 from Components.Sources.List import List
1570 -from Components.MultiContent import MultiContentEntryText, MultiContentEntryPixmapAlphaTest
1571 -from Components.AVSwitch import AVSwitch
1572 -from Components.ActionMap import HelpableActionMap
1573 -from Components.config import config, Config, ConfigSelection, ConfigSubsection, ConfigText, getConfigListEntry, ConfigYesNo, ConfigIP, ConfigNumber,ConfigLocations
1574 -from Components.config import KEY_DELETE, KEY_BACKSPACE, KEY_LEFT, KEY_RIGHT, KEY_HOME, KEY_END, KEY_TOGGLEOW, KEY_ASCII, KEY_TIMEOUT
1575 -from Components.ConfigList import ConfigListScreen
1576 -from Components.ServiceEventTracker import ServiceEventTracker, InfoBarBase
1577 -from Components.Console import Console
1578 -from Components.Sources.Source import Source
1579 from Components.Task import Task, Job, job_manager
1580 +from Components.config import config, ConfigSelection, ConfigSubsection, ConfigText, ConfigYesNo, getConfigListEntry
1581 +#, ConfigIP, ConfigNumber, ConfigLocations
1582 +from MyTubeSearch import ConfigTextWithGoogleSuggestions, MyTubeSettingsScreen, MyTubeTasksScreen, MyTubeHistoryScreen
1583 +from MyTubeService import validate_cert, get_rnd, myTubeService
1584 +from Plugins.Plugin import PluginDescriptor
1585 +from Screens.ChoiceBox import ChoiceBox
1586 +from Screens.InfoBarGenerics import InfoBarNotifications
1587 +from Screens.MessageBox import MessageBox
1588 +from Screens.Screen import Screen
1589 +from Screens.VirtualKeyBoard import VirtualKeyBoard
1590 +from Tools.BoundFunction import boundFunction
1591 +from Tools.Directories import resolveFilename, SCOPE_HDD, SCOPE_CURRENT_PLUGIN
1592 +from Tools.Downloader import downloadWithProgress
1594 -from threading import Thread
1595 -from threading import Condition
1596 +from __init__ import decrypt_block
1598 -from Tools.Directories import pathExists, fileExists, resolveFilename, SCOPE_PLUGINS, SCOPE_SKIN_IMAGE, SCOPE_HDD, SCOPE_CURRENT_PLUGIN
1599 -from Tools.LoadPixmap import LoadPixmap
1600 -from Tools.Downloader import HTTPProgressDownloader, downloadWithProgress
1601 -from enigma import eTimer, quitMainloop,eListbox,ePoint, RT_HALIGN_LEFT, RT_HALIGN_RIGHT, RT_VALIGN_CENTER, eListboxPythonMultiContent, eListbox, gFont, getDesktop, ePicLoad, eServiceCenter, iServiceInformation, eServiceReference,iSeekableService,iServiceInformation, iPlayableService, iPlayableServicePtr
1602 -from os import path as os_path, system as os_system, unlink, stat, mkdir, popen, makedirs, listdir, access, rename, remove, W_OK, R_OK, F_OK
1603 +from enigma import eTPM, eTimer, ePoint, RT_HALIGN_LEFT, RT_VALIGN_CENTER, gFont, ePicLoad, eServiceReference, iPlayableService
1604 +from os import path as os_path, remove as os_remove
1605 from twisted.web import client
1606 -from twisted.internet import reactor
1607 -from time import time
1609 -from Screens.InfoBarGenerics import InfoBarShowHide, InfoBarSeek, InfoBarNotifications, InfoBarServiceNotifications
1610 -from enigma import eTPM
1611 -from __init__ import bin2long, long2bin, rsa_pub1024, decrypt_block
1615 rootkey = ['\x9f', '|', '\xe4', 'G', '\xc9', '\xb4', '\xf4', '#', '&', '\xce', '\xb3', '\xfe', '\xda', '\xc9', 'U', '`', '\xd8', '\x8c', 's', 'o', '\x90', '\x9b', '\\', 'b', '\xc0', '\x89', '\xd1', '\x8c', '\x9e', 'J', 'T', '\xc5', 'X', '\xa1', '\xb8', '\x13', '5', 'E', '\x02', '\xc9', '\xb2', '\xe6', 't', '\x89', '\xde', '\xcd', '\x9d', '\x11', '\xdd', '\xc7', '\xf4', '\xe4', '\xe4', '\xbc', '\xdb', '\x9c', '\xea', '}', '\xad', '\xda', 't', 'r', '\x9b', '\xdc', '\xbc', '\x18', '3', '\xe7', '\xaf', '|', '\xae', '\x0c', '\xe3', '\xb5', '\x84', '\x8d', '\r', '\x8d', '\x9d', '2', '\xd0', '\xce', '\xd5', 'q', '\t', '\x84', 'c', '\xa8', ')', '\x99', '\xdc', '<', '"', 'x', '\xe8', '\x87', '\x8f', '\x02', ';', 'S', 'm', '\xd5', '\xf0', '\xa3', '_', '\xb7', 'T', '\t', '\xde', '\xa7', '\xf1', '\xc9', '\xae', '\x8a', '\xd7', '\xd2', '\xcf', '\xb2', '.', '\x13', '\xfb', '\xac', 'j', '\xdf', '\xb1', '\x1d', ':', '?']
1617 config.plugins.mytube = ConfigSubsection()
1618 config.plugins.mytube.search = ConfigSubsection()
1621 config.plugins.mytube.search.searchTerm = ConfigTextWithGoogleSuggestions("", False, threaded = True)
1622 config.plugins.mytube.search.orderBy = ConfigSelection(
1624 @@ -152,6 +145,7 @@ config.plugins.mytube.general.clearHistoryOnClose = ConfigYesNo(default = False)
1625 #config.plugins.mytube.general.ProxyIP = ConfigIP(default=[0,0,0,0])
1626 #config.plugins.mytube.general.ProxyPort = ConfigNumber(default=8080)
1629 class downloadJob(Job):
1630 def __init__(self, url, file, title):
1631 Job.__init__(self, title)
1632 @@ -189,8 +183,6 @@ class downloadTask(Task):
1636 -from MyTubeService import myTubeService
1637 -from MyTubeSearch import MyTubeSettingsScreen,MyTubeTasksScreen,MyTubeHistoryScreen
1640 class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1641 @@ -198,7 +190,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1643 #(entry, Title, Description, TubeID, thumbnail, PublishedDate,Views,duration,ratings )
1645 - <screen name="MyTubePlayerMainScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTubePlayerMainScreen..." >
1646 + <screen name="MyTubePlayerMainScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTube - Browser" >
1647 <ePixmap position="0,0" zPosition="-1" size="720,576" pixmap="~/mytubemain_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1648 <widget name="config" zPosition="2" position="60,60" size="600,50" scrollbarMode="showNever" transparent="1" />
1649 <widget source="feedlist" render="Listbox" position="49,110" size="628,385" zPosition="1" scrollbarMode="showOnDemand" transparent="1" backgroundPixmap="~/list_bg.png" selectionPixmap="~/list_sel.png" >
1650 @@ -248,6 +240,8 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1652 self.currentFeedName = None
1654 + self.queryThread = None
1655 + self.queryRunning = False
1657 self.video_playlist = []
1658 self.statuslist = []
1659 @@ -339,6 +333,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1660 "nextBouquet": self.switchToConfigList,
1661 "green": self.keyStdFeed,
1662 "yellow": self.handleHistory,
1663 + "menu": self.handleMenu
1666 self["historyactions"] = ActionMap(["ShortcutActions", "WizardActions", "MediaPlayerActions", "MovieSelectionActions", "HelpActions"],
1667 @@ -385,10 +380,12 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1668 current = self["config"].getCurrent()
1669 if current[1].help_window.instance is not None:
1670 current[1].help_window.instance.hide()
1672 self.statuslist.append(( _("Fetching feed entries"), _("Trying to download the Youtube feed entries. Please wait..." ) ))
1673 self["feedlist"].style = "state"
1674 self['feedlist'].setList(self.statuslist)
1675 - self.Timer.start(200)
1676 + self.Timer.start(200)
1678 def TimerFire(self):
1680 if config.plugins.mytube.general.loadFeedOnOpen.value:
1681 @@ -473,7 +470,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1682 self.switchToConfigList()
1684 def handleMenu(self):
1685 - if self.currList == "configlist":
1686 + if self.currList == "configlist" or self.currList == "status":
1688 (_("MyTube Settings"), "settings"),
1690 @@ -644,6 +641,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1691 config.plugins.mytube.general.history.save()
1692 config.plugins.mytube.general.save()
1693 config.plugins.mytube.save()
1694 + self.cancelThread()
1698 @@ -901,16 +899,8 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1699 self.propagateUpDownNormally = True
1701 def getFeed(self, feedUrl, feedName):
1703 - feed = myTubeService.getFeed(feedUrl)
1704 - except Exception, e:
1706 - print "Error querying feed :",feedName
1708 - self.setState('Error')
1709 - if feed is not None:
1710 - self.ytfeed = feed
1711 - self.buildEntryList()
1712 + self.queryStarted()
1713 + self.queryThread = myTubeService.getFeed(feedUrl, self.gotFeed, self.gotFeedError)
1715 def getNextEntries(self, result):
1717 @@ -943,26 +933,53 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1718 self.searchFeed(searchContext)
1720 def searchFeed(self, searchContext):
1721 - print "[MyTubePlayer] searchFeed"
1722 + print "[MyTubePlayer] searchFeed"
1723 + self.queryStarted()
1724 self.appendEntries = False
1726 - feed = myTubeService.search(searchContext,
1727 + self.queryThread = myTubeService.search(searchContext,
1728 orderby = config.plugins.mytube.search.orderBy.value,
1729 racy = config.plugins.mytube.search.racy.value,
1730 lr = config.plugins.mytube.search.lr.value,
1731 categories = [ config.plugins.mytube.search.categories.value ],
1732 - sortOrder = config.plugins.mytube.search.sortOrder.value)
1733 - except Exception, e:
1735 - print "Error querying search for :",config.plugins.mytube.search.searchTerm.value
1737 - self.setState('Error')
1738 + sortOrder = config.plugins.mytube.search.sortOrder.value,
1739 + callback = self.gotSearchFeed, errorback = self.gotSearchFeedError)
1741 + def queryStarted(self):
1742 + if self.queryRunning:
1743 + self.cancelThread()
1744 + self.queryRunning = True
1746 + def queryFinished(self):
1747 + self.queryRunning = False
1749 + def cancelThread(self):
1750 + print "[MyTubePlayer] cancelThread"
1751 + if self.queryThread is not None:
1752 + self.queryThread.cancel()
1753 + self.queryFinished()
1755 + def gotFeed(self, feed):
1756 + print "[MyTubePlayer] gotFeed"
1757 + self.queryFinished()
1758 if feed is not None:
1760 - if self.FirstRun == True:
1761 - self.FirstRun = False
1762 self.buildEntryList()
1765 + def gotFeedError(self, exception):
1766 + print "[MyTubePlayer] gotFeedError"
1767 + self.queryFinished()
1768 + self.setState('Error')
1770 + def gotSearchFeed(self, feed):
1772 + self.FirstRun = False
1773 + self.gotFeed(feed)
1775 + def gotSearchFeedError(self, exception):
1777 + self.FirstRun = False
1778 + self.gotFeedError(exception)
1780 def buildEntryList(self):
1781 self.mytubeentries = None
1782 self.screenshotList = []
1783 @@ -989,7 +1006,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1784 self["feedlist"].setIndex(0)
1785 self["feedlist"].setList(self.videolist)
1786 self["feedlist"].updateList(self.videolist)
1787 - if self.FirstRun == True:
1788 + if self.FirstRun and not config.plugins.mytube.general.loadFeedOnOpen.value:
1789 self.switchToConfigList()
1791 self.switchToFeedList()
1792 @@ -1157,7 +1174,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1793 if self.Details.has_key(tubeid):
1794 self.Details[tubeid]["thumbnail"] = ptr
1795 if (os_path.exists(thumbnailFile) == True):
1796 - remove(thumbnailFile)
1797 + os_remove(thumbnailFile)
1798 del self.picloads[tubeid]
1800 del self.picloads[tubeid]
1801 @@ -1186,7 +1203,7 @@ class MyTubePlayerMainScreen(Screen, ConfigListScreen):
1803 class MyTubeVideoInfoScreen(Screen):
1805 - <screen name="MyTubeVideoInfoScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTubePlayerMainScreen..." >
1806 + <screen name="MyTubeVideoInfoScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTube - Video Info" >
1807 <ePixmap position="0,0" zPosition="-1" size="720,576" pixmap="~/mytubemain_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1808 <widget name="title" position="60,50" size="600,50" zPosition="5" valign="center" halign="left" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
1809 <widget name="starsbg" pixmap="~/starsbar_empty.png" position="560,220" zPosition="5" size="100,20" transparent="1" alphatest="on" />
1810 @@ -1361,7 +1378,7 @@ class MyTubeVideoInfoScreen(Screen):
1811 self.thumbnails[picindex][3] = ptr
1812 if (os_path.exists(self.thumbnails[picindex][2]) == True):
1813 print "removing", self.thumbnails[picindex][2]
1814 - remove(self.thumbnails[picindex][2])
1815 + os_remove(self.thumbnails[picindex][2])
1816 del self.picloads[picindex]
1817 if len(self.picloads) == 0:
1818 self.timer.startLongTimer(3)
1819 @@ -1400,7 +1417,7 @@ class MyTubeVideoInfoScreen(Screen):
1821 class MyTubeVideoHelpScreen(Screen):
1823 - <screen name="MyTubeVideoHelpScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTubePlayerMainScreen..." >
1824 + <screen name="MyTubeVideoHelpScreen" flags="wfNoBorder" position="0,0" size="720,576" title="MyTube - Help" >
1825 <ePixmap position="0,0" zPosition="-1" size="720,576" pixmap="~/mytubemain_bg.png" alphatest="on" transparent="1" backgroundColor="transparent"/>
1826 <widget name="title" position="60,50" size="600,50" zPosition="5" valign="center" halign="left" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
1827 <widget name="detailtext" position="60,120" size="610,370" zPosition="10" font="Regular;21" transparent="1" halign="left" valign="top"/>
1828 @@ -1561,7 +1578,6 @@ class MyTubePlayer(Screen, InfoBarNotifications):
1829 if self.infoCallback is not None:
1833 def playNextFile(self):
1834 print "playNextFile"
1835 nextservice,error = self.nextCallback()