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

Unified Diff: extensions/browser/api/hid/hid_device_manager.cc

Issue 771393002: Migrate HidServiceLinux and HidConnectionLinux to BrowserThread::UI. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Switched to an embedded thread checker. Created 6 years 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 side-by-side diff with in-line comments
Download patch
Index: extensions/browser/api/hid/hid_device_manager.cc
diff --git a/extensions/browser/api/hid/hid_device_manager.cc b/extensions/browser/api/hid/hid_device_manager.cc
index 838099ef8d284d5f53b1e68d6a69391839535345..1490e87303bb66111f5e4ec04faab6b701f4b96c 100644
--- a/extensions/browser/api/hid/hid_device_manager.cc
+++ b/extensions/browser/api/hid/hid_device_manager.cc
@@ -148,12 +148,11 @@ bool HidDeviceManager::HasPermission(const Extension* extension,
// static
bool HidDeviceManager::IsCalledOnValidThread() {
-#if defined(OS_MACOSX)
- // Migration from FILE thread to UI thread. OS X gets it first.
- return content::BrowserThread::CurrentlyOn(content::BrowserThread::UI);
-#else
- // TODO(reillyg): Migrate Linux/CrOS and Windows as well.
+#if defined(OS_WIN)
+ // TODO(reillyg): Migrate Windows backend from FILE thread to UI thread.
return content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE);
+#else
+ return content::BrowserThread::CurrentlyOn(content::BrowserThread::UI);
#endif
}
« no previous file with comments | « extensions/browser/api/hid/hid_connection_resource.h ('k') | extensions/shell/browser/shell_device_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698