Add /openurl command (#2926)
Usage: `/openurl <URL>`. Opens the provided URL in the browser. Co-authored-by: Rasmus Karlsson <rasmus.karlsson@pajlada.com>
This commit is contained in:
@@ -84,12 +84,14 @@ bool supportsIncognitoLinks()
|
||||
#endif
|
||||
}
|
||||
|
||||
void openLinkIncognito(const QString &link)
|
||||
bool openLinkIncognito(const QString &link)
|
||||
{
|
||||
#ifdef Q_OS_WIN
|
||||
auto command = getCommand(link);
|
||||
|
||||
QProcess::startDetached(command);
|
||||
return QProcess::startDetached(command);
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@@ -5,6 +5,6 @@
|
||||
namespace chatterino {
|
||||
|
||||
bool supportsIncognitoLinks();
|
||||
void openLinkIncognito(const QString &link);
|
||||
bool openLinkIncognito(const QString &link);
|
||||
|
||||
} // namespace chatterino
|
||||
|
||||
Reference in New Issue
Block a user