From ae6c45f90ed337c3b98ca581443e96dd230ee4bb Mon Sep 17 00:00:00 2001 From: gixxpunk Date: Mon, 29 May 2017 17:15:38 +0200 Subject: [PATCH] imdb poster: if possible load bigger image Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/090ccc42510831aec1f291accc9091e096cfcf2e Author: gixxpunk Date: 2017-05-29 (Mon, 29 May 2017) Origin message was: ------------------ - imdb poster: if possible load bigger image --- src/gui/imdb.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/gui/imdb.cpp b/src/gui/imdb.cpp index 8ecbbf670..606ffefe8 100644 --- a/src/gui/imdb.cpp +++ b/src/gui/imdb.cpp @@ -323,6 +323,16 @@ int CIMDB::getIMDb(const std::string& epgTitle) //download Poster if(m["Poster"] != "N/A") { + // if possible load bigger image + std::string origURL ("300"); + std::string replURL ("600"); + + if (m["Poster"].compare(m["Poster"].size()-7,3,origURL) == 0){ + //std::cout << "########## " << m["Poster"] << " contains " << origURL << '\n'; + m["Poster"].replace(m["Poster"].size()-7,3,replURL); + //std::cout << "########## New string: " << m["Poster"] << '\n'; + } + if (httpTool.downloadFile(m["Poster"], posterfile.c_str())) return 2; else {