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

Unified Diff: components/scheduler/child/virtual_time_tqm_delegate.h

Issue 1652083002: Prepare for per-webview virtual time (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 11 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: components/scheduler/child/virtual_time_tqm_delegate.h
diff --git a/components/scheduler/child/virtual_time_tqm_delegate.h b/components/scheduler/child/virtual_time_tqm_delegate.h
deleted file mode 100644
index 8a0aae2bf3536beb8fcadb3c803dc22fba0ef693..0000000000000000000000000000000000000000
--- a/components/scheduler/child/virtual_time_tqm_delegate.h
+++ /dev/null
@@ -1,64 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef COMPONENTS_SCHEDULER_CHILD_VIRTUAL_TIME_TQM_DELEGATE_H_
-#define COMPONENTS_SCHEDULER_CHILD_VIRTUAL_TIME_TQM_DELEGATE_H_
-
-#include <map>
-
-#include "base/macros.h"
-#include "base/message_loop/message_loop.h"
-#include "base/time/tick_clock.h"
-#include "components/scheduler/child/scheduler_tqm_delegate.h"
-#include "components/scheduler/scheduler_export.h"
-
-namespace scheduler {
-
-class SCHEDULER_EXPORT VirtualTimeTqmDelegate : public SchedulerTqmDelegate {
- public:
- // |message_loop| is not owned and must outlive the lifetime of this object.
- static scoped_refptr<VirtualTimeTqmDelegate> Create(
- base::MessageLoop* message_loop,
- base::TimeTicks initial_now);
-
- // SchedulerTqmDelegate implementation
- void SetDefaultTaskRunner(
- scoped_refptr<base::SingleThreadTaskRunner> task_runner) override;
- void RestoreDefaultTaskRunner() override;
- bool PostDelayedTask(const tracked_objects::Location& from_here,
- const base::Closure& task,
- base::TimeDelta delay) override;
- bool PostNonNestableDelayedTask(const tracked_objects::Location& from_here,
- const base::Closure& task,
- base::TimeDelta delay) override;
- bool RunsTasksOnCurrentThread() const override;
- bool IsNested() const override;
- base::TimeTicks NowTicks() override;
- void OnNoMoreImmediateWork() override;
- double CurrentTimeSeconds() const override;
-
- protected:
- ~VirtualTimeTqmDelegate() override;
-
- private:
- explicit VirtualTimeTqmDelegate(base::MessageLoop* message_loop,
- base::TimeTicks initial_no);
-
- void AdvancedTimeTo(base::TimeTicks now);
-
- typedef std::multimap<base::TimeTicks, base::Closure> DelayedWakeupMultimap;
-
- DelayedWakeupMultimap delayed_wakeup_multimap_;
-
- // Not owned.
- base::MessageLoop* message_loop_;
- scoped_refptr<SingleThreadTaskRunner> message_loop_task_runner_;
- base::TimeTicks now_;
-
- DISALLOW_COPY_AND_ASSIGN(VirtualTimeTqmDelegate);
-};
-
-} // namespace scheduler
-
-#endif // COMPONENTS_SCHEDULER_CHILD_VIRTUAL_TIME_TQM_DELEGATE_H_
« no previous file with comments | « components/scheduler/child/scheduler_tqm_delegate_impl.cc ('k') | components/scheduler/child/virtual_time_tqm_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698