fix search plugin
This commit is contained in:
parent
725ca07a25
commit
da24fafa85
|
@ -116,6 +116,7 @@ class plugin_Search:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def torrent_search(self, widget=None):
|
def torrent_search(self, widget=None):
|
||||||
|
import dcommon
|
||||||
print "Searching with engine", self.se
|
print "Searching with engine", self.se
|
||||||
url = self.engines.get(self.se)
|
url = self.engines.get(self.se)
|
||||||
entry = self.search_entry.get_text()
|
entry = self.search_entry.get_text()
|
||||||
|
@ -127,6 +128,7 @@ class plugin_Search:
|
||||||
url = url.replace('${query}', entry)
|
url = url.replace('${query}', entry)
|
||||||
print 'URL =', url
|
print 'URL =', url
|
||||||
print 'Entry =', entry
|
print 'Entry =', entry
|
||||||
|
dcommon.open_url_in_browser(url)
|
||||||
|
|
||||||
def populate_search_menu(self):
|
def populate_search_menu(self):
|
||||||
import gtk
|
import gtk
|
||||||
|
|
|
@ -155,7 +155,7 @@ def get_glade_file(fname):
|
||||||
def get_pixmap(fname):
|
def get_pixmap(fname):
|
||||||
return PIXMAP_DIR + "/" + fname
|
return PIXMAP_DIR + "/" + fname
|
||||||
|
|
||||||
def open_url_in_browser(dialog, link):
|
def open_url_in_browser(link):
|
||||||
try:
|
try:
|
||||||
webbrowser.open(link)
|
webbrowser.open(link)
|
||||||
except webbrowser.Error:
|
except webbrowser.Error:
|
||||||
|
|
Loading…
Reference in New Issue