Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 36a4f232 authored by Derek Sollenberger's avatar Derek Sollenberger
Browse files

Add full-screen support for OpenGL based plugins.

bug: 3321891
Change-Id: Ief8ef6d3c4b9ea535054b80b84df080567b9b163
parent cf7775a8
Loading
Loading
Loading
Loading
+9 −4
Original line number Diff line number Diff line
@@ -2577,10 +2577,7 @@ final class WebViewCore {
                .sendToTarget();
    }

    // called by JNI.  PluginWidget functions for creating an embedded View for
    // the surface drawing model.
    private ViewManager.ChildView addSurface(View pluginView, int x, int y,
                                             int width, int height) {
    private ViewManager.ChildView createSurface(View pluginView) {
        if (mWebView == null) {
            return null;
        }
@@ -2598,6 +2595,14 @@ final class WebViewCore {

        ViewManager.ChildView view = mWebView.mViewManager.createView();
        view.mView = pluginView;
        return view;
    }
    
    // called by JNI.  PluginWidget functions for creating an embedded View for
    // the surface drawing model.
    private ViewManager.ChildView addSurface(View pluginView, int x, int y,
                                             int width, int height) {
        ViewManager.ChildView view = createSurface(pluginView);
        view.attachView(x, y, width, height);
        return view;
    }