Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Unified Diff: ash/shell.cc

Issue 12212171: Provides more types of errors for output status. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/shell.h ('k') | chromeos/display/output_configurator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shell.cc
diff --git a/ash/shell.cc b/ash/shell.cc
index ffa015abffb370e6fe45248b19caa43f4abd952b..c6965b297469821dcdd0f96970f131346c365ef9 100644
--- a/ash/shell.cc
+++ b/ash/shell.cc
@@ -106,6 +106,7 @@
#if defined(OS_CHROMEOS)
#include "ash/ash_constants.h"
#include "ash/display/display_change_observer_x11.h"
+#include "ash/display/display_error_dialog.h"
#include "ash/display/output_configurator_animation.h"
#include "base/chromeos/chromeos_version.h"
#include "base/message_pump_aurax11.h"
@@ -303,17 +304,19 @@ Shell::~Shell() {
// because they might have registered ActivationChangeObserver.
activation_controller_.reset();
- DCHECK(instance_ == this);
- instance_ = NULL;
-
#if defined(OS_CHROMEOS)
if (display_change_observer_.get())
output_configurator_->RemoveObserver(display_change_observer_.get());
if (output_configurator_animation_.get())
output_configurator_->RemoveObserver(output_configurator_animation_.get());
+ if (display_error_observer_.get())
+ output_configurator_->RemoveObserver(display_error_observer_.get());
base::MessagePumpAuraX11::Current()->RemoveDispatcherForRootWindow(
output_configurator());
#endif // defined(OS_CHROMEOS)
+
+ DCHECK(instance_ == this);
+ instance_ = NULL;
}
// static
@@ -418,8 +421,10 @@ void Shell::Init() {
// observer gets invoked after the root windows are configured.
output_configurator_->AddObserver(display_change_observer_.get());
output_configurator_animation_.reset(
- new internal::OutputConfiguratorAnimation()),
+ new internal::OutputConfiguratorAnimation());
+ display_error_observer_.reset(new internal::DisplayErrorObserver());
output_configurator_->AddObserver(output_configurator_animation_.get());
+ output_configurator_->AddObserver(display_error_observer_.get());
display_change_observer_->OnDisplayModeChanged();
}
#endif
« no previous file with comments | « ash/shell.h ('k') | chromeos/display/output_configurator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698