X-Git-Url: https://gitweb.stoutner.com/?a=blobdiff_plain;ds=sidebyside;f=src%2Fhelpers%2FUserAgentHelper.h;h=5c8286afdedccbf87577b6e309140a081e74f297;hb=cba9a47f00b59f59f76f1b5195086285ca0cdb59;hp=f93696804499f173cf3bfa6c82711a9edb2944c1;hpb=68167c0aba46c4bd4c859b176824873ffd14a3e7;p=PrivacyBrowserPC.git diff --git a/src/helpers/UserAgentHelper.h b/src/helpers/UserAgentHelper.h index f936968..5c8286a 100644 --- a/src/helpers/UserAgentHelper.h +++ b/src/helpers/UserAgentHelper.h @@ -29,7 +29,39 @@ public: // The default constructor. UserAgentHelper(); - // The public functions. - static QString getUserAgent(const QString &userAgentName); + // The public static constants. + static const QString CHROMIUM_LINUX_DATABASE; + static const QString CHROMIUM_LINUX_TRANSLATED; + static const QString CHROMIUM_LINUX_USER_AGENT; + static const QString CHROME_WINDOWS_DATABASE; + static const QString CHROME_WINDOWS_TRANSLATED; + static const QString CHROME_WINDOWS_USER_AGENT; + static const QString EDGE_WINDOWS_DATABASE; + static const QString EDGE_WINDOWS_TRANSLATED; + static const QString EDGE_WINDOWS_USER_AGENT; + static const QString FIREFOX_LINUX_DATABASE; + static const QString FIREFOX_LINUX_TRANSLATED; + static const QString FIREFOX_LINUX_USER_AGENT; + static const QString FIREFOX_WINDOWS_DATABASE; + static const QString FIREFOX_WINDOWS_TRANSLATED; + static const QString FIREFOX_WINDOWS_USER_AGENT; + static const QString PRIVACY_BROWSER_DATABASE; + static const QString PRIVACY_BROWSER_TRANSLATED; + static const QString PRIVACY_BROWSER_USER_AGENT; + static const QString SAFARI_MACOS_DATABASE; + static const QString SAFARI_MACOS_TRANSLATED; + static const QString SAFARI_MACOS_USER_AGENT; + static const QString SYSTEM_DEFAULT_DATABASE; + static const QString SYSTEM_DEFAULT_TRANSLATED; + static const QString WEB_ENGINE_DEFAULT_DATABASE; + static const QString WEB_ENGINE_DEFAULT_TRANSLATED; + + // The public static functions. + static QString getDatabaseUserAgentNameFromTranslatedName(const QString &translatedUserAgentName); + static int getDomainSettingsUserAgentIndex(const QString &userAgentName); + static QString getUserAgentFromDatabaseName(const QString &userAgentDatabaseName); + static QString getUserAgentFromTranslatedName(const QString &userAgentTranslatedName); + static QString getResultingDomainSettingsUserAgent(const QString &rawUserAgent); + static QString getTranslatedUserAgentNameFromDatabaseName(const QString &userAgentName); }; #endif