Commit a0b19528 authored by mtomasz@chromium.org's avatar mtomasz@chromium.org

Fixed full screen magnifier switching in oobe.

Before full screen magnifier was enabled by default, instead of disabled. Also, it didn't listen to state switches. This patch addresses these issues.

BUG=163147


Review URL: https://chromiumcodereview.appspot.com/11412264

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@170956 0039d316-1c4b-4281-b951-d872f2087c98
parent 4561eff4
......@@ -102,15 +102,8 @@ class MagnificationManagerImpl : public MagnificationManager,
}
void UpdateMagnifierStatus() {
UserManager* manager = UserManager::Get();
if (!profile_) {
SetMagnifier(ash::MAGNIFIER_OFF);
} else if (manager && !manager->IsSessionStarted()) {
SetMagnifier(ash::MAGNIFIER_FULL);
} else {
ash::MagnifierType type = GetMagnifierType();
SetMagnifier(type);
}
ash::MagnifierType type = GetMagnifierType();
SetMagnifier(type);
}
virtual void Observe(int type,
......
......@@ -58,14 +58,14 @@ class MagnificationManagerTest : public CrosInProcessBrowserTest {
};
IN_PROC_BROWSER_TEST_F(MagnificationManagerTest, Login) {
// Confirms that magnifier is enabled on the login screen.
CheckCurrentMagnifierType(ash::MAGNIFIER_FULL);
// Confirms that magnifier is disabled on the login screen.
CheckCurrentMagnifierType(ash::MAGNIFIER_OFF);
// Logs in.
UserManager::Get()->UserLoggedIn("owner@invalid.domain", true);
UserManager::Get()->SessionStarted();
// Confirms that magnifier is disabled just after login.
// Confirms that magnifier is still disabled just after login.
CheckCurrentMagnifierType(ash::MAGNIFIER_OFF);
// Enables magnifier.
......
Markdown is supported
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