如何在ListView onTap中设置Webview

时间:2019-06-06 14:51:55

标签: flutter

import 'package:flutter/material.dart';
import 'package:webview_flutter/webview_flutter.dart';

void main() => runApp(MaterialApp(
  home: Scaffold(
      appBar: new AppBar(
        title: new Text("Flutter"),

         ),
    body: list(),
  ),
));

Widget list() {

var listtt = ListView(     儿童:[       卡(         子代:ListTile(           领先:CircleAvatar(             backgroundImage:AssetImage(               'images / girl.jpg',             ),           ),           标题:Text(“ Abhsihek”),           副标题:文本(“测验布朗福克斯跳过懒狗。”),           onTap:(){             webview();

      },
    ))],);

返回listtt;}

 var webpage = WebView(
initialUrl: 'https://www.google.com',
javascriptMode: JavascriptMode.unrestricted,);

返回webview();}

0 个答案:

没有答案