Index: trunk/src/chrome/browser/ui/ash/launcher/multi_profile_shell_window_launcher_controller.cc |
=================================================================== |
--- trunk/src/chrome/browser/ui/ash/launcher/multi_profile_shell_window_launcher_controller.cc (revision 251093) |
+++ trunk/src/chrome/browser/ui/ash/launcher/multi_profile_shell_window_launcher_controller.cc (working copy) |
@@ -43,18 +43,14 @@ |
for (ShellWindowList::iterator it = shell_window_list_.begin(); |
it != shell_window_list_.end(); ++it) { |
apps::ShellWindow* shell_window = *it; |
- Profile* profile = |
- Profile::FromBrowserContext(shell_window->browser_context()); |
- if (!multi_user_util::IsProfileFromActiveUser(profile) && |
+ if (!multi_user_util::IsProfileFromActiveUser(shell_window->profile()) && |
IsRegisteredApp(shell_window->GetNativeWindow())) |
UnregisterApp(shell_window->GetNativeWindow()); |
} |
for (ShellWindowList::iterator it = shell_window_list_.begin(); |
it != shell_window_list_.end(); ++it) { |
apps::ShellWindow* shell_window = *it; |
- Profile* profile = |
- Profile::FromBrowserContext(shell_window->browser_context()); |
- if (multi_user_util::IsProfileFromActiveUser(profile) && |
+ if (multi_user_util::IsProfileFromActiveUser(shell_window->profile()) && |
!IsRegisteredApp(shell_window->GetNativeWindow())) |
RegisterApp(*it); |
} |
@@ -73,9 +69,7 @@ |
if (!ControlsWindow(shell_window->GetNativeWindow())) |
return; |
shell_window_list_.push_back(shell_window); |
- Profile* profile = |
- Profile::FromBrowserContext(shell_window->browser_context()); |
- if (multi_user_util::IsProfileFromActiveUser(profile)) |
+ if (multi_user_util::IsProfileFromActiveUser(shell_window->profile())) |
RegisterApp(shell_window); |
} |