Don't declare IsDesktopEnvironmentUnity on non-Linux
This commit is contained in:
parent
1cc5492784
commit
26f5390ac0
1 changed files with 2 additions and 4 deletions
|
@ -15,16 +15,14 @@
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
bool IsDesktopEnvironmentUnity() {
|
|
||||||
#if defined(OS_LINUX)
|
#if defined(OS_LINUX)
|
||||||
|
bool IsDesktopEnvironmentUnity() {
|
||||||
std::unique_ptr<base::Environment> env(base::Environment::Create());
|
std::unique_ptr<base::Environment> env(base::Environment::Create());
|
||||||
base::nix::DesktopEnvironment desktop_env =
|
base::nix::DesktopEnvironment desktop_env =
|
||||||
base::nix::GetDesktopEnvironment(env.get());
|
base::nix::GetDesktopEnvironment(env.get());
|
||||||
return desktop_env == base::nix::DESKTOP_ENVIRONMENT_UNITY;
|
return desktop_env == base::nix::DESKTOP_ENVIRONMENT_UNITY;
|
||||||
#else
|
|
||||||
return false;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue