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

Side by Side Diff: third_party/WebKit/Source/platform/TimerTest.cpp

Issue 1865913005: Nuke WebPassOwnPtr<T> and replace it with std::unique_ptr<T>. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "platform/Timer.h" 5 #include "platform/Timer.h"
6 6
7 #include "platform/testing/TestingPlatformSupport.h" 7 #include "platform/testing/TestingPlatformSupport.h"
8 #include "public/platform/Platform.h" 8 #include "public/platform/Platform.h"
9 #include "public/platform/WebScheduler.h" 9 #include "public/platform/WebScheduler.h"
10 #include "public/platform/WebThread.h" 10 #include "public/platform/WebThread.h"
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 return m_timerTasks.size() == 1; 178 return m_timerTasks.size() == 1;
179 } 179 }
180 180
181 double nextTimerTaskDelaySecs() const 181 double nextTimerTaskDelaySecs() const
182 { 182 {
183 ASSERT(hasOneTimerTask()); 183 ASSERT(hasOneTimerTask());
184 return m_timerTasks.top().delaySeconds(); 184 return m_timerTasks.top().delaySeconds();
185 } 185 }
186 186
187 void shutdown() override {} 187 void shutdown() override {}
188 WebPassOwnPtr<WebViewScheduler> createWebViewScheduler(blink::WebView*) over ride { return nullptr; } 188 std::unique_ptr<WebViewScheduler> createWebViewScheduler(blink::WebView*) ov erride { return nullptr; }
189 void suspendTimerQueue() override { } 189 void suspendTimerQueue() override { }
190 void resumeTimerQueue() override { } 190 void resumeTimerQueue() override { }
191 void addPendingNavigation() override { } 191 void addPendingNavigation() override { }
192 void removePendingNavigation() override { } 192 void removePendingNavigation() override { }
193 void onNavigationStarted() override { } 193 void onNavigationStarted() override { }
194 194
195 private: 195 private:
196 std::priority_queue<DelayedTask> m_timerTasks; 196 std::priority_queue<DelayedTask> m_timerTasks;
197 MockWebTaskRunner m_timerWebTaskRunner; 197 MockWebTaskRunner m_timerWebTaskRunner;
198 }; 198 };
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after
760 TimerForTest<TimerTest> timer(this, &TimerTest::countingTask, &taskRunner); 760 TimerForTest<TimerTest> timer(this, &TimerTest::countingTask, &taskRunner);
761 timer.startOneShot(0, BLINK_FROM_HERE); 761 timer.startOneShot(0, BLINK_FROM_HERE);
762 762
763 // Make sure the task was posted on taskRunner. 763 // Make sure the task was posted on taskRunner.
764 EXPECT_FALSE(timerTasks.empty()); 764 EXPECT_FALSE(timerTasks.empty());
765 } 765 }
766 766
767 767
768 } // namespace 768 } // namespace
769 } // namespace blink 769 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/webusb/USB.cpp ('k') | third_party/WebKit/Source/platform/mediastream/RTCConfiguration.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698