Roll src/third_party/skia 0b71278:f7aaadb
[chromium-blink-merge.git] / ios / web / web_thread_impl.cc
blob5f5b6150d9aa9472f24a79d2f9f3d08879ab49f7
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "ios/web/web_thread_impl.h"
7 #include "base/logging.h"
9 namespace web {
11 content::BrowserThread::ID BrowserThreadIDFromWebThreadID(
12 WebThread::ID identifier) {
13 switch (identifier) {
14 case WebThread::UI:
15 return content::BrowserThread::UI;
16 case WebThread::DB:
17 return content::BrowserThread::DB;
18 case WebThread::FILE:
19 return content::BrowserThread::FILE;
20 case WebThread::FILE_USER_BLOCKING:
21 return content::BrowserThread::FILE_USER_BLOCKING;
22 case WebThread::CACHE:
23 return content::BrowserThread::CACHE;
24 case WebThread::IO:
25 return content::BrowserThread::IO;
26 default:
27 NOTREACHED() << "Unknown web::WebThread::ID: " << identifier;
28 return content::BrowserThread::UI;
32 } // namespace web