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

Side by Side Diff: chrome/browser/chromeos/system/ash_system_tray_delegate.cc

Issue 10825191: Allow closing root window, or pressing the power button to shutdown ash_shell, and chrome /w chrome… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Missed removing this somehow Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/wm/power_button_controller.cc ('k') | ui/aura/root_window.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" 5 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/shell_window_ids.h" 8 #include "ash/shell_window_ids.h"
9 #include "ash/system/audio/audio_observer.h" 9 #include "ash/system/audio/audio_observer.h"
10 #include "ash/system/bluetooth/bluetooth_observer.h" 10 #include "ash/system/bluetooth/bluetooth_observer.h"
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 } 360 }
361 361
362 virtual void SetCapsLockEnabled(bool enabled) OVERRIDE { 362 virtual void SetCapsLockEnabled(bool enabled) OVERRIDE {
363 input_method::InputMethodManager* ime_manager = 363 input_method::InputMethodManager* ime_manager =
364 input_method::InputMethodManager::GetInstance(); 364 input_method::InputMethodManager::GetInstance();
365 return ime_manager->GetXKeyboard()->SetCapsLockEnabled(enabled); 365 return ime_manager->GetXKeyboard()->SetCapsLockEnabled(enabled);
366 } 366 }
367 367
368 virtual void ShutDown() OVERRIDE { 368 virtual void ShutDown() OVERRIDE {
369 DBusThreadManager::Get()->GetPowerManagerClient()->RequestShutdown(); 369 DBusThreadManager::Get()->GetPowerManagerClient()->RequestShutdown();
370 if (!base::chromeos::IsRunningOnChromeOS())
371 browser::AttemptUserExit();
370 } 372 }
371 373
372 virtual void SignOut() OVERRIDE { 374 virtual void SignOut() OVERRIDE {
373 browser::AttemptUserExit(); 375 browser::AttemptUserExit();
374 } 376 }
375 377
376 virtual void RequestLockScreen() OVERRIDE { 378 virtual void RequestLockScreen() OVERRIDE {
377 DBusThreadManager::Get()->GetSessionManagerClient()->RequestLockScreen(); 379 DBusThreadManager::Get()->GetSessionManagerClient()->RequestLockScreen();
378 } 380 }
379 381
(...skipping 873 matching lines...) Expand 10 before | Expand all | Expand 10 after
1253 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate); 1255 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate);
1254 }; 1256 };
1255 1257
1256 } // namespace 1258 } // namespace
1257 1259
1258 ash::SystemTrayDelegate* CreateSystemTrayDelegate(ash::SystemTray* tray) { 1260 ash::SystemTrayDelegate* CreateSystemTrayDelegate(ash::SystemTray* tray) {
1259 return new chromeos::SystemTrayDelegate(tray); 1261 return new chromeos::SystemTrayDelegate(tray);
1260 } 1262 }
1261 1263
1262 } // namespace chromeos 1264 } // namespace chromeos
OLDNEW
« no previous file with comments | « ash/wm/power_button_controller.cc ('k') | ui/aura/root_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698