Don't use android.internal.R for resources.

We don't want to use framework internal resources in the WebView
APK.

Change-Id: Id3c8a89a73c40902442e871033b7277ae4601fe4
diff --git a/chromium/java/com/android/webview/chromium/WebViewChromiumFactoryProvider.java b/chromium/java/com/android/webview/chromium/WebViewChromiumFactoryProvider.java
index 8f0ebbd..d4ee715 100644
--- a/chromium/java/com/android/webview/chromium/WebViewChromiumFactoryProvider.java
+++ b/chromium/java/com/android/webview/chromium/WebViewChromiumFactoryProvider.java
@@ -264,10 +264,10 @@
 
     private void setUpResources(Context ctx) {
         AwResource.setResources(getWebViewPackageResources(ctx));
-        AwResource.setErrorPageResources(com.android.internal.R.raw.loaderror,
-                com.android.internal.R.raw.nodomain);
+        AwResource.setErrorPageResources(R.raw.webviewchromium_loaderror,
+                R.raw.webviewchromium_nodomain);
         AwResource.setDefaultTextEncoding(
-                com.android.internal.R.string.default_text_encoding);
+                R.string.webviewchromium_default_text_encoding);
         AwResource.setConfigKeySystemUuidMapping(
                 R.array.config_keySystemUuidMapping);
     }
diff --git a/chromium/res/raw/webviewchromium_loaderror.html b/chromium/res/raw/webviewchromium_loaderror.html
new file mode 100644
index 0000000..565e8e9
--- /dev/null
+++ b/chromium/res/raw/webviewchromium_loaderror.html
@@ -0,0 +1,19 @@
+<html>
+    <head>
+        <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"/>
+        <title>Webpage not available</title>
+        <style type="text/css">
+            body { margin-top: 0px; padding-top: 0px; }
+            h2   { margin-top: 5px; padding-top: 0px; }
+        </style>
+
+        <body>
+
+            <img src="file:///android_asset/webkit/android-weberror.png" align="top" />
+            <h2>Webpage not available</h2>
+            <p>The webpage at <a href="%s">%s</a> could not be loaded because:</p>
+            <!-- The %e is replaced by a localized error string -->
+            <p>%e</p>
+        </body>
+    </head>
+</html>
diff --git a/chromium/res/raw/webviewchromium_nodomain.html b/chromium/res/raw/webviewchromium_nodomain.html
new file mode 100644
index 0000000..d757483
--- /dev/null
+++ b/chromium/res/raw/webviewchromium_nodomain.html
@@ -0,0 +1,26 @@
+<html>
+    <head>
+        <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"/>
+        <title>Webpage not available</title>
+        <style type="text/css">
+            body { margin-top: 0px; padding-top: 0px; }
+            h2   { margin-top: 5px; padding-top: 0px; }
+        </style>
+
+        <body>
+
+            <img src="file:///android_asset/webkit/android-weberror.png" align="top" />
+            <h2>Webpage not available</h2>
+            <p>The webpage at <a href="%s">%s</a> might be
+            temporarily down or it may have moved permanently to a new web
+            address.</p>
+
+            <p><b>Suggestions:</b></p>
+            <ul>
+                <li>Make sure you have a data connection</li>
+                <li>Reload this webpage later</li>
+                <li>Check the address you entered</li>
+            </ul>
+        </body>
+    </head>
+</html>
diff --git a/chromium/res/values/strings.xml b/chromium/res/values/strings.xml
index bb42490..bc47002 100644
--- a/chromium/res/values/strings.xml
+++ b/chromium/res/values/strings.xml
@@ -9,4 +9,5 @@
     <!-- Contextual action bar item for sharing a block of text via email, or
          other method. [CHAR-LIMIT=24] -->
     <string name="webviewchromium_private_browsing_warning">This functionality is not supported in this version of Android.</string>
+    <string name="webviewchromium_default_text_encoding">UTF-8</string>
 </resources>