Change api for webview overscroll background.
diff --git a/api/current.xml b/api/current.xml
index 8d2dbb1..9dc2218 100644
--- a/api/current.xml
+++ b/api/current.xml
@@ -193735,7 +193735,7 @@
visibility="public"
>
</method>
-<method name="getUseSystemOverscrollBackground"
+<method name="getUseWebViewBackgroundForOverscrollBackground"
return="boolean"
abstract="false"
native="false"
@@ -194325,7 +194325,7 @@
<parameter name="use" type="boolean">
</parameter>
</method>
-<method name="setUseSystemOverscrollBackground"
+<method name="setUseWebViewBackgroundForOverscrollBackground"
return="void"
abstract="false"
native="false"
@@ -194335,7 +194335,7 @@
deprecated="not deprecated"
visibility="public"
>
-<parameter name="system" type="boolean">
+<parameter name="view" type="boolean">
</parameter>
</method>
<method name="setUseWideViewPort"
diff --git a/core/java/android/webkit/WebSettings.java b/core/java/android/webkit/WebSettings.java
index fb15f78..d1da5ea 100644
--- a/core/java/android/webkit/WebSettings.java
+++ b/core/java/android/webkit/WebSettings.java
@@ -192,7 +192,7 @@
private boolean mBuiltInZoomControls = false;
private boolean mAllowFileAccess = true;
private boolean mLoadWithOverviewMode = false;
- private boolean mUseSystemOverscrollBackground = false;
+ private boolean mUseWebViewBackgroundOverscrollBackground = true;
// private WebSettings, not accessible by the host activity
static private int mDoubleTapToastCount = 3;
@@ -471,20 +471,20 @@
}
/**
- * Set whether the WebView uses system background for over scroll
- * background. If false, it will use the WebView's background. Default is
- * false.
+ * Set whether the WebView uses its background for over scroll background.
+ * If true, it will use the WebView's background. If false, it will use an
+ * internal pattern. Default is true.
*/
- public void setUseSystemOverscrollBackground(boolean system) {
- mUseSystemOverscrollBackground = system;
+ public void setUseWebViewBackgroundForOverscrollBackground(boolean view) {
+ mUseWebViewBackgroundOverscrollBackground = view;
}
/**
- * Returns true if this WebView uses system background instead of WebView
- * background for over scroll background.
+ * Returns true if this WebView uses WebView's background instead of
+ * internal pattern for over scroll background.
*/
- public boolean getUseSystemOverscrollBackground() {
- return mUseSystemOverscrollBackground;
+ public boolean getUseWebViewBackgroundForOverscrollBackground() {
+ return mUseWebViewBackgroundOverscrollBackground;
}
/**
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java
index 1becf9e..8f7bf8d 100644
--- a/core/java/android/webkit/WebView.java
+++ b/core/java/android/webkit/WebView.java
@@ -3120,8 +3120,8 @@
}
int saveCount = canvas.save();
- if (mInOverScrollMode
- && getSettings().getUseSystemOverscrollBackground()) {
+ if (mInOverScrollMode && !getSettings()
+ .getUseWebViewBackgroundForOverscrollBackground()) {
if (mOverScrollBackground == null) {
mOverScrollBackground = new Paint();
Bitmap bm = BitmapFactory.decodeResource(