diff options
author | bartfab@chromium.org <bartfab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-11 10:53:44 +0000 |
---|---|---|
committer | bartfab@chromium.org <bartfab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-11 10:53:44 +0000 |
commit | 60b9bc70d2e35e217bc1bbd08138ea109b24bc64 (patch) | |
tree | c696fddfab682e84d2ade326a8cb1171076d7e7a /ash | |
parent | 5872f7368130950c962ac478703b2ab1815a704c (diff) | |
download | chromium_src-60b9bc70d2e35e217bc1bbd08138ea109b24bc64.zip chromium_src-60b9bc70d2e35e217bc1bbd08138ea109b24bc64.tar.gz chromium_src-60b9bc70d2e35e217bc1bbd08138ea109b24bc64.tar.bz2 |
Do not show "This device is owned by..." menu entry for Public Accounts
For Public Accounts, enterprise ownership is indicated in the system
tray menu's user details section. A separate menu entry informing the
user that this device is enterprise-owned is not necessary.
BUG=chromium-os:35755
TEST=Manual
Review URL: https://chromiumcodereview.appspot.com/11819063
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@176307 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash')
-rw-r--r-- | ash/system/chromeos/enterprise/tray_enterprise.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/ash/system/chromeos/enterprise/tray_enterprise.cc b/ash/system/chromeos/enterprise/tray_enterprise.cc index 592eb64..9c0e6dc 100644 --- a/ash/system/chromeos/enterprise/tray_enterprise.cc +++ b/ash/system/chromeos/enterprise/tray_enterprise.cc @@ -7,6 +7,8 @@ #include "ash/system/tray/system_tray_notifier.h" #include "ash/system/tray/tray_constants.h" #include "ash/system/tray/tray_views.h" +#include "ash/system/user/login_status.h" +#include "base/logging.h" #include "grit/ash_resources.h" #include "ui/base/resource/resource_bundle.h" #include "ui/gfx/font.h" @@ -88,7 +90,12 @@ void TrayEnterprise::UpdateEnterpriseMessage() { default_view_->SetMessage(message); } -views::View* TrayEnterprise::CreateDefaultView(user::LoginStatus /*status*/) { +views::View* TrayEnterprise::CreateDefaultView(user::LoginStatus status) { + CHECK(default_view_ == NULL); + // For public accounts, enterprise ownership is indicated in the user details + // instead. + if (status == ash::user::LOGGED_IN_PUBLIC) + return NULL; default_view_ = new EnterpriseDefaultView(this); UpdateEnterpriseMessage(); return default_view_; |