From ae8f425e78bd6935f87089d54373d841ec097e4b Mon Sep 17 00:00:00 2001 From: gounux Date: Sat, 13 Apr 2024 20:26:09 +0200 Subject: [PATCH] Fix open url calls --- qtribu/gui/dlg_contents.py | 2 +- qtribu/gui/dlg_settings.py | 4 ++-- qtribu/gui/form_rdp_news.py | 3 ++- qtribu/plugin_main.py | 11 +++++++---- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/qtribu/gui/dlg_contents.py b/qtribu/gui/dlg_contents.py index a8d07421..9a15583c 100644 --- a/qtribu/gui/dlg_contents.py +++ b/qtribu/gui/dlg_contents.py @@ -71,7 +71,7 @@ def submit_news(self) -> None: self.form_rdp_news.show() def donate(self) -> None: - self._open_url_in_browser("https://fr.tipeee.com/geotribu") + open_url_in_browser("https://geotribu.fr/team/sponsoring/") def refresh_list(self, expand_all: bool = False) -> None: # fetch last RSS items using JSONFeed diff --git a/qtribu/gui/dlg_settings.py b/qtribu/gui/dlg_settings.py index b3df9b60..be572971 100644 --- a/qtribu/gui/dlg_settings.py +++ b/qtribu/gui/dlg_settings.py @@ -61,13 +61,13 @@ def __init__(self, parent=None): # customization self.btn_help.setIcon(QIcon(QgsApplication.iconPath("mActionHelpContents.svg"))) - self.btn_help.pressed.connect(partial(open_url_in_browser(__uri_homepage__))) + self.btn_help.pressed.connect(partial(open_url_in_browser, __uri_homepage__)) self.btn_report.setIcon( QIcon(QgsApplication.iconPath("console/iconSyntaxErrorConsole.svg")) ) self.btn_report.pressed.connect( - partial(open_url_in_browser(f"{__uri_tracker__}new/choose")) + partial(open_url_in_browser, f"{__uri_tracker__}new/choose") ) self.btn_reset_read_history.setIcon( diff --git a/qtribu/gui/form_rdp_news.py b/qtribu/gui/form_rdp_news.py index 7828347c..a38f8e0d 100644 --- a/qtribu/gui/form_rdp_news.py +++ b/qtribu/gui/form_rdp_news.py @@ -78,7 +78,8 @@ def __init__(self, parent=None): # connect help button self.btn_box.helpRequested.connect( partial( - open_url_in_browser("https://contribuer.geotribu.fr/rdp/add_news/"), + open_url_in_browser, + "https://contribuer.geotribu.fr/rdp/add_news/", ) ) diff --git a/qtribu/plugin_main.py b/qtribu/plugin_main.py index e41fe390..e415a1c2 100644 --- a/qtribu/plugin_main.py +++ b/qtribu/plugin_main.py @@ -112,7 +112,7 @@ def initGui(self): self.iface.mainWindow(), ) self.action_help.triggered.connect( - partial(open_url_in_browser(__uri_homepage__)) + partial(open_url_in_browser, __uri_homepage__) ) self.action_settings = QAction( @@ -143,7 +143,8 @@ def initGui(self): ) self.action_geotribu.triggered.connect( partial( - open_url_in_browser("https://geotribu.fr"), + open_url_in_browser, + "https://geotribu.fr", ) ) @@ -153,7 +154,8 @@ def initGui(self): ) self.action_georezo.triggered.connect( partial( - open_url_in_browser("https://georezo.net/forum/viewforum.php?id=55"), + open_url_in_browser, + "https://georezo.net/forum/viewforum.php?id=55", ) ) self.action_osgeofr = QAction( @@ -162,7 +164,8 @@ def initGui(self): ) self.action_osgeofr.triggered.connect( partial( - open_url_in_browser("https://www.osgeo.fr/"), + open_url_in_browser, + "https://www.osgeo.fr/", ) ) self.iface.helpMenu().addAction(self.action_georezo)