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

Unified Diff: chrome/browser/idle_chromeos.cc

Issue 514293003: Run athena on chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressed comments, rebase Created 6 years, 3 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
Index: chrome/browser/idle_chromeos.cc
diff --git a/chrome/browser/idle_chromeos.cc b/chrome/browser/idle_chromeos.cc
index 62a72d46324bd95d8af0cc1a26a5ffcaeeb0c8c4..f61ff5e8d57dc9bb9af11621779772edc37bbadb 100644
--- a/chrome/browser/idle_chromeos.cc
+++ b/chrome/browser/idle_chromeos.cc
@@ -10,11 +10,21 @@
#include "ui/wm/core/user_activity_detector.h"
void CalculateIdleTime(IdleTimeCallback notify) {
+#if defined(USE_ATHENA)
+ // TODO(oshima): Implement this for athena. crbug.com/408752
+ base::TimeDelta idle_time;
+ NOTIMPLEMENTED();
+#else
base::TimeDelta idle_time = base::TimeTicks::Now() -
ash::Shell::GetInstance()->user_activity_detector()->last_activity_time();
+#endif
notify.Run(static_cast<int>(idle_time.InSeconds()));
}
bool CheckIdleStateIsLocked() {
+#if defined(USE_ATHENA)
+ return false;
+#else
return ash::Shell::GetInstance()->session_state_delegate()->IsScreenLocked();
+#endif
}

Powered by Google App Engine
This is Rietveld 408576698