Chromium Code Reviews| Index: chrome/browser/lifetime/application_lifetime_aura.cc |
| diff --git a/chrome/browser/lifetime/application_lifetime_aura.cc b/chrome/browser/lifetime/application_lifetime_aura.cc |
| index 75d67bae8588d0be4b9bddcc62e7089cd362d412..a082d3a25aa328778024eb02ff8cfd34a7fb1c60 100644 |
| --- a/chrome/browser/lifetime/application_lifetime_aura.cc |
| +++ b/chrome/browser/lifetime/application_lifetime_aura.cc |
| @@ -4,7 +4,6 @@ |
| #include "chrome/browser/lifetime/application_lifetime.h" |
| -#include "ash/shell.h" |
| #include "base/command_line.h" |
| #include "chrome/browser/browser_process.h" |
| #include "chrome/browser/notifications/notification_ui_manager.h" |
| @@ -13,6 +12,10 @@ |
| #include "ui/aura/window_event_dispatcher.h" |
| #include "ui/views/widget/widget.h" |
| +#if defined(USE_ASH) |
| +#include "ash/shell.h" |
| +#endif |
| + |
| namespace chrome { |
| void HandleAppExitingForPlatform() { |
| @@ -20,6 +23,7 @@ void HandleAppExitingForPlatform() { |
| // and windows created by Ash (launcher, background, etc). |
| g_browser_process->notification_ui_manager()->CancelAll(); |
| +#if defined(USE_ASH) |
| // This may be called before |ash::Shell| is initialized when |
| // XIOError is reported. crbug.com/150633. |
| if (ash::Shell::HasInstance()) { |
| @@ -28,6 +32,7 @@ void HandleAppExitingForPlatform() { |
| aura::client::GetCaptureClient(ash::Shell::GetPrimaryRootWindow())-> |
| SetCapture(NULL); |
| } |
| +#endif // defined(USE_ASH) |
| views::Widget::CloseAllSecondaryWidgets(); |
| @@ -43,7 +48,7 @@ void HandleAppExitingForPlatform() { |
| // NotifyAndTerminate does nothing if called more than once. |
| NotifyAndTerminate(true); |
| } |
| -#endif // OS_CHROMEOS |
| +#endif // defined(OS_CHROMEOS) |
|
sky
2015/11/20 23:46:40
IMO this style of comments are a waste.
mohsen
2015/11/21 01:05:17
Do you mean the whole comment or just the part I a
sky
2015/11/22 16:00:22
I mean the trailing // defined(OS_CHROMEOS). Comme
|
| } |
| } // namespace chrome |