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

Side by Side Diff: Source/modules/webdatabase/DatabaseThread.cpp

Issue 469773002: Cleanup blink:: prefix usage in Source/core/modules/[mediasource/*.cpp to websockets/*.cpp] (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 4 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) 2007, 2008, 2013 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2013 Apple 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 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 #if ENABLE(OILPAN) 65 #if ENABLE(OILPAN)
66 visitor->trace(m_openDatabaseSet); 66 visitor->trace(m_openDatabaseSet);
67 visitor->trace(m_transactionCoordinator); 67 visitor->trace(m_transactionCoordinator);
68 #endif 68 #endif
69 } 69 }
70 70
71 void DatabaseThread::start() 71 void DatabaseThread::start()
72 { 72 {
73 if (m_thread) 73 if (m_thread)
74 return; 74 return;
75 m_thread = adoptPtr(blink::Platform::current()->createThread("WebCore: Datab ase")); 75 m_thread = adoptPtr(Platform::current()->createThread("WebCore: Database"));
76 m_thread->postTask(new Task(WTF::bind(&DatabaseThread::setupDatabaseThread, this))); 76 m_thread->postTask(new Task(WTF::bind(&DatabaseThread::setupDatabaseThread, this)));
77 } 77 }
78 78
79 void DatabaseThread::setupDatabaseThread() 79 void DatabaseThread::setupDatabaseThread()
80 { 80 {
81 m_pendingGCRunner = adoptPtr(new PendingGCRunner); 81 m_pendingGCRunner = adoptPtr(new PendingGCRunner);
82 m_messageLoopInterruptor = adoptPtr(new MessageLoopInterruptor(m_thread.get( ))); 82 m_messageLoopInterruptor = adoptPtr(new MessageLoopInterruptor(m_thread.get( )));
83 m_thread->addTaskObserver(m_pendingGCRunner.get()); 83 m_thread->addTaskObserver(m_pendingGCRunner.get());
84 ThreadState::attach(); 84 ThreadState::attach();
85 ThreadState::current()->addInterruptor(m_messageLoopInterruptor.get()); 85 ThreadState::current()->addInterruptor(m_messageLoopInterruptor.get());
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 165
166 void DatabaseThread::scheduleTask(PassOwnPtr<DatabaseTask> task) 166 void DatabaseThread::scheduleTask(PassOwnPtr<DatabaseTask> task)
167 { 167 {
168 ASSERT(m_thread); 168 ASSERT(m_thread);
169 ASSERT(!task->hasSynchronizer() || task->hasCheckedForTermination()); 169 ASSERT(!task->hasSynchronizer() || task->hasCheckedForTermination());
170 // WebThread takes ownership of the task. 170 // WebThread takes ownership of the task.
171 m_thread->postTask(task.leakPtr()); 171 m_thread->postTask(task.leakPtr());
172 } 172 }
173 173
174 } // namespace blink 174 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/webdatabase/DatabaseBackendBase.cpp ('k') | Source/modules/webdatabase/DatabaseTracker.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698