Commit dd5e95bc authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇
Browse files

[Settings] Add browser icon name

Eventually to be used from DBus runners
parent 739a8ae0
......@@ -51,28 +51,32 @@ const QMap<Settings::Environment, EnvironmentDescription> Settings::environmentD
QStringLiteral("Google Chrome"),
QStringLiteral("google-chrome"),
QStringLiteral("google.com"),
QStringLiteral("Google")
QStringLiteral("Google"),
QStringLiteral("google-chrome")
} },
{Settings::Environment::Chromium, {
QStringLiteral("chromium-browser"),
QStringLiteral("Chromium"),
QStringLiteral("chromium-browser"),
QStringLiteral("google.com"),
QStringLiteral("Google")
QStringLiteral("Google"),
QStringLiteral("chromium-browser")
} },
{Settings::Environment::Firefox, {
QStringLiteral("firefox"),
QStringLiteral("Mozilla Firefox"),
QStringLiteral("firefox"),
QStringLiteral("mozilla.org"),
QStringLiteral("Mozilla")
QStringLiteral("Mozilla"),
QStringLiteral("firefox")
} },
{Settings::Environment::Opera, {
QStringLiteral("opera"),
QStringLiteral("Opera"),
QStringLiteral("opera"),
QStringLiteral("opera.com"),
QStringLiteral("Opera")
QStringLiteral("Opera"),
QStringLiteral("opera")
} },
{Settings::Environment::Vivaldi, {
QStringLiteral("vivaldi"),
......@@ -80,14 +84,16 @@ const QMap<Settings::Environment, EnvironmentDescription> Settings::environmentD
// This is what the official package on their website uses
QStringLiteral("vivaldi-stable"),
QStringLiteral("vivaldi.com"),
QStringLiteral("Vivaldi")
QStringLiteral("Vivaldi"),
QStringLiteral("vivaldi")
} },
{Settings::Environment::Brave, {
QStringLiteral("Brave"),
QStringLiteral("Brave"),
QStringLiteral("brave-browser"),
QStringLiteral("brave.com"),
QStringLiteral("Brave")
QStringLiteral("Brave"),
QStringLiteral("brave")
} }
};
......@@ -197,6 +203,11 @@ QString Settings::environmentString() const
return Settings::environmentNames.value(m_environment);
}
EnvironmentDescription Settings::environmentDescription() const
{
return m_currentEnvironment;
}
bool Settings::pluginEnabled(const QString &subsystem) const
{
return settingsForPlugin(subsystem).value(QStringLiteral("enabled")).toBool();
......
......@@ -33,6 +33,7 @@ struct EnvironmentDescription {
QString desktopFileName;
QString organizationDomain;
QString organizationName;
QString iconName;
};
/*
......@@ -65,7 +66,7 @@ public:
Environment environment() const;
QString environmentString() const; // dbus
// TODO should we have additional getters like browserName(), browserDesktopEntry(), etc?
EnvironmentDescription environmentDescription() const;
bool pluginEnabled(const QString &subsystem) const;
QJsonObject settingsForPlugin(const QString &subsystem) const;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment