From 92be69aef53b5e899b4ecffcf377b9b315559db8 Mon Sep 17 00:00:00 2001 From: Philipp Wolfer Date: Thu, 15 Aug 2019 23:24:46 +0200 Subject: [PATCH] PICARD-1575: Allow dragging images from Bing image search result --- picard/ui/coverartbox.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/picard/ui/coverartbox.py b/picard/ui/coverartbox.py index f5e025d10..0a28342ae 100644 --- a/picard/ui/coverartbox.py +++ b/picard/ui/coverartbox.py @@ -409,6 +409,10 @@ class CoverArtBox(QtWidgets.QGroupBox): # This may be a google images result, try to get the URL which is encoded in the query url = QtCore.QUrl(url_query.queryItemValue("imgurl", QtCore.QUrl.FullyDecoded)) self.fetch_remote_image(url) + elif url_query.hasQueryItem("mediaurl"): + # Bing uses mediaurl + url = QtCore.QUrl(url_query.queryItemValue("mediaurl", QtCore.QUrl.FullyDecoded)) + self.fetch_remote_image(url) else: log.warning("Can't load remote image with MIME-Type %s", mime) if fallback_data: