简体   繁体   中英

How can I overlay floatingActionButton on WebviewScaffold

I try to Overlay a floatingActionButton on a Webview which is opened in a Widget.

"/widget": (_) => new WebviewScaffold(
          clearCache: true,
          clearCookies: true,
          withJavascript: false,
          url: selectedUrl,
          appBar: new AppBar(
            title: new Text("Widget webview"),                
          ),              
          withLocalStorage: true,
          /*floatingActionButton: new FloatingActionButton (
            backgroundColor: Colors.amber,
            onPressed: () {
              Navigator.of(context).push(new MaterialPageRoute(
                  builder: (BuildContext context) => new AddLinkPage()));
            },
            child: new Icon(
              Icons.add,
              color: Colors.black,
            ),
          ),*/
        )

This doesn't work.

It is possible with persistentFooterButtons: <Widget>[] , but then the view will be cut off

I use the flutter_webview_plugin: 0.1.5

That's not possible.

The WebView is an Android view shown as overlay and is therefore always the top-most content that is shown.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM