Commit ea830701 authored by 杜欣's avatar 杜欣

样式修改

parent af056532
import 'package:flutter/widgets.dart';
import 'package:gmalpha_flutter/NewMessageModel/NewMessageRouter.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/MessagePage.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/AttentionPage.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/focusPage/FocusPage.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/likePage/LikePage.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/messagePage/MessagePage.dart';
class NewMessageRouterImpl implements NewMessageRouter {
@override
......
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/MessageModel.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/common.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/messagePage/MessageModel.dart';
import 'package:gmalpha_flutter/NewMessageModel/page/messagePage/common.dart';
import 'package:gmalpha_flutter/NewMessageModel/service/remote/entity/LatestMessageEntity.dart';
import 'package:gmalpha_flutter/NewMessageModel/service/remote/entity/MyMessageEntity.dart';
import 'package:gmalpha_flutter/NewMessageModel/service/remote/entity/UnreadMessageEntity.dart';
......@@ -86,13 +86,13 @@ class _MessagePageState extends BasePage<MessagePage> {
valueColor: AlwaysStoppedAnimation(ALColors.Color999999),
strokeWidth: 2
),
width: ScreenUtil().setWidth(16),
height: ScreenUtil().setHeight(16)
width: ScreenUtil.instance.setWidth(16),
height: ScreenUtil.instance.setHeight(16)
)
);
return _pad(
Row(
children: <Widget>[loadingIndicator, _pad(Text(body, style: loadingTS), l: ScreenUtil().setWidth(10))],
children: <Widget>[loadingIndicator, _pad(Text(body, style: loadingTS), l: ScreenUtil.instance.setWidth(10))],
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
),
......@@ -201,14 +201,14 @@ class _MessagePageState extends BasePage<MessagePage> {
},
),
Container(
margin: EdgeInsets.only(left: ScreenUtil().setWidth(16), right: ScreenUtil().setWidth(16), bottom: ScreenUtil().setHeight(24)),
height: ScreenUtil().setHeight(12),
margin: EdgeInsets.only(left: ScreenUtil.instance.setWidth(16), right: ScreenUtil.instance.setWidth(16), bottom: ScreenUtil().setHeight(24)),
height: ScreenUtil.instance.setHeight(12),
decoration: BoxDecoration(
color: ALColors.ColorFFFFFF,
border: Border(
bottom: BorderSide(
color: Color(0xfffE4E4E4),
width: ScreenUtil().setWidth(1),
width: ScreenUtil.instance.setWidth(1),
style: BorderStyle.solid
)
)
......
......@@ -13,7 +13,7 @@ messageTitle(String text) {
color: ALColors.Color323232, fontSize: ScreenUtil().setSp(20)));
}
var width = ScreenUtil().setWidth(16);
var width = ScreenUtil.instance.setWidth(16);
Widget messageTop(imgUrl, title, content, count) {
var height = ScreenUtil().setHeight(12);
......@@ -23,9 +23,9 @@ Widget messageTop(imgUrl, title, content, count) {
child: Stack(
children: <Widget>[
Container(
padding: EdgeInsets.only(left: ScreenUtil().setWidth(28)),
padding: EdgeInsets.only(left: ScreenUtil.instance.setWidth(28)),
margin: EdgeInsets.only(
left: ScreenUtil().setWidth(4), top: height, bottom: height),
left: ScreenUtil.instance.setWidth(4), top: height, bottom: height),
width: double.infinity,
decoration: BoxDecoration(
color: ALColors.ColorFFFFFF,
......@@ -40,10 +40,10 @@ Widget messageTop(imgUrl, title, content, count) {
fontSize: ScreenUtil().setSp(13),
fontWeight: FontWeight.bold)),
SizedBox(
width: ScreenUtil().setWidth(16),
width: ScreenUtil.instance.setWidth(16),
),
Container(
width: ScreenUtil().setWidth(200),
width: ScreenUtil.instance.setWidth(200),
child: Text(content,
style: TextStyle(
color: ALColors.Color8E8E8E,
......@@ -55,8 +55,8 @@ Widget messageTop(imgUrl, title, content, count) {
),
getNum(count),
Positioned(
right: ScreenUtil().setWidth(14),
top: ScreenUtil().setHeight(12),
right: ScreenUtil.instance.setWidth(14),
top: ScreenUtil.instance.setHeight(12),
child: Hero(
tag: "arrow_right",
child: SvgPicture.asset(
......@@ -71,14 +71,14 @@ Widget messageTop(imgUrl, title, content, count) {
Widget getNum([int count]) {
if (count > 0) {
return Positioned(
right: 0,
top: ScreenUtil().setHeight(12),
right: ScreenUtil.instance.setWidth(30),
top: ScreenUtil.instance.setHeight(12),
child: Container(
padding: EdgeInsets.only(
top: ScreenUtil().setHeight(2),
bottom: ScreenUtil().setHeight(2),
left: ScreenUtil().setWidth(7),
right: ScreenUtil().setWidth(7)),
top: ScreenUtil.instance.setHeight(2),
bottom: ScreenUtil.instance.setHeight(2),
left: ScreenUtil.instance.setWidth(7),
right: ScreenUtil.instance.setWidth(7)),
decoration: BoxDecoration(
color: ALColors.Color323232,
borderRadius: BorderRadius.circular(22.0)),
......@@ -125,7 +125,7 @@ Widget messageList(Data list) {
};
return Container(
padding: EdgeInsets.only(left: width, right: width),
margin: EdgeInsets.only(bottom: ScreenUtil().setHeight(25)),
margin: EdgeInsets.only(bottom: ScreenUtil.instance.setHeight(25)),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
......@@ -149,7 +149,7 @@ Widget messageList(Data list) {
shape: BoxShape.circle,
image: DecorationImage(
image: NetworkImage(list.icon))))),
SizedBox(width: ScreenUtil().setWidth(10)),
SizedBox(width: ScreenUtil.instance.setWidth(10)),
GestureDetector(
onTap: () {
onClickButton('comment');
......@@ -174,7 +174,7 @@ Widget messageList(Data list) {
color: ALColors.Color323232,
fontSize: ScreenUtil().setSp(13),
fontWeight: FontWeight.bold)),
SizedBox(width: ScreenUtil().setWidth(10)),
SizedBox(width: ScreenUtil.instance.setWidth(10)),
Text(
content[list.repliedContent?.type]
['showText'],
......@@ -184,7 +184,7 @@ Widget messageList(Data list) {
],
),
Container(
width: ScreenUtil().setWidth(210),
width: ScreenUtil.instance.setWidth(210),
child: Text(list.content,
style: TextStyle(
color: ALColors.Color323232,
......@@ -210,7 +210,7 @@ Widget messageList(Data list) {
},
child: Image.network(
list.repliedContent.content,
width: ScreenUtil().setWidth(48),
width: ScreenUtil.instance.setWidth(48),
fit: BoxFit.fill,
))
],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment