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

Side by Side Diff: android_webview/glue/java/src/com/android/webview/chromium/CookieManagerAdapter.java

Issue 1000793002: [Android] Incorporate findbugs into android builds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address cjhopman's comment + rebase Created 5 years, 9 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 package com.android.webview.chromium; 5 package com.android.webview.chromium;
6 6
7 import android.net.ParseException; 7 import android.net.ParseException;
8 import android.net.WebAddress; 8 import android.net.WebAddress;
9 import android.util.Log; 9 import android.util.Log;
10 import android.webkit.CookieManager; 10 import android.webkit.CookieManager;
11 import android.webkit.ValueCallback; 11 import android.webkit.ValueCallback;
12 import android.webkit.WebView; 12 import android.webkit.WebView;
13 13
14 import org.chromium.android_webview.AwCookieManager; 14 import org.chromium.android_webview.AwCookieManager;
15 import org.chromium.base.annotations.SuppressFBWarnings;
15 16
16 /** 17 /**
17 * Chromium implementation of CookieManager -- forwards calls to the 18 * Chromium implementation of CookieManager -- forwards calls to the
18 * chromium internal implementation. 19 * chromium internal implementation.
19 */ 20 */
20 @SuppressWarnings("deprecation") 21 @SuppressWarnings("deprecation")
22 @SuppressFBWarnings("CHROMIUM_SYNCHRONIZED_METHOD")
21 public class CookieManagerAdapter extends CookieManager { 23 public class CookieManagerAdapter extends CookieManager {
22 private static final String LOGTAG = "CookieManager"; 24 private static final String LOGTAG = "CookieManager";
23 25
24 AwCookieManager mChromeCookieManager; 26 AwCookieManager mChromeCookieManager;
25 27
26 public CookieManagerAdapter(AwCookieManager chromeCookieManager) { 28 public CookieManagerAdapter(AwCookieManager chromeCookieManager) {
27 mChromeCookieManager = chromeCookieManager; 29 mChromeCookieManager = chromeCookieManager;
28 } 30 }
29 31
30 @Override 32 @Override
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 } 144 }
143 145
144 private static String fixupUrl(String url) throws ParseException { 146 private static String fixupUrl(String url) throws ParseException {
145 // WebAddress is a private API in the android framework and a "quirk" 147 // WebAddress is a private API in the android framework and a "quirk"
146 // of the Classic WebView implementation that allowed embedders to 148 // of the Classic WebView implementation that allowed embedders to
147 // be relaxed about what URLs they passed into the CookieManager, so we 149 // be relaxed about what URLs they passed into the CookieManager, so we
148 // do the same normalisation before entering the chromium stack. 150 // do the same normalisation before entering the chromium stack.
149 return new WebAddress(url).toString(); 151 return new WebAddress(url).toString();
150 } 152 }
151 } 153 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698