From f8b3ef8aab85985cb74d748112a1a3ec8e2b7ed8 Mon Sep 17 00:00:00 2001 From: "tfarina@chromium.org" Date: Mon, 11 Oct 2010 02:45:52 +0000 Subject: Rename ChromeThread to BrowserThread Part15: - Rename entries in more 40 files under chrome/browser. BUG=56926 TEST=trybots Review URL: http://codereview.chromium.org/3704001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62130 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/file_path_watcher_mac.cc | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'chrome/browser/file_path_watcher_mac.cc') diff --git a/chrome/browser/file_path_watcher_mac.cc b/chrome/browser/file_path_watcher_mac.cc index b95992c..ddcfd41 100644 --- a/chrome/browser/file_path_watcher_mac.cc +++ b/chrome/browser/file_path_watcher_mac.cc @@ -68,7 +68,7 @@ void FSEventsCallback(ConstFSEventStreamRef stream, void* event_watcher, size_t num_events, void* event_paths, const FSEventStreamEventFlags flags[], const FSEventStreamEventId event_ids[]) { - DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); + DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); FilePathWatcherImpl* watcher = reinterpret_cast(event_watcher); @@ -87,12 +87,12 @@ void FSEventsCallback(ConstFSEventStreamRef stream, if (root_changed) { // Resetting the event stream from within the callback fails (FSEvents spews // bad file descriptor errors), so post a task to do the reset. - ChromeThread::PostTask(ChromeThread::UI, FROM_HERE, + BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, NewRunnableMethod(watcher, &FilePathWatcherImpl::UpdateEventStream, root_change_at)); } - ChromeThread::PostTask(ChromeThread::FILE, FROM_HERE, + BrowserThread::PostTask(BrowserThread::FILE, FROM_HERE, NewRunnableMethod(watcher, &FilePathWatcherImpl::OnFilePathChanged)); } @@ -104,7 +104,7 @@ FilePathWatcherImpl::FilePathWatcherImpl() } void FilePathWatcherImpl::OnFilePathChanged() { - DCHECK(ChromeThread::CurrentlyOn(ChromeThread::FILE)); + DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE)); DCHECK(!target_.empty()); base::PlatformFileInfo file_info; @@ -156,7 +156,7 @@ bool FilePathWatcherImpl::Watch(const FilePath& path, first_notification_ = base::Time::Now(); } - ChromeThread::PostTask(ChromeThread::UI, FROM_HERE, + BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, NewRunnableMethod(this, &FilePathWatcherImpl::UpdateEventStream, start_event)); @@ -165,8 +165,8 @@ bool FilePathWatcherImpl::Watch(const FilePath& path, void FilePathWatcherImpl::Cancel() { // Switch to the UI thread if necessary, so we can tear down the event stream. - if (!ChromeThread::CurrentlyOn(ChromeThread::UI)) { - ChromeThread::PostTask(ChromeThread::UI, FROM_HERE, + if (!BrowserThread::CurrentlyOn(BrowserThread::UI)) { + BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, NewRunnableMethod(this, &FilePathWatcherImpl::Cancel)); return; } @@ -177,7 +177,7 @@ void FilePathWatcherImpl::Cancel() { } void FilePathWatcherImpl::UpdateEventStream(FSEventStreamEventId start_event) { - DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); + DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); // It can happen that the watcher gets canceled while tasks that call this // function are still in flight, so abort if this situation is detected. @@ -211,14 +211,14 @@ void FilePathWatcherImpl::UpdateEventStream(FSEventStreamEventId start_event) { FSEventStreamScheduleWithRunLoop(fsevent_stream_, CFRunLoopGetCurrent(), kCFRunLoopDefaultMode); if (!FSEventStreamStart(fsevent_stream_)) { - ChromeThread::PostTask(ChromeThread::FILE, FROM_HERE, + BrowserThread::PostTask(BrowserThread::FILE, FROM_HERE, NewRunnableMethod(delegate_.get(), &FilePathWatcher::Delegate::OnError)); } } void FilePathWatcherImpl::DestroyEventStream() { - DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); + DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); FSEventStreamStop(fsevent_stream_); FSEventStreamInvalidate(fsevent_stream_); FSEventStreamRelease(fsevent_stream_); -- cgit v1.1