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

Side by Side Diff: components/web_contents_delegate_android/web_contents_delegate_android.h

Issue 16073002: components: Move web_contents_delegate_android into web_contents_delegate_android namespace. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix android java Created 7 years, 6 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
OLDNEW
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 #ifndef COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H _ 5 #ifndef COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H _
6 #define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H _ 6 #define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H _
7 7
8 #include "base/android/jni_helper.h" 8 #include "base/android/jni_helper.h"
9 #include "base/android/scoped_java_ref.h" 9 #include "base/android/scoped_java_ref.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "content/public/browser/web_contents_delegate.h" 12 #include "content/public/browser/web_contents_delegate.h"
13 #include "ui/gfx/vector2d.h" 13 #include "ui/gfx/vector2d.h"
14 14
15 class GURL; 15 class GURL;
16 16
17 namespace content { 17 namespace content {
18 class WebContents; 18 class WebContents;
19 class WebContentsDelegate; 19 class WebContentsDelegate;
20 struct NativeWebKeyboardEvent; 20 struct NativeWebKeyboardEvent;
21 struct OpenURLParams; 21 struct OpenURLParams;
22 } // namespace content 22 }
23 23
24 namespace components { 24 namespace web_contents_delegate_android {
25 25
26 enum WebContentsDelegateLogLevel { 26 enum WebContentsDelegateLogLevel {
27 // Equivalent of WebCore::WebConsoleMessage::LevelDebug. 27 // Equivalent of WebCore::WebConsoleMessage::LevelDebug.
28 WEB_CONTENTS_DELEGATE_LOG_LEVEL_DEBUG = 0, 28 WEB_CONTENTS_DELEGATE_LOG_LEVEL_DEBUG = 0,
29 // Equivalent of WebCore::WebConsoleMessage::LevelLog. 29 // Equivalent of WebCore::WebConsoleMessage::LevelLog.
30 WEB_CONTENTS_DELEGATE_LOG_LEVEL_LOG = 1, 30 WEB_CONTENTS_DELEGATE_LOG_LEVEL_LOG = 1,
31 // Equivalent of WebCore::WebConsoleMessage::LevelWarning. 31 // Equivalent of WebCore::WebConsoleMessage::LevelWarning.
32 WEB_CONTENTS_DELEGATE_LOG_LEVEL_WARNING = 2, 32 WEB_CONTENTS_DELEGATE_LOG_LEVEL_WARNING = 2,
33 // Equivalent of WebCore::WebConsoleMessage::LevelError. 33 // Equivalent of WebCore::WebConsoleMessage::LevelError.
34 WEB_CONTENTS_DELEGATE_LOG_LEVEL_ERROR = 3, 34 WEB_CONTENTS_DELEGATE_LOG_LEVEL_ERROR = 3,
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 100
101 private: 101 private:
102 // We depend on the java side user of WebContentDelegateAndroid to hold a 102 // We depend on the java side user of WebContentDelegateAndroid to hold a
103 // strong reference to that object as long as they want to receive callbacks 103 // strong reference to that object as long as they want to receive callbacks
104 // on it. Using a weak ref here allows it to be correctly GCed. 104 // on it. Using a weak ref here allows it to be correctly GCed.
105 JavaObjectWeakGlobalRef weak_java_delegate_; 105 JavaObjectWeakGlobalRef weak_java_delegate_;
106 }; 106 };
107 107
108 bool RegisterWebContentsDelegateAndroid(JNIEnv* env); 108 bool RegisterWebContentsDelegateAndroid(JNIEnv* env);
109 109
110 } // namespace components 110 } // namespace web_contents_delegate_android
111 111
112 #endif // COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROI D_H_ 112 #endif // COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROI D_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698