Index: content/browser/android/launcher_thread.cc |
diff --git a/content/browser/android/launcher_thread.cc b/content/browser/android/launcher_thread.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..2c59a2da7a5756000a98be34c925e8f93eb88a32 |
--- /dev/null |
+++ b/content/browser/android/launcher_thread.cc |
@@ -0,0 +1,27 @@ |
+// Copyright 2017 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#include "content/browser/android/launcher_thread.h" |
+ |
+#include "jni/LauncherThread_jni.h" |
+ |
+namespace content { |
+namespace android { |
+ |
+namespace { |
+base::LazyInstance<LauncherThread>::Leaky g_launcher_thread; |
+} |
+ |
+base::MessageLoop* LauncherThread::GetMessageLoop() { |
+ return g_launcher_thread.Get().java_handler_thread_.message_loop(); |
+} |
+ |
+LauncherThread::LauncherThread() |
+ : java_handler_thread_(Java_LauncherThread_getHandlerThread( |
+ base::android::AttachCurrentThread())) {} |
+ |
+LauncherThread::~LauncherThread() {} |
+ |
+} // namespace android |
+} // namespace content |