OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "chrome/browser/android/preferences/website_preference_bridge.h" | 5 #include "chrome/browser/android/preferences/website_preference_bridge.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 29 matching lines...) Expand all Loading... |
40 #include "content/public/browser/browser_thread.h" | 40 #include "content/public/browser/browser_thread.h" |
41 #include "content/public/browser/storage_partition.h" | 41 #include "content/public/browser/storage_partition.h" |
42 #include "jni/WebsitePreferenceBridge_jni.h" | 42 #include "jni/WebsitePreferenceBridge_jni.h" |
43 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" | 43 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
44 #include "storage/browser/quota/quota_manager.h" | 44 #include "storage/browser/quota/quota_manager.h" |
45 #include "storage/common/quota/quota_status_code.h" | 45 #include "storage/common/quota/quota_status_code.h" |
46 #include "url/url_constants.h" | 46 #include "url/url_constants.h" |
47 | 47 |
48 using base::android::ConvertJavaStringToUTF8; | 48 using base::android::ConvertJavaStringToUTF8; |
49 using base::android::ConvertUTF8ToJavaString; | 49 using base::android::ConvertUTF8ToJavaString; |
| 50 using base::android::JavaParamRef; |
50 using base::android::JavaRef; | 51 using base::android::JavaRef; |
51 using base::android::ScopedJavaGlobalRef; | 52 using base::android::ScopedJavaGlobalRef; |
52 using base::android::ScopedJavaLocalRef; | 53 using base::android::ScopedJavaLocalRef; |
53 using content::BrowserThread; | 54 using content::BrowserThread; |
54 | 55 |
55 namespace { | 56 namespace { |
56 // We need to limit our size due to the algorithm in ImportantSiteUtil, but we | 57 // We need to limit our size due to the algorithm in ImportantSiteUtil, but we |
57 // want to be more on the liberal side here as we're not exposing these sites | 58 // want to be more on the liberal side here as we're not exposing these sites |
58 // to the user, we're just using them for our 'clear unimportant' feature in | 59 // to the user, we're just using them for our 'clear unimportant' feature in |
59 // ManageSpaceActivity.java. | 60 // ManageSpaceActivity.java. |
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
784 GURL url(ConvertJavaStringToUTF8(env, jorigin)); | 785 GURL url(ConvertJavaStringToUTF8(env, jorigin)); |
785 scoped_refptr<SiteDataDeleteHelper> site_data_deleter( | 786 scoped_refptr<SiteDataDeleteHelper> site_data_deleter( |
786 new SiteDataDeleteHelper(profile, url)); | 787 new SiteDataDeleteHelper(profile, url)); |
787 site_data_deleter->Run(); | 788 site_data_deleter->Run(); |
788 } | 789 } |
789 | 790 |
790 // Register native methods | 791 // Register native methods |
791 bool RegisterWebsitePreferenceBridge(JNIEnv* env) { | 792 bool RegisterWebsitePreferenceBridge(JNIEnv* env) { |
792 return RegisterNativesImpl(env); | 793 return RegisterNativesImpl(env); |
793 } | 794 } |
OLD | NEW |