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

Side by Side Diff: Source/web/WebKit.cpp

Issue 656463004: Use the scheduling mechanism provided by the platform (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Bad upload. Created 6 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 ASSERT(!s_webKitInitialized); 141 ASSERT(!s_webKitInitialized);
142 s_webKitInitialized = true; 142 s_webKitInitialized = true;
143 143
144 ASSERT(platform); 144 ASSERT(platform);
145 Platform::initialize(platform); 145 Platform::initialize(platform);
146 146
147 WTF::setRandomSource(cryptographicallyRandomValues); 147 WTF::setRandomSource(cryptographicallyRandomValues);
148 WTF::initialize(currentTimeFunction, monotonicallyIncreasingTimeFunction); 148 WTF::initialize(currentTimeFunction, monotonicallyIncreasingTimeFunction);
149 WTF::initializeMainThread(callOnMainThreadFunction); 149 WTF::initializeMainThread(callOnMainThreadFunction);
150 Heap::init(); 150 Heap::init();
151 Scheduler::initializeOnMainThread();
152 151
153 ThreadState::attachMainThread(); 152 ThreadState::attachMainThread();
154 // currentThread will always be non-null in production, but can be null in C hromium unit tests. 153 // currentThread will always be non-null in production, but can be null in C hromium unit tests.
155 if (WebThread* currentThread = platform->currentThread()) { 154 if (WebThread* currentThread = platform->currentThread()) {
156 ASSERT(!s_pendingGCRunner); 155 ASSERT(!s_pendingGCRunner);
157 s_pendingGCRunner = new PendingGCRunner; 156 s_pendingGCRunner = new PendingGCRunner;
158 currentThread->addTaskObserver(s_pendingGCRunner); 157 currentThread->addTaskObserver(s_pendingGCRunner);
159 158
160 ASSERT(!s_messageLoopInterruptor); 159 ASSERT(!s_messageLoopInterruptor);
161 s_messageLoopInterruptor = new MessageLoopInterruptor(currentThread); 160 s_messageLoopInterruptor = new MessageLoopInterruptor(currentThread);
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 channel->state = WTFLogChannelOn; 255 channel->state = WTFLogChannelOn;
257 #endif // !LOG_DISABLED 256 #endif // !LOG_DISABLED
258 } 257 }
259 258
260 void resetPluginCache(bool reloadPages) 259 void resetPluginCache(bool reloadPages)
261 { 260 {
262 Page::refreshPlugins(reloadPages); 261 Page::refreshPlugins(reloadPages);
263 } 262 }
264 263
265 } // namespace blink 264 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698