@@ -420,32 +420,38 @@ class _ChatPageState extends State<ChatPage> { | |||||
child: Image.asset(R.assetsImagesDefaultNorAvatar))), | child: Image.asset(R.assetsImagesDefaultNorAvatar))), | ||||
Padding( | Padding( | ||||
padding: EdgeInsets.only(left: 10), | padding: EdgeInsets.only(left: 10), | ||||
child: Column( | |||||
child: Container(child: Column( | |||||
crossAxisAlignment: CrossAxisAlignment.start, | |||||
children: <Widget>[ | children: <Widget>[ | ||||
Text( | Text( | ||||
I18n.of(context).translation_butler, | |||||
I18n.of(context).translation_butler , | |||||
textScaleFactor: 1.0, | textScaleFactor: 1.0, | ||||
overflow: TextOverflow.ellipsis, | |||||
maxLines: 1, | |||||
style: TextStyle( | style: TextStyle( | ||||
color: AppColors.NewAppbarTextColor, fontSize: 15), | color: AppColors.NewAppbarTextColor, fontSize: 15), | ||||
), | ), | ||||
SizedBox(height: 5,), | |||||
Text( | Text( | ||||
coinTIme, | coinTIme, | ||||
textScaleFactor: 1.0, | textScaleFactor: 1.0, | ||||
maxLines: 1, | |||||
style: TextStyle( | style: TextStyle( | ||||
color: AppColors.NewAppbarTextColor, fontSize: 13), | |||||
color: Color(0xFF797979), fontSize: 13), | |||||
) | ) | ||||
], | ], | ||||
), | |||||
),constraints:BoxConstraints(maxWidth: 135),), | |||||
), | ), | ||||
Expanded( | Expanded( | ||||
child: Container( | child: Container( | ||||
constraints:BoxConstraints(maxWidth: 130), | |||||
width: double.maxFinite, | width: double.maxFinite, | ||||
child: CountDownButton( | child: CountDownButton( | ||||
I18n.of(context).translation_butler_end_service, | I18n.of(context).translation_butler_end_service, | ||||
() { | () { | ||||
Navigator.of(context).pop(); | Navigator.of(context).pop(); | ||||
}, | }, | ||||
countDownTime: 60, | |||||
countDownTime: 360, | |||||
align: Alignment.centerRight, | align: Alignment.centerRight, | ||||
onPress: () {}, | onPress: () {}, | ||||
), | ), | ||||
@@ -505,7 +511,7 @@ class _ChatPageState extends State<ChatPage> { | |||||
child: Text( | child: Text( | ||||
I18n.of(context).translation_butler_evaluation, | I18n.of(context).translation_butler_evaluation, | ||||
textScaleFactor: 1.0, | textScaleFactor: 1.0, | ||||
style: TextStyle(color: Colors.white, fontSize: 19), | |||||
style: TextStyle(color: Colors.white, fontSize: 15), | |||||
), | ), | ||||
onPressed: () { | onPressed: () { | ||||
CustomUI.buildTranslationEvaluationDialog(context); | CustomUI.buildTranslationEvaluationDialog(context); | ||||
@@ -30,6 +30,7 @@ import 'package:shared_preferences/shared_preferences.dart'; | |||||
import 'package:chat/utils/my_bottom_navigation_bar.dart' as myBottm; | import 'package:chat/utils/my_bottom_navigation_bar.dart' as myBottm; | ||||
import 'friend_page.dart'; | import 'friend_page.dart'; | ||||
import 'group_chat_page.dart'; | |||||
class NavigationIconView { | class NavigationIconView { | ||||
final BottomNavigationBarItem item; | final BottomNavigationBarItem item; | ||||
@@ -310,22 +311,87 @@ class _HomeMainState extends State<HomeMain> { | |||||
I18n.of(context).me | I18n.of(context).me | ||||
]; | ]; | ||||
// _navigationViews = [ | |||||
// NavigationIconView( | |||||
// title: _titles[2], | |||||
// icon: IconData( | |||||
// 0xe67c, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// isShowdot: true, | |||||
// iconSize: 29), | |||||
// NavigationIconView( | |||||
// title: _titles[0], | |||||
// isShowdot: true, | |||||
// iconMargin: EdgeInsets.only(top: 2), | |||||
// type: 5, | |||||
// icon: IconData( | |||||
// 0xe66e, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// iconSize: 26.5), | |||||
// NavigationIconView( | |||||
// title: _titles[1], | |||||
// icon: IconData( | |||||
// 0xe656, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// isCenter: true, | |||||
// iconSize: 31), | |||||
// NavigationIconView( | |||||
// title: _titles[1], | |||||
// isShowdot: true, | |||||
// icon: IconData( | |||||
// 0xe60b, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// type: 6, | |||||
// iconSize: 26.5), | |||||
// NavigationIconView( | |||||
// title: _titles[3], | |||||
// icon: IconData( | |||||
// 0xe67b, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// iconSize: 26.5), | |||||
// ]; | |||||
// | |||||
// _pages = [ | |||||
// RealTimeHelperPage(), | |||||
// FriendPage(), | |||||
// FindPage(), | |||||
// ConversActionPage(), | |||||
//// GroupChatListPage(), | |||||
// ProfilePage( | |||||
// userId: UserData().basicInfo.userId, | |||||
// ), | |||||
// ]; | |||||
_navigationViews = [ | _navigationViews = [ | ||||
// NavigationIconView( | |||||
// title: _titles[2], | |||||
// icon: IconData( | |||||
// 0xe67c, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// isShowdot: true, | |||||
// iconSize: 29), | |||||
NavigationIconView( | NavigationIconView( | ||||
title: _titles[2], | |||||
title: _titles[1], | |||||
isShowdot: true, | |||||
icon: IconData( | icon: IconData( | ||||
0xe67c, | |||||
0xe60b, | |||||
fontFamily: 'iconfont', | fontFamily: 'iconfont', | ||||
), | ), | ||||
isShowdot: true, | |||||
iconSize: 29), | |||||
type: 1, | |||||
iconSize: 26.5), | |||||
NavigationIconView( | NavigationIconView( | ||||
title: _titles[0], | title: _titles[0], | ||||
isShowdot: true, | isShowdot: true, | ||||
iconMargin: EdgeInsets.only(top: 2), | iconMargin: EdgeInsets.only(top: 2), | ||||
type: 5, | type: 5, | ||||
icon: IconData( | icon: IconData( | ||||
0xe66e, | |||||
0xe663, | |||||
fontFamily: 'iconfont', | fontFamily: 'iconfont', | ||||
), | ), | ||||
iconSize: 26.5), | iconSize: 26.5), | ||||
@@ -337,15 +403,25 @@ class _HomeMainState extends State<HomeMain> { | |||||
), | ), | ||||
isCenter: true, | isCenter: true, | ||||
iconSize: 31), | iconSize: 31), | ||||
// NavigationIconView( | |||||
// title: _titles[1], | |||||
// isShowdot: true, | |||||
// icon: IconData( | |||||
// 0xe60b, | |||||
// fontFamily: 'iconfont', | |||||
// ), | |||||
// type: 6, | |||||
// iconSize: 26.5), | |||||
NavigationIconView( | NavigationIconView( | ||||
title: _titles[1], | |||||
isShowdot: true, | |||||
title: _titles[3], | |||||
icon: IconData( | icon: IconData( | ||||
0xe60b, | |||||
0xe66e, | |||||
fontFamily: 'iconfont', | fontFamily: 'iconfont', | ||||
), | ), | ||||
type: 6, | |||||
type: 4, | |||||
iconSize: 26.5), | iconSize: 26.5), | ||||
NavigationIconView( | NavigationIconView( | ||||
title: _titles[3], | title: _titles[3], | ||||
icon: IconData( | icon: IconData( | ||||
@@ -356,15 +432,18 @@ class _HomeMainState extends State<HomeMain> { | |||||
]; | ]; | ||||
_pages = [ | _pages = [ | ||||
RealTimeHelperPage(), | |||||
ConversActionPage(), | |||||
// RealTimeHelperPage(), | |||||
FriendPage(), | FriendPage(), | ||||
FindPage(), | FindPage(), | ||||
ConversActionPage(), | |||||
// GroupChatListPage(), | |||||
// ConversActionPage(), | |||||
GroupChatListPage(), | |||||
ProfilePage( | ProfilePage( | ||||
userId: UserData().basicInfo.userId, | userId: UserData().basicInfo.userId, | ||||
), | ), | ||||
]; | ]; | ||||
} | } | ||||
@override | @override | ||||
@@ -63,30 +63,24 @@ class TranslationButlerPageState extends State<TranslationButlerPage> { | |||||
initData(); | initData(); | ||||
focusNode.addListener((){ | |||||
if(focusNode.hasFocus){ | |||||
} | |||||
}); | |||||
WidgetsBinding.instance.addPostFrameCallback((_) { | WidgetsBinding.instance.addPostFrameCallback((_) { | ||||
Future.delayed(Duration(seconds: 4), () { | |||||
// CustomUI.buildTranslationHelperOrderDialog(context); | |||||
Navigator.of(context).push( | |||||
new MaterialPageRoute( | |||||
builder: (context) { | |||||
return ChatPage( | |||||
key: Key('Chat'), | |||||
friendId: 100006, | |||||
isTranslateButler: true, | |||||
); | |||||
}, | |||||
), | |||||
); | |||||
}); | |||||
// Future.delayed(Duration(seconds: 4), () { | |||||
//// CustomUI.buildTranslationHelperOrderDialog(context); | |||||
// Navigator.of(context).push( | |||||
// new MaterialPageRoute( | |||||
// builder: (context) { | |||||
// return ChatPage( | |||||
// key: Key('Chat'), | |||||
// friendId: 100006, | |||||
// isTranslateButler: true, | |||||
// ); | |||||
// }, | |||||
// ), | |||||
// ); | |||||
// }); | |||||
@@ -145,7 +139,6 @@ class TranslationButlerPageState extends State<TranslationButlerPage> { | |||||
@override | @override | ||||
void dispose() { | void dispose() { | ||||
// MessageMgr().off('Update Group Info', updateGroupInfo); | |||||
timer?.cancel(); | timer?.cancel(); | ||||
if (!isApply && timeStamp != null) { | if (!isApply && timeStamp != null) { | ||||
@@ -45,7 +45,7 @@ class HttpUtil { | |||||
//static const String BaseUrl = 'http://192.168.0.207:9080/'; | //static const String BaseUrl = 'http://192.168.0.207:9080/'; | ||||
static const String BaseUrl = 'http://120.79.107.63:9080/'; | static const String BaseUrl = 'http://120.79.107.63:9080/'; | ||||
//static const String BaseUrl = 'http://192.168.0.177:9016/'; | //static const String BaseUrl = 'http://192.168.0.177:9016/'; | ||||
//static const String BaseUrl = 'https://datasm.chengyouhd.com/'; | |||||
// static const String BaseUrl = 'https://datasm.chengyouhd.com/'; | |||||
static HttpUtil _getInstance() { | static HttpUtil _getInstance() { | ||||
if (_instance == null) { | if (_instance == null) { | ||||
@@ -460,7 +460,7 @@ class MsgHandler { | |||||
chat.contentBuff, chat.sendTime.toInt(), chat.targetId, | chat.contentBuff, chat.sendTime.toInt(), chat.targetId, | ||||
channelType: chat.channelType.value); | channelType: chat.channelType.value); | ||||
// String content =utf8.decode(msgModel.msgContent); | |||||
// String content =utf8.decode(msgModel.msgContent); | |||||
// print('当前收到消息条数$receivedCount $content'); | // print('当前收到消息条数$receivedCount $content'); | ||||
if (chat.hasTencentTranslate()) { | if (chat.hasTencentTranslate()) { | ||||