Commit b0ee2d07 authored by Cathy Li's avatar Cathy Li Committed by Commit Bot

[Xsurface]: Remove recyclerview reference, and add method to update renderer with template data

Change-Id: I9ed8eb54c6a172e23bfc6b2c4b1e800cad74ae9c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2099225
Commit-Queue: Cathy Li <chili@chromium.org>
Reviewed-by: default avatarJustin DeWitt <dewittj@chromium.org>
Cr-Commit-Position: refs/heads/master@{#749789}
parent 6775628e
......@@ -13,6 +13,5 @@ android_library("java") {
"android/java/src/org/chromium/chrome/browser/xsurface/SurfaceDependencyProvider.java",
"android/java/src/org/chromium/chrome/browser/xsurface/SurfaceRenderer.java",
]
deps =
[ "//third_party/android_deps:androidx_recyclerview_recyclerview_java" ]
deps = []
}
......@@ -4,15 +4,19 @@
package org.chromium.chrome.browser.xsurface;
import androidx.recyclerview.widget.RecyclerView;
import android.view.View;
/**
* A renderer that can handle mixing externally-provided views with native Android views
* in a RecyclerView.
*/
public interface HybridListRenderer {
/** Binds a RecyclerView and contentmanager with this renderer. */
void bind(RecyclerView view, ListContentManager manager);
/**
* Binds a contentmanager with this renderer.
* @return a View that the HybridListRenderer is managing, which can then be
* attached to other view
*/
View bind(ListContentManager manager);
/**
* Unbinds a previously attached recyclerview and contentmanager.
......@@ -20,4 +24,9 @@ public interface HybridListRenderer {
* Does nothing if nothing was previously bound.
*/
void unbind();
/**
* Updates the renderer with templates and initializing data.
*/
void update(byte[] data);
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment