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

Side by Side Diff: components/timers/alarm_timer_chromeos.cc

Issue 1997153002: libchrome: Several upstreamable fixes from libchrome Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: Addressed feedback Created 4 years, 6 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/timers/alarm_timer_chromeos.h" 5 #include "components/timers/alarm_timer_chromeos.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 #include <sys/timerfd.h> 8 #include <sys/timerfd.h>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 if (origin_task_runner_->RunsTasksOnCurrentThread()) { 246 if (origin_task_runner_->RunsTasksOnCurrentThread()) {
247 OnTimerFired(io_reset_sequence_number_); 247 OnTimerFired(io_reset_sequence_number_);
248 } else { 248 } else {
249 origin_task_runner_->PostTask( 249 origin_task_runner_->PostTask(
250 FROM_HERE, 250 FROM_HERE,
251 base::Bind(&Delegate::OnTimerFired, scoped_refptr<Delegate>(this), 251 base::Bind(&Delegate::OnTimerFired, scoped_refptr<Delegate>(this),
252 io_reset_sequence_number_)); 252 io_reset_sequence_number_));
253 } 253 }
254 } 254 }
255 255
256 void AlarmTimer::Delegate::OnFileCanWriteWithoutBlocking(int fd) { 256 void AlarmTimer::Delegate::OnFileCanWriteWithoutBlocking(int /*fd*/) {
257 NOTREACHED(); 257 NOTREACHED();
258 } 258 }
259 259
260 void AlarmTimer::Delegate::SetTimerFiredCallbackForTest( 260 void AlarmTimer::Delegate::SetTimerFiredCallbackForTest(
261 base::Closure test_callback) { 261 base::Closure test_callback) {
262 on_timer_fired_callback_for_test_ = test_callback; 262 on_timer_fired_callback_for_test_ = test_callback;
263 } 263 }
264 264
265 void AlarmTimer::Delegate::ResetImpl(base::TimeDelta delay, 265 void AlarmTimer::Delegate::ResetImpl(base::TimeDelta delay,
266 int reset_sequence_number) { 266 int reset_sequence_number) {
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 SimpleAlarmTimer::SimpleAlarmTimer(const tracked_objects::Location& posted_from, 467 SimpleAlarmTimer::SimpleAlarmTimer(const tracked_objects::Location& posted_from,
468 base::TimeDelta delay, 468 base::TimeDelta delay,
469 const base::Closure& user_task) 469 const base::Closure& user_task)
470 : AlarmTimer(posted_from, delay, user_task, false) { 470 : AlarmTimer(posted_from, delay, user_task, false) {
471 } 471 }
472 472
473 SimpleAlarmTimer::~SimpleAlarmTimer() { 473 SimpleAlarmTimer::~SimpleAlarmTimer() {
474 } 474 }
475 475
476 } // namespace timers 476 } // namespace timers
OLDNEW
« base/metrics/histogram.cc ('K') | « base/values.cc ('k') | dbus/bus.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698