From 2ec3ff157bc5213e5eede61750f1c2c1cce185a6 Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Thu, 22 Dec 2011 21:17:02 +0000 Subject: [PATCH] Kill AegisubApp::OpenURL. It makes no sense for the top level application object to be doing this and it doesn't even save any code. Originally committed to SVN as r6048. --- aegisub/src/command/help.cpp | 8 ++++---- aegisub/src/main.cpp | 10 ---------- aegisub/src/main.h | 1 - 3 files changed, 4 insertions(+), 15 deletions(-) diff --git a/aegisub/src/command/help.cpp b/aegisub/src/command/help.cpp index eae877b6d..11297cae3 100644 --- a/aegisub/src/command/help.cpp +++ b/aegisub/src/command/help.cpp @@ -72,7 +72,7 @@ struct help_bugs : public Command { throw c->parent; } } - AegisubApp::OpenURL("http://devel.aegisub.org/"); + wxLaunchDefaultBrowser("http://devel.aegisub.org/", wxBROWSER_NEW_WINDOW); } }; @@ -114,7 +114,7 @@ struct help_forums : public Command { STR_HELP("Visit Aegisub's forums.") void operator()(agi::Context *) { - AegisubApp::OpenURL("http://forum.aegisub.org/"); + wxLaunchDefaultBrowser("http://forum.aegisub.org/", wxBROWSER_NEW_WINDOW); } }; @@ -127,7 +127,7 @@ struct help_irc : public Command { STR_HELP("Visit Aegisub's official IRC channel.") void operator()(agi::Context *) { - AegisubApp::OpenURL("irc://irc.rizon.net/aegisub"); + wxLaunchDefaultBrowser("irc://irc.rizon.net/aegisub", wxBROWSER_NEW_WINDOW); } }; @@ -151,7 +151,7 @@ struct help_website : public Command { STR_HELP("Visit Aegisub's official website.") void operator()(agi::Context *) { - AegisubApp::OpenURL("http://www.aegisub.org/"); + wxLaunchDefaultBrowser("http://www.aegisub.org/", wxBROWSER_NEW_WINDOW); } }; } diff --git a/aegisub/src/main.cpp b/aegisub/src/main.cpp index 8743892ad..2b77042e8 100644 --- a/aegisub/src/main.cpp +++ b/aegisub/src/main.cpp @@ -546,16 +546,6 @@ int AegisubApp::OnRun() { return 1; } - - -/// @brief Open URL -/// @param url -/// -void AegisubApp::OpenURL(wxString url) { - wxLaunchDefaultBrowser(url, wxBROWSER_NEW_WINDOW); -} - - //////////////// // Apple events #ifdef __WXMAC__ diff --git a/aegisub/src/main.h b/aegisub/src/main.h index 20f5c53e1..9e9cd0776 100644 --- a/aegisub/src/main.h +++ b/aegisub/src/main.h @@ -121,7 +121,6 @@ public: /// @return /// static AegisubApp* Get() { return (AegisubApp*) wxTheApp; } - static void OpenURL(wxString url); bool OnInit(); int OnExit();