diff options
author | igsolla <igsolla@chromium.org> | 2015-02-09 08:28:07 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-02-09 16:28:40 +0000 |
commit | 709e3c43d4287c5ae632b6614a1d3747fe21b47b (patch) | |
tree | d29877de11ff4f96296e10581ca8cf5fcd8610e2 /android_webview/native | |
parent | 9dcc040173f2e0967569754fde74b21e1c71480c (diff) | |
download | chromium_src-709e3c43d4287c5ae632b6614a1d3747fe21b47b.zip chromium_src-709e3c43d4287c5ae632b6614a1d3747fe21b47b.tar.gz chromium_src-709e3c43d4287c5ae632b6614a1d3747fe21b47b.tar.bz2 |
Revert of [WebView] Add unique visual state request ids. (patchset #4 id:60001 of https://codereview.chromium.org/900303002/)
Reason for revert:
This is breaking some bots, see for example:
https://chromegw.corp.google.com/i/chromium.linux/builders/Android%20Arm64%20Builder%20(dbg)/builds/8923
https://chromegw.corp.google.com/i/chromium.linux/builders/Android%20Builder%20(dbg)/builds/73663
The reason is:
M D ST: Write to static field org.chromium.android_webview.AwContents.sNextVisualStateRequestId from instance method org.chromium.android_webview.AwContents.flushVisualState(AwContents$VisualStateFlushCallback) At AwContents.java
Original issue's description:
> [WebView] Add unique visual state request ids.
>
> Each flushVisualState request returns a unique id
> that allows callers to match requests with callbacks.
> The reasoning behind is to potentially allow clients
> to reuse VisualStateFlushCallback objects to avoid
> additional java allocations.
>
> BUG=455651
>
> Committed: https://crrev.com/d011b93e7c8f966ba068b0c77c8a1400bdedee88
> Cr-Commit-Position: refs/heads/master@{#315304}
TBR=boliu@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=455651
Review URL: https://codereview.chromium.org/907723004
Cr-Commit-Position: refs/heads/master@{#315321}
Diffstat (limited to 'android_webview/native')
-rw-r--r-- | android_webview/native/aw_contents.cc | 15 | ||||
-rw-r--r-- | android_webview/native/aw_contents.h | 5 |
2 files changed, 6 insertions, 14 deletions
diff --git a/android_webview/native/aw_contents.cc b/android_webview/native/aw_contents.cc index 5c2b319..6c468f6 100644 --- a/android_webview/native/aw_contents.cc +++ b/android_webview/native/aw_contents.cc @@ -1037,27 +1037,22 @@ void AwContents::EnableOnNewPicture(JNIEnv* env, namespace { void FlushVisualStateCallback(const JavaObjectWeakGlobalRef& java_ref, ScopedJavaGlobalRef<jobject>* callback, - int64 request_id, bool result) { JNIEnv* env = AttachCurrentThread(); ScopedJavaLocalRef<jobject> obj = java_ref.get(env); if (obj.is_null()) return; - Java_AwContents_flushVisualStateCallback(env, obj.obj(), callback->obj(), - request_id, result); + Java_AwContents_flushVisualStateCallback( + env, obj.obj(), callback->obj(), result); } } // namespace -void AwContents::FlushVisualState(JNIEnv* env, - jobject obj, - jobject callback, - int64 request_id) { +void AwContents::FlushVisualState(JNIEnv* env, jobject obj, jobject callback) { DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); ScopedJavaGlobalRef<jobject>* j_callback = new ScopedJavaGlobalRef<jobject>(); j_callback->Reset(env, callback); - web_contents_->GetMainFrame()->FlushVisualState( - base::Bind(&FlushVisualStateCallback, java_ref_, base::Owned(j_callback), - request_id)); + web_contents_->GetMainFrame()->FlushVisualState(base::Bind( + &FlushVisualStateCallback, java_ref_, base::Owned(j_callback))); } void AwContents::ClearView(JNIEnv* env, jobject obj) { diff --git a/android_webview/native/aw_contents.h b/android_webview/native/aw_contents.h index d02c39a..077690f 100644 --- a/android_webview/native/aw_contents.h +++ b/android_webview/native/aw_contents.h @@ -129,10 +129,7 @@ class AwContents : public FindHelper::Listener, jlong GetAwDrawGLViewContext(JNIEnv* env, jobject obj); jlong CapturePicture(JNIEnv* env, jobject obj, int width, int height); void EnableOnNewPicture(JNIEnv* env, jobject obj, jboolean enabled); - void FlushVisualState(JNIEnv* env, - jobject obj, - jobject callback, - int64 request_id); + void FlushVisualState(JNIEnv* env, jobject obj, jobject callback); void ClearView(JNIEnv* env, jobject obj); void SetExtraHeadersForUrl(JNIEnv* env, jobject obj, jstring url, jstring extra_headers); |