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

Side by Side Diff: third_party/WebKit/Source/platform/testing/TestingPlatformSupport.cpp

Issue 2148363004: Use std::unique_ptr<> for WebTaskRunner::clone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 5 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 /* 1 /*
2 * Copyright (C) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 { 83 {
84 NOTREACHED(); 84 NOTREACHED();
85 } 85 }
86 86
87 bool runsTasksOnCurrentThread() override 87 bool runsTasksOnCurrentThread() override
88 { 88 {
89 NOTREACHED(); 89 NOTREACHED();
90 return true; 90 return true;
91 } 91 }
92 92
93 WebTaskRunner* clone() override 93 std::unique_ptr<WebTaskRunner> clone() override
94 { 94 {
95 return new TestingPlatformMockWebTaskRunner(m_tasks); 95 return WTF::wrapUnique(new TestingPlatformMockWebTaskRunner(m_tasks));
96 } 96 }
97 97
98 double virtualTimeSeconds() const override 98 double virtualTimeSeconds() const override
99 { 99 {
100 NOTREACHED(); 100 NOTREACHED();
101 return 0.0; 101 return 0.0;
102 } 102 }
103 103
104 double monotonicallyIncreasingVirtualTimeSeconds() const override 104 double monotonicallyIncreasingVirtualTimeSeconds() const override
105 { 105 {
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 { 187 {
188 return m_mockWebThread.get(); 188 return m_mockWebThread.get();
189 } 189 }
190 190
191 TestingPlatformMockScheduler* TestingPlatformSupportWithMockScheduler::mockWebSc heduler() 191 TestingPlatformMockScheduler* TestingPlatformSupportWithMockScheduler::mockWebSc heduler()
192 { 192 {
193 return m_mockWebThread->mockWebScheduler(); 193 return m_mockWebThread->mockWebScheduler();
194 } 194 }
195 195
196 } // namespace blink 196 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/mac/ScrollAnimatorMac.mm ('k') | third_party/WebKit/public/platform/WebTaskRunner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698