mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-30 17:01:08 +02:00
gui/moviebrowser, system/ytparser: Google dropped most YouTube feeds. Limit code to what's left.
Origin commit data
------------------
Commit: eda90ac834
Author: martii <m4rtii@gmx.de>
Date: 2013-11-23 (Sat, 23 Nov 2013)
This commit is contained in:
@@ -1438,13 +1438,9 @@ moviebrowser.yt_error Fehler beim laden des Youtube Feed
|
||||
moviebrowser.yt_history Frühere Suchen
|
||||
moviebrowser.yt_max_history Max. Anzahl früherer Suchen
|
||||
moviebrowser.yt_max_results Max. Anzahl der zu holenden Feeds
|
||||
moviebrowser.yt_most_discussed Am meisten diskutiert
|
||||
moviebrowser.yt_most_popular Beliebteste Videos
|
||||
moviebrowser.yt_most_resent Unbeliebteste Videos
|
||||
moviebrowser.yt_most_responded Feeds mit den meisten Reaktionen
|
||||
moviebrowser.yt_most_shared Am häufigsten wiedergegebe Videos
|
||||
moviebrowser.yt_most_popular Beliebteste Videos heute
|
||||
moviebrowser.yt_most_popular_all_time Beliebteste Videos
|
||||
moviebrowser.yt_next_results Nächste Ergebnisse
|
||||
moviebrowser.yt_on_the_web Trendvideos
|
||||
moviebrowser.yt_orderby Sortierung nach
|
||||
moviebrowser.yt_orderby.published Veröffentlichungszeitpunkt
|
||||
moviebrowser.yt_orderby.rating Bewertung
|
||||
@@ -1456,8 +1452,6 @@ moviebrowser.yt_recently_featured Vor kurzem empfohlen
|
||||
moviebrowser.yt_region Region
|
||||
moviebrowser.yt_related Passende Videos
|
||||
moviebrowser.yt_search Suche nach Stichwort
|
||||
moviebrowser.yt_top_favorites Top Favoriten
|
||||
moviebrowser.yt_top_rated Am besten bewertet
|
||||
movieplayer.bookmark Bookmarks
|
||||
movieplayer.bookmarkname Bookmark Name
|
||||
movieplayer.bookmarkname_hint1 Geben Sie den Namen für das neue Lesezeichen ein
|
||||
|
@@ -1438,13 +1438,9 @@ moviebrowser.yt_error Failed to load youtube feed
|
||||
moviebrowser.yt_history Search history
|
||||
moviebrowser.yt_max_history Max search history size
|
||||
moviebrowser.yt_max_results Max results to fetch
|
||||
moviebrowser.yt_most_discussed Most discussed
|
||||
moviebrowser.yt_most_popular Most popular
|
||||
moviebrowser.yt_most_resent Most resent
|
||||
moviebrowser.yt_most_responded Most responded
|
||||
moviebrowser.yt_most_shared Most shared
|
||||
moviebrowser.yt_most_popular Most popular today
|
||||
moviebrowser.yt_most_popular_all_time Most popular
|
||||
moviebrowser.yt_next_results Next results
|
||||
moviebrowser.yt_on_the_web Trending videos
|
||||
moviebrowser.yt_orderby Order by
|
||||
moviebrowser.yt_orderby.published publishing date
|
||||
moviebrowser.yt_orderby.rating rating
|
||||
@@ -1456,8 +1452,6 @@ moviebrowser.yt_recently_featured Recently featured
|
||||
moviebrowser.yt_region Region
|
||||
moviebrowser.yt_related Related videos
|
||||
moviebrowser.yt_search Search keyword
|
||||
moviebrowser.yt_top_favorites Top favorites
|
||||
moviebrowser.yt_top_rated Top rated
|
||||
movieplayer.bookmark Bookmarks
|
||||
movieplayer.bookmarkname Bookmarkname
|
||||
movieplayer.bookmarkname_hint1 Enter a name for your new bookmark
|
||||
|
@@ -3623,15 +3623,8 @@ void CMovieBrowser::loadYTitles(int mode, std::string search, std::string id)
|
||||
|
||||
const CMenuOptionChooser::keyval YT_FEED_OPTIONS[] =
|
||||
{
|
||||
{ cYTFeedParser::TOP_RATED, LOCALE_MOVIEBROWSER_YT_TOP_RATED },
|
||||
{ cYTFeedParser::TOP_FAVORITES, LOCALE_MOVIEBROWSER_YT_TOP_FAVORITES },
|
||||
{ cYTFeedParser::MOST_SHARED, LOCALE_MOVIEBROWSER_YT_MOST_SHARED },
|
||||
{ cYTFeedParser::MOST_POPULAR, LOCALE_MOVIEBROWSER_YT_MOST_POPULAR },
|
||||
{ cYTFeedParser::MOST_RESENT, LOCALE_MOVIEBROWSER_YT_MOST_RESENT },
|
||||
{ cYTFeedParser::MOST_DISCUSSED, LOCALE_MOVIEBROWSER_YT_MOST_DISCUSSED },
|
||||
{ cYTFeedParser::MOST_RESPONDED, LOCALE_MOVIEBROWSER_YT_MOST_RESPONDED },
|
||||
{ cYTFeedParser::RECENTLY_FEATURED, LOCALE_MOVIEBROWSER_YT_RECENTLY_FEATURED },
|
||||
{ cYTFeedParser::ON_THE_WEB, LOCALE_MOVIEBROWSER_YT_ON_THE_WEB },
|
||||
{ cYTFeedParser::MOST_POPULAR_ALL_TIME, LOCALE_MOVIEBROWSER_YT_MOST_POPULAR_ALL_TIME },
|
||||
{ cYTFeedParser::MOST_POPULAR, LOCALE_MOVIEBROWSER_YT_MOST_POPULAR }
|
||||
};
|
||||
|
||||
#define YT_FEED_OPTION_COUNT (sizeof(YT_FEED_OPTIONS)/sizeof(CMenuOptionChooser::keyval))
|
||||
@@ -3641,7 +3634,7 @@ const CMenuOptionChooser::keyval YT_ORDERBY_OPTIONS[] =
|
||||
{ cYTFeedParser::ORDERBY_PUBLISHED, LOCALE_MOVIEBROWSER_YT_ORDERBY_PUBLISHED },
|
||||
{ cYTFeedParser::ORDERBY_RELEVANCE, LOCALE_MOVIEBROWSER_YT_ORDERBY_RELEVANCE },
|
||||
{ cYTFeedParser::ORDERBY_VIEWCOUNT, LOCALE_MOVIEBROWSER_YT_ORDERBY_VIEWCOUNT },
|
||||
{ cYTFeedParser::ORDERBY_RATING, LOCALE_MOVIEBROWSER_YT_ORDERBY_RATING },
|
||||
{ cYTFeedParser::ORDERBY_RATING, LOCALE_MOVIEBROWSER_YT_ORDERBY_RATING }
|
||||
};
|
||||
|
||||
#define YT_ORDERBY_OPTION_COUNT (sizeof(YT_ORDERBY_OPTIONS)/sizeof(CMenuOptionChooser::keyval))
|
||||
|
@@ -1465,13 +1465,9 @@ typedef enum
|
||||
LOCALE_MOVIEBROWSER_YT_HISTORY,
|
||||
LOCALE_MOVIEBROWSER_YT_MAX_HISTORY,
|
||||
LOCALE_MOVIEBROWSER_YT_MAX_RESULTS,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_DISCUSSED,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_POPULAR,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_RESENT,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_RESPONDED,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_SHARED,
|
||||
LOCALE_MOVIEBROWSER_YT_MOST_POPULAR_ALL_TIME,
|
||||
LOCALE_MOVIEBROWSER_YT_NEXT_RESULTS,
|
||||
LOCALE_MOVIEBROWSER_YT_ON_THE_WEB,
|
||||
LOCALE_MOVIEBROWSER_YT_ORDERBY,
|
||||
LOCALE_MOVIEBROWSER_YT_ORDERBY_PUBLISHED,
|
||||
LOCALE_MOVIEBROWSER_YT_ORDERBY_RATING,
|
||||
@@ -1483,8 +1479,6 @@ typedef enum
|
||||
LOCALE_MOVIEBROWSER_YT_REGION,
|
||||
LOCALE_MOVIEBROWSER_YT_RELATED,
|
||||
LOCALE_MOVIEBROWSER_YT_SEARCH,
|
||||
LOCALE_MOVIEBROWSER_YT_TOP_FAVORITES,
|
||||
LOCALE_MOVIEBROWSER_YT_TOP_RATED,
|
||||
LOCALE_MOVIEPLAYER_BOOKMARK,
|
||||
LOCALE_MOVIEPLAYER_BOOKMARKNAME,
|
||||
LOCALE_MOVIEPLAYER_BOOKMARKNAME_HINT1,
|
||||
|
@@ -1465,13 +1465,9 @@ const char * locale_real_names[] =
|
||||
"moviebrowser.yt_history",
|
||||
"moviebrowser.yt_max_history",
|
||||
"moviebrowser.yt_max_results",
|
||||
"moviebrowser.yt_most_discussed",
|
||||
"moviebrowser.yt_most_popular",
|
||||
"moviebrowser.yt_most_resent",
|
||||
"moviebrowser.yt_most_responded",
|
||||
"moviebrowser.yt_most_shared",
|
||||
"moviebrowser.yt_most_popular_all_time",
|
||||
"moviebrowser.yt_next_results",
|
||||
"moviebrowser.yt_on_the_web",
|
||||
"moviebrowser.yt_orderby",
|
||||
"moviebrowser.yt_orderby.published",
|
||||
"moviebrowser.yt_orderby.rating",
|
||||
@@ -1483,8 +1479,6 @@ const char * locale_real_names[] =
|
||||
"moviebrowser.yt_region",
|
||||
"moviebrowser.yt_related",
|
||||
"moviebrowser.yt_search",
|
||||
"moviebrowser.yt_top_favorites",
|
||||
"moviebrowser.yt_top_rated",
|
||||
"movieplayer.bookmark",
|
||||
"movieplayer.bookmarkname",
|
||||
"movieplayer.bookmarkname_hint1",
|
||||
|
@@ -476,36 +476,15 @@ bool cYTFeedParser::ParseFeed(yt_feed_mode_t mode, std::string search, std::stri
|
||||
{
|
||||
std::string url = "http://gdata.youtube.com/feeds/api/standardfeeds/";
|
||||
bool append_res = true;
|
||||
std::string trailer;
|
||||
if (mode < FEED_LAST) {
|
||||
switch(mode) {
|
||||
case TOP_RATED:
|
||||
curfeed = "top_rated";
|
||||
break;
|
||||
case TOP_FAVORITES:
|
||||
curfeed = "top_favorites";
|
||||
break;
|
||||
case MOST_SHARED:
|
||||
curfeed = "most_shared";
|
||||
break;
|
||||
case MOST_POPULAR:
|
||||
default:
|
||||
trailer = "&time=today";
|
||||
case MOST_POPULAR_ALL_TIME:
|
||||
curfeed = "most_popular";
|
||||
break;
|
||||
case MOST_RESENT:
|
||||
curfeed = "most_recent";
|
||||
break;
|
||||
case MOST_DISCUSSED:
|
||||
curfeed = "most_discussed";
|
||||
break;
|
||||
case MOST_RESPONDED:
|
||||
curfeed = "most_responded";
|
||||
break;
|
||||
case RECENTLY_FEATURED:
|
||||
curfeed = "recently_featured";
|
||||
break;
|
||||
case ON_THE_WEB:
|
||||
curfeed = "on_the_web";
|
||||
break;
|
||||
}
|
||||
if (!region.empty()) {
|
||||
url += region;
|
||||
@@ -552,6 +531,8 @@ bool cYTFeedParser::ParseFeed(yt_feed_mode_t mode, std::string search, std::stri
|
||||
url+= res;
|
||||
}
|
||||
|
||||
url += trailer;
|
||||
|
||||
return ParseFeed(url);
|
||||
}
|
||||
|
||||
|
@@ -113,15 +113,8 @@ class cYTFeedParser
|
||||
public:
|
||||
enum yt_feed_mode_t
|
||||
{
|
||||
TOP_RATED,
|
||||
TOP_FAVORITES,
|
||||
MOST_SHARED,
|
||||
MOST_POPULAR,
|
||||
MOST_RESENT,
|
||||
MOST_DISCUSSED,
|
||||
MOST_RESPONDED,
|
||||
RECENTLY_FEATURED,
|
||||
ON_THE_WEB,
|
||||
MOST_POPULAR_ALL_TIME,
|
||||
FEED_LAST,
|
||||
NEXT,
|
||||
PREV,
|
||||
|
Reference in New Issue
Block a user