diff --git a/Core.py b/Core.py index a7c2a68..6184937 100644 --- a/Core.py +++ b/Core.py @@ -1702,12 +1702,17 @@ class Core: defaultKeyword = params.get('url') showKey=params.get('showKey') + external = unquote(params.get("external"), None) + if external and not params.get('from_searcher'): + searcher = '[%s] ' % str(external) + else: + searcher = '' if showKey == "true" or defaultKeyword == '' or not defaultKeyword: if not defaultKeyword: defaultKeyword = '' defaultKeyword=unquote(defaultKeyword) - keyboard = xbmc.Keyboard(defaultKeyword, self.localize('Search Phrase') + ':') + keyboard = xbmc.Keyboard(defaultKeyword, '%s%s:' % (searcher, self.localize('Search Phrase'))) keyboard.doModal() query = keyboard.getText() if not query: diff --git a/SearcherABC.py b/SearcherABC.py index 22807cd..4b138dc 100644 --- a/SearcherABC.py +++ b/SearcherABC.py @@ -154,11 +154,10 @@ class SearcherABC: return response def askCaptcha(self, url): - temp_dir = tempfile.gettempdir() + temp_dir = self.tempdir() if isinstance(temp_dir, list): temp_dir = temp_dir[0] urllib.URLopener().retrieve(url, temp_dir + '/captcha.png') window = xbmcgui.Window(xbmcgui.getCurrentWindowId()) - temp_dir = tempfile.gettempdir() if isinstance(temp_dir, list): temp_dir = temp_dir[0] image = xbmcgui.ControlImage(460, 20, 360, 160, temp_dir + '/captcha.png') window.addControl(image)