summaryrefslogtreecommitdiffstats
path: root/android_webview
diff options
context:
space:
mode:
authoraurimas@chromium.org <aurimas@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-08-08 19:27:00 +0000
committeraurimas@chromium.org <aurimas@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-08-08 19:27:00 +0000
commita8aaede1647c6d40ec0ed275a800396a19136d2c (patch)
tree36a99a171982c434405f8abf1733a4b8b094e626 /android_webview
parent47e70d03bac8c0cbb3420183c0edb9ded20711b4 (diff)
downloadchromium_src-a8aaede1647c6d40ec0ed275a800396a19136d2c.zip
chromium_src-a8aaede1647c6d40ec0ed275a800396a19136d2c.tar.gz
chromium_src-a8aaede1647c6d40ec0ed275a800396a19136d2c.tar.bz2
[Checkstyle] Update static variable and constant names to match style guides.
- Static field names start with s. - static final fields (constants) are ALL_CAPS_WITH_UNDERSCORES. http://source.android.com/source/code-style.html#follow-field-naming-conventions BUG=318404 TBR=qinmin Review URL: https://codereview.chromium.org/455523002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@288416 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'android_webview')
-rw-r--r--android_webview/java/src/org/chromium/android_webview/AwResource.java24
-rw-r--r--android_webview/java/src/org/chromium/android_webview/permission/AwPermissionRequest.java2
-rw-r--r--android_webview/javatests/src/org/chromium/android_webview/test/AwContentsClientShouldInterceptRequestTest.java6
-rw-r--r--android_webview/javatests/src/org/chromium/android_webview/test/AwZoomTest.java2
-rw-r--r--android_webview/javatests/src/org/chromium/android_webview/test/MediaAccessPermissionRequestTest.java4
-rw-r--r--android_webview/javatests/src/org/chromium/android_webview/test/WebKitHitTestTest.java4
6 files changed, 21 insertions, 21 deletions
diff --git a/android_webview/java/src/org/chromium/android_webview/AwResource.java b/android_webview/java/src/org/chromium/android_webview/AwResource.java
index 3b3b326..b5c1a54 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwResource.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwResource.java
@@ -26,17 +26,17 @@ public class AwResource {
// Raw resource ID for an HTML page to be displayed in the case of
// a specific load error.
- private static int RAW_LOAD_ERROR;
+ private static int sRawLoadError;
// Raw resource ID for an HTML page to be displayed in the case of
// a generic load error. (It's called NO_DOMAIN for legacy reasons).
- private static int RAW_NO_DOMAIN;
+ private static int sRawNoDomain;
// String resource ID for the default text encoding to use.
- private static int STRING_DEFAULT_TEXT_ENCODING;
+ private static int sStringDefaultTextEncoding;
// Array resource ID for the configuration of platform specific key-systems.
- private static int STRING_ARRAY_CONFIG_KEY_SYSTEM_UUID_MAPPING;
+ private static int sStringArrayConfigKeySystemUUIDMapping;
// The embedder should inject a Resources object that will be used
// to resolve Resource IDs into the actual resources.
@@ -54,36 +54,36 @@ public class AwResource {
}
public static void setErrorPageResources(int loaderror, int nodomain) {
- RAW_LOAD_ERROR = loaderror;
- RAW_NO_DOMAIN = nodomain;
+ sRawLoadError = loaderror;
+ sRawNoDomain = nodomain;
}
public static void setDefaultTextEncoding(int encoding) {
- STRING_DEFAULT_TEXT_ENCODING = encoding;
+ sStringDefaultTextEncoding = encoding;
}
public static void setConfigKeySystemUuidMapping(int config) {
- STRING_ARRAY_CONFIG_KEY_SYSTEM_UUID_MAPPING = config;
+ sStringArrayConfigKeySystemUUIDMapping = config;
}
@CalledByNative
public static String getDefaultTextEncoding() {
- return getResource(STRING_DEFAULT_TEXT_ENCODING, TYPE_STRING);
+ return getResource(sStringDefaultTextEncoding, TYPE_STRING);
}
@CalledByNative
public static String getNoDomainPageContent() {
- return getResource(RAW_NO_DOMAIN, TYPE_RAW);
+ return getResource(sRawNoDomain, TYPE_RAW);
}
@CalledByNative
public static String getLoadErrorPageContent() {
- return getResource(RAW_LOAD_ERROR, TYPE_RAW);
+ return getResource(sRawLoadError, TYPE_RAW);
}
public static String[] getConfigKeySystemUuidMapping() {
// No need to cache, since this should be called only once.
- return sResources.getStringArray(STRING_ARRAY_CONFIG_KEY_SYSTEM_UUID_MAPPING);
+ return sResources.getStringArray(sStringArrayConfigKeySystemUUIDMapping);
}
private static String getResource(int resid, int type) {
diff --git a/android_webview/java/src/org/chromium/android_webview/permission/AwPermissionRequest.java b/android_webview/java/src/org/chromium/android_webview/permission/AwPermissionRequest.java
index c622b95..d0860f4 100644
--- a/android_webview/java/src/org/chromium/android_webview/permission/AwPermissionRequest.java
+++ b/android_webview/java/src/org/chromium/android_webview/permission/AwPermissionRequest.java
@@ -17,7 +17,7 @@ import org.chromium.base.ThreadUtils;
*/
@JNINamespace("android_webview")
public class AwPermissionRequest {
- private static String TAG = "AwPermissionRequest";
+ private static final String TAG = "AwPermissionRequest";
private Uri mOrigin;
private long mResources;
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/AwContentsClientShouldInterceptRequestTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/AwContentsClientShouldInterceptRequestTest.java
index 0402f4c..d83c96a 100644
--- a/android_webview/javatests/src/org/chromium/android_webview/test/AwContentsClientShouldInterceptRequestTest.java
+++ b/android_webview/javatests/src/org/chromium/android_webview/test/AwContentsClientShouldInterceptRequestTest.java
@@ -118,7 +118,7 @@ public class AwContentsClientShouldInterceptRequestTest extends AwTestBase {
}
private static final int TEAPOT_STATUS_CODE = 418;
- private static final String TEAPOD_RESPONSE_PHRASE = "I'm a teapot";
+ private static final String TEAPOT_RESPONSE_PHRASE = "I'm a teapot";
private String addPageToTestServer(TestWebServer webServer, String httpPath, String html) {
List<Pair<String, String>> headers = new ArrayList<Pair<String, String>>();
@@ -492,8 +492,8 @@ public class AwContentsClientShouldInterceptRequestTest extends AwTestBase {
mShouldInterceptRequestHelper.setReturnValue(
new AwWebResourceResponse("text/html", "UTF-8", new EmptyInputStream(),
- TEAPOT_STATUS_CODE, TEAPOD_RESPONSE_PHRASE, new HashMap<String, String>()));
- assertEquals("\"[" + TEAPOT_STATUS_CODE + "][" + TEAPOD_RESPONSE_PHRASE + "]\"",
+ TEAPOT_STATUS_CODE, TEAPOT_RESPONSE_PHRASE, new HashMap<String, String>()));
+ assertEquals("\"[" + TEAPOT_STATUS_CODE + "][" + TEAPOT_RESPONSE_PHRASE + "]\"",
executeJavaScriptAndWaitForResult(mAwContents, mContentsClient, syncGetJs));
}
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/AwZoomTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/AwZoomTest.java
index 1f5425e..0dbd497 100644
--- a/android_webview/javatests/src/org/chromium/android_webview/test/AwZoomTest.java
+++ b/android_webview/javatests/src/org/chromium/android_webview/test/AwZoomTest.java
@@ -24,7 +24,7 @@ import java.util.concurrent.Callable;
public class AwZoomTest extends AwTestBase {
private TestAwContentsClient mContentsClient;
private AwContents mAwContents;
- private static float MAXIMUM_SCALE = 2.0f;
+ private static final float MAXIMUM_SCALE = 2.0f;
@Override
public void setUp() throws Exception {
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/MediaAccessPermissionRequestTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/MediaAccessPermissionRequestTest.java
index 5fc6770..05c528d 100644
--- a/android_webview/javatests/src/org/chromium/android_webview/test/MediaAccessPermissionRequestTest.java
+++ b/android_webview/javatests/src/org/chromium/android_webview/test/MediaAccessPermissionRequestTest.java
@@ -32,7 +32,7 @@ public class MediaAccessPermissionRequestTest extends AwTestBase {
}
}
- private static final String mData = "<html> <script> " +
+ private static final String DATA = "<html> <script> " +
"var constraints = {audio: true, video: true};" +
"var video = document.querySelector('video');" +
"function successCallback(stream) {" +
@@ -59,7 +59,7 @@ public class MediaAccessPermissionRequestTest extends AwTestBase {
protected void setUp() throws Exception {
super.setUp();
mTestWebServer = new TestWebServer(false);
- mWebRTCPage = mTestWebServer.setResponse("/WebRTC", mData,
+ mWebRTCPage = mTestWebServer.setResponse("/WebRTC", DATA,
CommonResources.getTextHtmlHeaders(true));
}
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/WebKitHitTestTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/WebKitHitTestTest.java
index c91ed37..a7fda66 100644
--- a/android_webview/javatests/src/org/chromium/android_webview/test/WebKitHitTestTest.java
+++ b/android_webview/javatests/src/org/chromium/android_webview/test/WebKitHitTestTest.java
@@ -30,8 +30,8 @@ public class WebKitHitTestTest extends AwTestBase {
private AwContents mAwContents;
private TestWebServer mWebServer;
- private static String HREF = "http://foo/";
- private static String ANCHOR_TEXT = "anchor text";
+ private static final String HREF = "http://foo/";
+ private static final String ANCHOR_TEXT = "anchor text";
@Override
public void setUp() throws Exception {