Chromium Code Reviews| Index: chrome/browser/ui/views/panels/panel_view.cc |
| diff --git a/chrome/browser/ui/views/panels/panel_view.cc b/chrome/browser/ui/views/panels/panel_view.cc |
| index 9775a2de76037edc08dd156748942d37f79553cf..ba6ef05c71173d62392b45fa2d14c8249267f03f 100644 |
| --- a/chrome/browser/ui/views/panels/panel_view.cc |
| +++ b/chrome/browser/ui/views/panels/panel_view.cc |
| @@ -14,13 +14,14 @@ |
| #include "base/strings/utf_string_conversions.h" |
| #include "build/build_config.h" |
| #include "chrome/app/chrome_command_ids.h" |
| +#include "chrome/browser/lifetime/keep_alive_types.h" |
| +#include "chrome/browser/lifetime/scoped_keep_alive.h" |
| #include "chrome/browser/profiles/profile.h" |
| #include "chrome/browser/ui/host_desktop.h" |
| #include "chrome/browser/ui/panels/panel.h" |
| #include "chrome/browser/ui/panels/panel_bounds_animation.h" |
| #include "chrome/browser/ui/panels/panel_manager.h" |
| #include "chrome/browser/ui/panels/stacked_panel_collection.h" |
| -#include "chrome/browser/ui/views/auto_keep_alive.h" |
| #include "chrome/browser/ui/views/panels/panel_frame_view.h" |
| #include "content/public/browser/render_view_host.h" |
| #include "content/public/browser/render_widget_host_view.h" |
| @@ -300,8 +301,11 @@ PanelView::PanelView(Panel* panel, const gfx::Rect& bounds, bool always_on_top) |
| window_->set_focus_on_creation(false); |
| window_->AddObserver(this); |
| +#if !defined(OS_CHROMEOS) |
|
sky
2016/02/25 18:43:50
I think want !USE_ASH here.
dgn
2016/02/25 20:08:50
Isn't there[1] where the count is incremented to b
sky
2016/02/25 23:27:49
I think that increment should be outside the ifdef
dgn
2016/02/26 11:51:59
Done.
dgn
2016/02/26 11:51:59
Thanks, I'll keep that in mind when changing that
|
| // Prevent the browser process from shutting down while this window is open. |
| - keep_alive_.reset(new AutoKeepAlive(GetNativePanelWindow())); |
| + // Chrome OS already has a mechanism to always stay alive and skips this. |
| + keep_alive_.reset(new ScopedKeepAlive(KeepAliveOrigin::PANEL_VIEW)); |
| +#endif // !defined(OS_CHROMEOS) |
| web_view_ = new views::WebView(NULL); |
| AddChildView(web_view_); |