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

Side by Side Diff: content/browser/android/launcher_thread.cc

Issue 2808343004: android: Fix java launcher thread (Closed)
Patch Set: review comments Created 3 years, 8 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
« no previous file with comments | « no previous file | content/browser/browser_main_loop.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/android/launcher_thread.h" 5 #include "content/browser/android/launcher_thread.h"
6 6
7 #include "jni/LauncherThread_jni.h" 7 #include "jni/LauncherThread_jni.h"
8 8
9 namespace content { 9 namespace content {
10 namespace android { 10 namespace android {
11 11
12 namespace { 12 namespace {
13 base::LazyInstance<LauncherThread>::Leaky g_launcher_thread; 13 base::LazyInstance<LauncherThread>::Leaky g_launcher_thread;
14 } 14 }
15 15
16 base::MessageLoop* LauncherThread::GetMessageLoop() { 16 base::MessageLoop* LauncherThread::GetMessageLoop() {
17 return g_launcher_thread.Get().java_handler_thread_.message_loop(); 17 return g_launcher_thread.Get().java_handler_thread_.message_loop();
18 } 18 }
19 19
20 LauncherThread::LauncherThread() 20 LauncherThread::LauncherThread()
21 : java_handler_thread_(Java_LauncherThread_getHandlerThread( 21 : java_handler_thread_(Java_LauncherThread_getHandlerThread(
22 base::android::AttachCurrentThread())) {} 22 base::android::AttachCurrentThread())) {
23 java_handler_thread_.Start();
24 }
23 25
24 LauncherThread::~LauncherThread() {} 26 LauncherThread::~LauncherThread() {}
25 27
26 } // namespace android 28 } // namespace android
27 } // namespace content 29 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/browser_main_loop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698