diff options
author | asvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-13 20:26:47 +0000 |
---|---|---|
committer | asvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-13 20:26:47 +0000 |
commit | a5fc73eec17220fb061c6dbbcc36846f386d9bcb (patch) | |
tree | c4de5ff6b243680d8514a6337a0deaebc379e960 /apps/app_shim | |
parent | 0b4731f8b49724c2f389921c4faae26f352f180c (diff) | |
download | chromium_src-a5fc73eec17220fb061c6dbbcc36846f386d9bcb.zip chromium_src-a5fc73eec17220fb061c6dbbcc36846f386d9bcb.tar.gz chromium_src-a5fc73eec17220fb061c6dbbcc36846f386d9bcb.tar.bz2 |
Revert 251094 "Revert 250826 "Remove Profile dependency from app..."
Speculative re-land. Sync tests are passing now, but we're not sure
which revert fixed them. Let's see if this makes the tree red again
or not.
> Revert 250826 "Remove Profile dependency from apps::ShellWindow"
>
> Speculative revert for failures:
>
> http://build.chromium.org/p/chromium.win/builders/Win7%20Sync%20x64/builds/11201
>
> > Remove Profile dependency from apps::ShellWindow
> >
> > Part of the effort to remove src/chrome dependencies from src/{apps, extensions}
> >
> > BUG=341690
> > TBR=tapted@chromium.org,stevenjb@chromium.org
> >
> > Review URL: https://codereview.chromium.org/157813007
>
> TBR=rockot@chromium.org
>
> Review URL: https://codereview.chromium.org/163913004
TBR=asvitkine@chromium.org
Review URL: https://codereview.chromium.org/164613002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@251112 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'apps/app_shim')
-rw-r--r-- | apps/app_shim/app_shim_handler_mac.h | 2 | ||||
-rw-r--r-- | apps/app_shim/extension_app_shim_handler_mac.cc | 19 |
2 files changed, 12 insertions, 9 deletions
diff --git a/apps/app_shim/app_shim_handler_mac.h b/apps/app_shim/app_shim_handler_mac.h index 2e73181..0ecde07 100644 --- a/apps/app_shim/app_shim_handler_mac.h +++ b/apps/app_shim/app_shim_handler_mac.h @@ -11,8 +11,6 @@ #include "apps/app_shim/app_shim_launch.h" #include "base/files/file_path.h" -class Profile; - namespace apps { // Registrar, and interface for services that can handle interactions with OSX diff --git a/apps/app_shim/extension_app_shim_handler_mac.cc b/apps/app_shim/extension_app_shim_handler_mac.cc index 4a580a5e..d9917bc 100644 --- a/apps/app_shim/extension_app_shim_handler_mac.cc +++ b/apps/app_shim/extension_app_shim_handler_mac.cc @@ -230,14 +230,16 @@ void ExtensionAppShimHandler::QuitAppForWindow(ShellWindow* shell_window) { ExtensionAppShimHandler* handler = g_browser_process->platform_part()->app_shim_host_manager()-> extension_app_shim_handler(); - Host* host = handler->FindHost(shell_window->profile(), - shell_window->extension_id()); + Host* host = handler->FindHost( + Profile::FromBrowserContext(shell_window->browser_context()), + shell_window->extension_id()); if (host) { handler->OnShimQuit(host); } else { // App shims might be disabled or the shim is still starting up. - ShellWindowRegistry::Get(shell_window->profile())-> - CloseAllShellWindowsForApp(shell_window->extension_id()); + ShellWindowRegistry::Get( + Profile::FromBrowserContext(shell_window->browser_context())) + ->CloseAllShellWindowsForApp(shell_window->extension_id()); } } @@ -245,7 +247,8 @@ void ExtensionAppShimHandler::HideAppForWindow(ShellWindow* shell_window) { ExtensionAppShimHandler* handler = g_browser_process->platform_part()->app_shim_host_manager()-> extension_app_shim_handler(); - Profile* profile = shell_window->profile(); + Profile* profile = + Profile::FromBrowserContext(shell_window->browser_context()); Host* host = handler->FindHost(profile, shell_window->extension_id()); if (host) host->OnAppHide(); @@ -258,7 +261,8 @@ void ExtensionAppShimHandler::FocusAppForWindow(ShellWindow* shell_window) { ExtensionAppShimHandler* handler = g_browser_process->platform_part()->app_shim_host_manager()-> extension_app_shim_handler(); - Profile* profile = shell_window->profile(); + Profile* profile = + Profile::FromBrowserContext(shell_window->browser_context()); const std::string& app_id = shell_window->extension_id(); Host* host = handler->FindHost(profile, app_id); if (host) { @@ -277,7 +281,8 @@ bool ExtensionAppShimHandler::RequestUserAttentionForWindow( ExtensionAppShimHandler* handler = g_browser_process->platform_part()->app_shim_host_manager()-> extension_app_shim_handler(); - Profile* profile = shell_window->profile(); + Profile* profile = + Profile::FromBrowserContext(shell_window->browser_context()); Host* host = handler->FindHost(profile, shell_window->extension_id()); if (host) { // Bring the window to the front without showing it. |