Example usage for com.facebook.react.uimanager.events ContentSizeChangeEvent ContentSizeChangeEvent

List of usage examples for com.facebook.react.uimanager.events ContentSizeChangeEvent ContentSizeChangeEvent

Introduction

In this page you can find the example usage for com.facebook.react.uimanager.events ContentSizeChangeEvent ContentSizeChangeEvent.

Prototype

public ContentSizeChangeEvent(int viewTag, int width, int height) 

Source Link

Usage

From source file:com.blockablewebview.BlockableWebViewManager.java

License:Open Source License

private WebView.PictureListener getPictureListener() {
    if (mPictureListener == null) {
        mPictureListener = new WebView.PictureListener() {
            @Override/*from w  w w .  j a v a 2 s .co  m*/
            public void onNewPicture(WebView webView, Picture picture) {
                dispatchEvent(webView, new ContentSizeChangeEvent(webView.getId(), webView.getWidth(),
                        webView.getContentHeight()));
            }
        };
    }
    return mPictureListener;
}