Index: chrome/browser/chromeos/display/display_configuration_observer.cc |
diff --git a/chrome/browser/chromeos/display/display_configuration_observer.cc b/chrome/browser/chromeos/display/display_configuration_observer.cc |
index a3674c1074d1dd80f12242b390aa1939ee66e4b0..5e36c434a2b22746e6c5aafd80f8dbe3ac16abb3 100644 |
--- a/chrome/browser/chromeos/display/display_configuration_observer.cc |
+++ b/chrome/browser/chromeos/display/display_configuration_observer.cc |
@@ -4,11 +4,11 @@ |
#include "chrome/browser/chromeos/display/display_configuration_observer.h" |
-#include "ash/common/shell_delegate.h" |
-#include "ash/common/wm_shell.h" |
#include "ash/display/window_tree_host_manager.h" |
#include "ash/shell.h" |
+#include "base/command_line.h" |
#include "chrome/browser/chromeos/display/display_preferences.h" |
+#include "chromeos/chromeos_switches.h" |
namespace chromeos { |
@@ -22,7 +22,8 @@ DisplayConfigurationObserver::~DisplayConfigurationObserver() { |
void DisplayConfigurationObserver::OnDisplaysInitialized() { |
// Update the display pref with the initial power state. |
- if (ash::WmShell::Get()->delegate()->IsFirstRunAfterBoot()) |
+ base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); |
+ if (command_line->HasSwitch(chromeos::switches::kFirstExecAfterBoot)) |
StoreDisplayPrefs(); |
} |