summaryrefslogtreecommitdiffstats
path: root/android_webview/java/src/org
diff options
context:
space:
mode:
authorajith.v <ajith.v@samsung.com>2014-10-10 11:34:52 -0700
committerCommit bot <commit-bot@chromium.org>2014-10-10 18:35:03 +0000
commitb47e8a0b098e1a9d9b4ce15e8de78cc35af4c87f (patch)
tree21268919c6e2d6522dd33a441b61db6e8f03778b /android_webview/java/src/org
parent9a8e3d71f73ace82874d53ba2e749b1173a98513 (diff)
downloadchromium_src-b47e8a0b098e1a9d9b4ce15e8de78cc35af4c87f.zip
chromium_src-b47e8a0b098e1a9d9b4ce15e8de78cc35af4c87f.tar.gz
chromium_src-b47e8a0b098e1a9d9b4ce15e8de78cc35af4c87f.tar.bz2
Removing the CVC parameter from ShowRepostFormWarningDialog Callback.
With this we can reduce the dependency of CVC on AW module. Hence removing this unwanted parameter. BUG=398263 Review URL: https://codereview.chromium.org/646693003 Cr-Commit-Position: refs/heads/master@{#299147}
Diffstat (limited to 'android_webview/java/src/org')
-rw-r--r--android_webview/java/src/org/chromium/android_webview/AwContents.java4
-rw-r--r--android_webview/java/src/org/chromium/android_webview/AwWebContentsDelegateAdapter.java15
2 files changed, 9 insertions, 10 deletions
diff --git a/android_webview/java/src/org/chromium/android_webview/AwContents.java b/android_webview/java/src/org/chromium/android_webview/AwContents.java
index 49793690..d8a2eea 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwContents.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwContents.java
@@ -581,8 +581,8 @@ public class AwContents {
mDIPScale = DeviceDisplayInfo.create(mContext).getDIPScale();
mLayoutSizer.setDelegate(new AwLayoutSizerDelegate());
mLayoutSizer.setDIPScale(mDIPScale);
- mWebContentsDelegate = new AwWebContentsDelegateAdapter(
- contentsClient, mContainerView, mContext);
+ mWebContentsDelegate = new AwWebContentsDelegateAdapter(this, contentsClient,
+ mContainerView, mContext);
mContentsClientBridge = new AwContentsClientBridge(contentsClient,
mBrowserContext.getKeyStore(), AwContentsStatics.getClientCertLookupTable());
mZoomControls = new AwZoomControls(this);
diff --git a/android_webview/java/src/org/chromium/android_webview/AwWebContentsDelegateAdapter.java b/android_webview/java/src/org/chromium/android_webview/AwWebContentsDelegateAdapter.java
index 1746eb0..2d8b633 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwWebContentsDelegateAdapter.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwWebContentsDelegateAdapter.java
@@ -20,7 +20,6 @@ import android.webkit.ValueCallback;
import org.chromium.base.ContentUriUtils;
import org.chromium.base.ThreadUtils;
import org.chromium.content.browser.ContentVideoView;
-import org.chromium.content.browser.ContentViewCore;
/**
* Adapts the AwWebContentsDelegate interface to the AwContentsClient interface.
@@ -30,12 +29,14 @@ import org.chromium.content.browser.ContentViewCore;
class AwWebContentsDelegateAdapter extends AwWebContentsDelegate {
private static final String TAG = "AwWebContentsDelegateAdapter";
+ final AwContents mAwContents;
final AwContentsClient mContentsClient;
View mContainerView;
final Context mContext;
- public AwWebContentsDelegateAdapter(AwContentsClient contentsClient,
+ public AwWebContentsDelegateAdapter(AwContents awContents, AwContentsClient contentsClient,
View containerView, Context context) {
+ mAwContents = awContents;
mContentsClient = contentsClient;
setContainerView(containerView);
mContext = context;
@@ -135,7 +136,7 @@ class AwWebContentsDelegateAdapter extends AwWebContentsDelegate {
}
@Override
- public void showRepostFormWarningDialog(final ContentViewCore contentViewCore) {
+ public void showRepostFormWarningDialog() {
// TODO(mkosiba) We should be using something akin to the JsResultReceiver as the
// callback parameter (instead of ContentViewCore) and implement a way of converting
// that to a pair of messages.
@@ -147,17 +148,15 @@ class AwWebContentsDelegateAdapter extends AwWebContentsDelegate {
final Handler handler = new Handler(ThreadUtils.getUiThreadLooper()) {
@Override
public void handleMessage(Message msg) {
- if (contentViewCore.getWebContents() == null) return;
+ if (mAwContents.getNavigationController() == null) return;
switch(msg.what) {
case msgContinuePendingReload: {
- contentViewCore.getWebContents().getNavigationController()
- .continuePendingReload();
+ mAwContents.getNavigationController().continuePendingReload();
break;
}
case msgCancelPendingReload: {
- contentViewCore.getWebContents().getNavigationController()
- .cancelPendingReload();
+ mAwContents.getNavigationController().cancelPendingReload();
break;
}
default: