OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. | 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
75 repeat_interval_ += delta; | 75 repeat_interval_ += delta; |
76 } | 76 } |
77 | 77 |
78 void MoveToNewTaskRunner(RefPtr<WebTaskRunner>); | 78 void MoveToNewTaskRunner(RefPtr<WebTaskRunner>); |
79 | 79 |
80 struct PLATFORM_EXPORT Comparator { | 80 struct PLATFORM_EXPORT Comparator { |
81 bool operator()(const TimerBase* a, const TimerBase* b) const; | 81 bool operator()(const TimerBase* a, const TimerBase* b) const; |
82 }; | 82 }; |
83 | 83 |
84 protected: | 84 protected: |
85 // TODO: temporary hack | |
Sami
2017/04/27 17:38:17
What's this for? :)
Dan Elphick
2017/05/03 09:41:06
no longer required
| |
86 friend class BitmapImage; | |
85 static RefPtr<WebTaskRunner> GetTimerTaskRunner(); | 87 static RefPtr<WebTaskRunner> GetTimerTaskRunner(); |
86 static RefPtr<WebTaskRunner> GetUnthrottledTaskRunner(); | 88 static RefPtr<WebTaskRunner> GetUnthrottledTaskRunner(); |
87 | 89 |
88 private: | 90 private: |
89 virtual void Fired() = 0; | 91 virtual void Fired() = 0; |
90 | 92 |
91 virtual RefPtr<WebTaskRunner> TimerTaskRunner() const; | 93 virtual RefPtr<WebTaskRunner> TimerTaskRunner() const; |
92 | 94 |
93 NO_SANITIZE_ADDRESS | 95 NO_SANITIZE_ADDRESS |
94 virtual bool CanFire() const { return true; } | 96 virtual bool CanFire() const { return true; } |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
202 inline bool TimerBase::IsActive() const { | 204 inline bool TimerBase::IsActive() const { |
203 #if DCHECK_IS_ON() | 205 #if DCHECK_IS_ON() |
204 DCHECK_EQ(thread_, CurrentThread()); | 206 DCHECK_EQ(thread_, CurrentThread()); |
205 #endif | 207 #endif |
206 return weak_ptr_factory_.HasWeakPtrs(); | 208 return weak_ptr_factory_.HasWeakPtrs(); |
207 } | 209 } |
208 | 210 |
209 } // namespace blink | 211 } // namespace blink |
210 | 212 |
211 #endif // Timer_h | 213 #endif // Timer_h |
OLD | NEW |