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

Side by Side Diff: android_webview/native/aw_quota_manager_bridge.cc

Issue 12253057: Implement WebStorage API methods (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "android_webview/native/aw_quota_manager_bridge.h"
6
7 #include "android_webview/browser/aw_browser_context.h"
8 #include "android_webview/browser/aw_content_browser_client.h"
9 #include "content/public/common/content_client.h"
10 #include "jni/AwQuotaManagerBridge_jni.h"
11
12
13 namespace android_webview {
14
15 // static
16 jint getDefaultNativeAwQuotaManagerBridge(JNIEnv* env, jclass clazz) {
17 content::ContentBrowserClient* cbc = content::GetContentClient()->browser();
18 DCHECK(cbc);
19
20 AwContentBrowserClient* acbc =
21 AwContentBrowserClient::FromContentBrowserClient(cbc);
22 AwBrowserContext* browser_context = acbc->GetAwBrowserContext();
23 DCHECK(browser_context);
24
25 return reinterpret_cast<jint>(browser_context);
26 }
27
28 // static
29 AwQuotaManagerBridge* AwQuotaManagerBridge::Create(
30 AwBrowserContext* browser_context) {
31 return new AwQuotaManagerBridge(browser_context);
32 }
33
34 AwQuotaManagerBridge::AwQuotaManagerBridge(AwBrowserContext* browser_context)
35 : browser_context_(browser_context) {
36 }
37
38 void AwQuotaManagerBridge::Init(JNIEnv* env, jobject object) {
39 java_ref_ = JavaObjectWeakGlobalRef(env, object);
40 }
41
42 void AwQuotaManagerBridge::DeleteAllData(JNIEnv* env, jobject object) {
43 }
44
45 void AwQuotaManagerBridge::DeleteOrigin(
46 JNIEnv* env, jobject object, jobject origin) {
47 }
48
49 void AwQuotaManagerBridge::GetOrigins(
50 JNIEnv* env, jobject object, jint callback_id) {
51 }
52
53 void AwQuotaManagerBridge::GetQuotaForOrigin(
54 JNIEnv* env, jobject object, jobject origin, jint callback_id) {
55 }
56
57 void AwQuotaManagerBridge::GetUsageForOrigin(
58 JNIEnv* env, jobject object, jobject origin, jint callback_id) {
59 }
60
61 bool RegisterAwQuotaManagerBridge(JNIEnv* env) {
62 return RegisterNativesImpl(env) >= 0;
63 }
64
65 } // namespace android_webview
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698