54 lines
1.3 KiB
Dart
54 lines
1.3 KiB
Dart
import 'package:flutter/material.dart';
|
|
|
|
//好友列表 appbar 实现
|
|
|
|
class ContactAppBarPage extends StatelessWidget {
|
|
|
|
Color WechatThemeColor = Colors.white;
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return AppBar(
|
|
backgroundColor: WechatThemeColor,
|
|
title: Text('通讯录'), //标题
|
|
leading: //左按钮
|
|
GestureDetector(
|
|
child: Container(
|
|
margin: EdgeInsets.only(left: 15, top: 15),
|
|
child: Text(
|
|
'更多',
|
|
style: TextStyle(
|
|
fontSize: 20,
|
|
),
|
|
textAlign: TextAlign.center,
|
|
),
|
|
),
|
|
onTap: () {
|
|
Navigator.of(context)
|
|
.push(MaterialPageRoute(builder: (BuildContext context) {
|
|
return null;
|
|
}));
|
|
},
|
|
),
|
|
actions: <Widget>[
|
|
//右按钮
|
|
GestureDetector(
|
|
child: Container(
|
|
margin: EdgeInsets.only(right: 15),
|
|
child: Image(
|
|
image: AssetImage('images/icon_friends_add.png'),
|
|
width: 25,
|
|
),
|
|
),
|
|
onTap: () {
|
|
Navigator.of(context)
|
|
.push(MaterialPageRoute(builder: (BuildContext context) {
|
|
return null;
|
|
}));
|
|
},
|
|
),
|
|
],
|
|
);;
|
|
}
|
|
}
|