From 5266cd2b0590bc3322e90ff85e393e445297b35e Mon Sep 17 00:00:00 2001 From: eladeyal Date: Mon, 22 Apr 2019 21:26:20 +0300 Subject: [PATCH] fix #404 --- gooey/gui/components/console.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gooey/gui/components/console.py b/gooey/gui/components/console.py index 66e3e45..09de4c8 100644 --- a/gooey/gui/components/console.py +++ b/gooey/gui/components/console.py @@ -36,10 +36,12 @@ class Console(wx.Panel): self.layoutComponent() self.Layout() - self.Bind(wx.EVT_TEXT_URL, self.followUrl, self.textbox) + self.Bind(wx.EVT_TEXT_URL, self.evtUrl, self.textbox) - def followUrl(self, event): - webbrowser.open(self.textbox.GetValue()[event.URLStart:event.URLEnd]) + def evtUrl(self, event): + if event.MouseEvent.LeftUp(): + webbrowser.open(self.textbox.GetValue()[event.URLStart:event.URLEnd]) + event.Skip() def getFontStyle(self):