| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/shell/android/shell_manager.h" | 5 #include "content/shell/android/shell_manager.h" |
| 6 | 6 |
| 7 #include "base/android/jni_android.h" | 7 #include "base/android/jni_android.h" |
| 8 #include "base/android/jni_string.h" | 8 #include "base/android/jni_string.h" |
| 9 #include "base/android/scoped_java_ref.h" | 9 #include "base/android/scoped_java_ref.h" |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| 11 #include "base/lazy_instance.h" | 11 #include "base/lazy_instance.h" |
| 12 #include "content/public/browser/web_contents.h" |
| 12 #include "content/shell/shell.h" | 13 #include "content/shell/shell.h" |
| 13 #include "content/shell/shell_browser_context.h" | 14 #include "content/shell/shell_browser_context.h" |
| 14 #include "content/shell/shell_content_browser_client.h" | 15 #include "content/shell/shell_content_browser_client.h" |
| 15 #include "content/public/browser/web_contents.h" | |
| 16 #include "content/shell/shell.h" | |
| 17 #include "googleurl/src/gurl.h" | |
| 18 #include "jni/ShellManager_jni.h" | 16 #include "jni/ShellManager_jni.h" |
| 17 #include "url/gurl.h" |
| 19 | 18 |
| 20 using base::android::ScopedJavaLocalRef; | 19 using base::android::ScopedJavaLocalRef; |
| 21 | 20 |
| 22 namespace { | 21 namespace { |
| 23 | 22 |
| 24 struct GlobalState { | 23 struct GlobalState { |
| 25 GlobalState() {} | 24 GlobalState() {} |
| 26 base::android::ScopedJavaGlobalRef<jobject> j_shell_manager; | 25 base::android::ScopedJavaGlobalRef<jobject> j_shell_manager; |
| 27 }; | 26 }; |
| 28 | 27 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 59 ShellContentBrowserClient::Get()->browser_context(); | 58 ShellContentBrowserClient::Get()->browser_context(); |
| 60 GURL url(base::android::ConvertJavaStringToUTF8(env, jurl)); | 59 GURL url(base::android::ConvertJavaStringToUTF8(env, jurl)); |
| 61 Shell::CreateNewWindow(browserContext, | 60 Shell::CreateNewWindow(browserContext, |
| 62 url, | 61 url, |
| 63 NULL, | 62 NULL, |
| 64 MSG_ROUTING_NONE, | 63 MSG_ROUTING_NONE, |
| 65 gfx::Size()); | 64 gfx::Size()); |
| 66 } | 65 } |
| 67 | 66 |
| 68 } // namespace content | 67 } // namespace content |
| OLD | NEW |