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

Unified Diff: ash/accelerators/accelerator_controller.cc

Issue 11047030: Decouple EventClientImpl and root window. Check containers on the same root window as focused windo… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cleanup Created 8 years, 2 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 | « no previous file | ash/accelerators/accelerator_table.cc » ('j') | ash/wm/event_client_impl.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/accelerators/accelerator_controller.cc
diff --git a/ash/accelerators/accelerator_controller.cc b/ash/accelerators/accelerator_controller.cc
index bc742c74cb6f419442a9cbb330a5129f90865cf4..56cf64c6ff81e126cba61d0531a1d0620ca83d81 100644
--- a/ash/accelerators/accelerator_controller.cc
+++ b/ash/accelerators/accelerator_controller.cc
@@ -33,6 +33,7 @@
#include "ash/system/tray/system_tray_delegate.h"
#include "ash/volume_control_delegate.h"
#include "ash/wm/partial_screenshot_view.h"
+#include "ash/wm/power_button_controller.h"
#include "ash/wm/property_util.h"
#include "ash/wm/window_cycle_controller.h"
#include "ash/wm/window_util.h"
@@ -57,6 +58,7 @@
#if defined(OS_CHROMEOS)
#include "ash/display/output_configurator_animation.h"
#include "base/chromeos/chromeos_version.h"
+#include "base/time.h"
#include "chromeos/display/output_configurator.h"
#endif // defined(OS_CHROMEOS)
@@ -761,11 +763,17 @@ bool AcceleratorController::PerformAction(int action,
return HandleMediaPlayPause();
case MEDIA_PREV_TRACK:
return HandleMediaPrevTrack();
- case POWER_PRESSED: // fallthrough
+ case POWER_PRESSED:
Daniel Erat 2012/10/06 14:01:20 i think that i'd rather that you made separate LOC
oshima 2012/10/06 17:20:58 I added shutdown as well. I prefer to keep this as
Daniel Erat 2012/10/07 13:40:02 I don't understand the "consistent with the device
case POWER_RELEASED:
- // We don't do anything with these at present, but we consume them to
- // prevent them from getting passed to apps -- see
- // http://crbug.com/146609.
+ // We don't do anything with these at present on the device, but
+ // we consume them to prevent them from getting passed to apps
+ // -- see http://crbug.com/146609.
Daniel Erat 2012/10/06 14:00:19 this comment needs to be updated
oshima 2012/10/06 17:20:58 This was actually updated, but probably not clear
+#if defined(OS_CHROMEOS)
+ if (!base::chromeos::IsRunningOnChromeOS()) {
+ Shell::GetInstance()->power_button_controller()->
+ OnLockButtonEvent(action == POWER_PRESSED, base::TimeTicks());
+ }
+#endif
return true;
#if !defined(NDEBUG)
case PRINT_LAYER_HIERARCHY:
« no previous file with comments | « no previous file | ash/accelerators/accelerator_table.cc » ('j') | ash/wm/event_client_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698