go-flutter icon indicating copy to clipboard operation
go-flutter copied to clipboard

Webview plug-in

Open SuperDan630 opened this issue 5 years ago • 6 comments

we can use js to replace when some widget no support , first we need webview!!

SuperDan630 avatar Dec 07 '19 07:12 SuperDan630

There are 2 ways.

Zserge lib Lorca lib.

Just Google for it on GitHub.

They have to open in a seperate window though. It might be possible to get zserge working inline but I don't know

joeblew99 avatar Dec 07 '19 15:12 joeblew99

In the same way a texture api is required to implement camera/video plug-in. There is a special Api to implement in the go-flutter source code to implement webview plug-in.

The first step towards supporting webview plug-in, is to adds support for FlutterCompositor. The you'll need to find a way to get pixel from the browser and send it to the engine.

Here is my honest opinion, go-flutter-desktop is a project supported by passionate people, and such plug-in demands a lot of initial work + maintenence. I really don't think we should add support for such feature we aren't Google.

pchampio avatar Dec 07 '19 18:12 pchampio

@pchampio thanks for the feedback. I was always wondering where compositing happens in Flutter !

winwisely99 avatar Dec 11 '19 08:12 winwisely99

Here is the golang lib that can open a Webview on all desktops. https://github.com/zserge/webview/tree/webview-x

The webview-x branch is a refactor designed to also use the Edge Webview, rather than the old Windows browser engine.

Rather than the complex compositing, i was thinking of at least trying to have it open in a separate window to at least have something working.

@pchampio Any idea how we can open a window without opening a new app ? SO that we dont get a new Icon in the app bar, etc

winwisely99 avatar Dec 11 '19 08:12 winwisely99

@pchampio Any idea how we can open a window without opening a new app ? SO that we dont get a new Icon in the app bar, etc

No, I don't know much, but I strongly recommend https://github.com/go-flutter-desktop/plugins/tree/master/url_launcher for a similar behavior.

pchampio avatar Dec 11 '19 08:12 pchampio

@pchampio thanks will try out the Url Launcher

winwisely99 avatar Dec 11 '19 08:12 winwisely99