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

Side by Side Diff: cc/scheduler/begin_frame_source.h

Issue 1136123009: Remove "mixin" from BeginFrameSource/Observer base classes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 #ifndef CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 5 #ifndef CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
6 #define CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 6 #define CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 virtual void AsValueInto(base::trace_event::TracedValue* dict) const = 0; 53 virtual void AsValueInto(base::trace_event::TracedValue* dict) const = 0;
54 }; 54 };
55 55
56 // Simple mix in which implements a BeginFrameObserver which checks the 56 // Simple mix in which implements a BeginFrameObserver which checks the
57 // incoming values meet the BeginFrameObserver requirements and implements the 57 // incoming values meet the BeginFrameObserver requirements and implements the
58 // required LastUsedBeginFrameArgs behaviour. 58 // required LastUsedBeginFrameArgs behaviour.
59 // 59 //
60 // Users of this mix in should; 60 // Users of this mix in should;
61 // - Implement the OnBeginFrameMixInDelegate function. 61 // - Implement the OnBeginFrameMixInDelegate function.
62 // - Recommended (but not required) to call 62 // - Recommended (but not required) to call
63 // BeginFrameObserverMixIn::OnValueInto in their overridden OnValueInto 63 // BeginFrameObserverBase::OnValueInto in their overridden OnValueInto
64 // function. 64 // function.
65 class CC_EXPORT BeginFrameObserverMixIn : public BeginFrameObserver { 65 class CC_EXPORT BeginFrameObserverBase : public BeginFrameObserver {
66 public: 66 public:
67 BeginFrameObserverMixIn(); 67 BeginFrameObserverBase();
68 68
69 // BeginFrameObserver 69 // BeginFrameObserver
70 70
71 // Traces |args| and DCHECK |args| satisfies pre-conditions then calls 71 // Traces |args| and DCHECK |args| satisfies pre-conditions then calls
72 // OnBeginFrameMixInDelegate and updates the last_begin_frame_args_ value on 72 // OnBeginFrameMixInDelegate and updates the last_begin_frame_args_ value on
73 // true. 73 // true.
74 void OnBeginFrame(const BeginFrameArgs& args) override; 74 void OnBeginFrame(const BeginFrameArgs& args) override;
75 const BeginFrameArgs LastUsedBeginFrameArgs() const override; 75 const BeginFrameArgs LastUsedBeginFrameArgs() const override;
76 76
77 // Outputs last_begin_frame_args_ 77 // Outputs last_begin_frame_args_
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 274
275 base::TimeDelta minimum_interval_; 275 base::TimeDelta minimum_interval_;
276 276
277 BeginFrameSource* active_source_; 277 BeginFrameSource* active_source_;
278 std::set<BeginFrameSource*> source_list_; 278 std::set<BeginFrameSource*> source_list_;
279 }; 279 };
280 280
281 } // namespace cc 281 } // namespace cc
282 282
283 #endif // CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 283 #endif // CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698