背景图闪烁优化
This commit is contained in:
parent
3d8c3f9cc3
commit
5517eca5f6
@ -72,63 +72,58 @@ class _CirclePageState extends State<CirclePage>
|
|||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
getContext = context;
|
getContext = context;
|
||||||
return GetBuilder<CircleLogic>(builder: (logic) {
|
return GetBuilder<CircleLogic>(builder: (logic) {
|
||||||
return Container(
|
return Scaffold(
|
||||||
width: MediaQuery.of(context).size.width,
|
backgroundColor: Colors.transparent,
|
||||||
height: MediaQuery.of(context).size.height,
|
body: SafeArea(
|
||||||
decoration:
|
child: GetBuilder(builder: (CircleLogic controller) {
|
||||||
const BoxDecoration(color: Color(0xFF423055), image: bgWidget),
|
return Stack(
|
||||||
child: Scaffold(
|
children: [
|
||||||
backgroundColor: Colors.transparent,
|
Column(children: [
|
||||||
body: SafeArea(
|
Obx(() {
|
||||||
child: GetBuilder(builder: (CircleLogic controller) {
|
return navigatorItem(controller.statistics.value);
|
||||||
return Stack(
|
}),
|
||||||
children: [
|
// Text(controller.state.msg),
|
||||||
Column(children: [
|
//组件使用
|
||||||
Obx(() {
|
]),
|
||||||
return navigatorItem(controller.statistics.value);
|
Container(
|
||||||
}),
|
margin: EdgeInsets.only(top: 45.sp),
|
||||||
// Text(controller.state.msg),
|
child: PageView(
|
||||||
//组件使用
|
controller: _pageController,
|
||||||
]),
|
onPageChanged: (index) {
|
||||||
Container(
|
_tabController.animateTo(index);
|
||||||
margin: EdgeInsets.only(top: 45.sp),
|
print("index=" + index.toString());
|
||||||
child: PageView(
|
},
|
||||||
controller: _pageController,
|
children: [
|
||||||
onPageChanged: (index) {
|
circleList(controller),
|
||||||
_tabController.animateTo(index);
|
vicinityList(controller),
|
||||||
print("index=" + index.toString());
|
],
|
||||||
},
|
),
|
||||||
children: [
|
),
|
||||||
circleList(controller),
|
logic.isShowCircle
|
||||||
vicinityList(controller),
|
? Positioned(
|
||||||
],
|
bottom: 36.sp,
|
||||||
),
|
right: 10.sp,
|
||||||
),
|
child: GestureDetector(
|
||||||
logic.isShowCircle
|
onTap: () async {
|
||||||
? Positioned(
|
List<MyConfigData> numbers = [];
|
||||||
bottom: 36.sp,
|
numbers.add(MyConfigData(
|
||||||
right: 10.sp,
|
logic.getCircleIndex().id.toString(),
|
||||||
child: GestureDetector(
|
logic.getCircleIndex().title!,
|
||||||
onTap: () async {
|
false));
|
||||||
List<MyConfigData> numbers = [];
|
var data = await Get.toNamed(
|
||||||
numbers.add(MyConfigData(
|
AppRoutes.Call_out,
|
||||||
logic.getCircleIndex().id.toString(),
|
arguments: {'numbers': numbers});
|
||||||
logic.getCircleIndex().title!,
|
},
|
||||||
false));
|
child: Image.asset(
|
||||||
var data = await Get.toNamed(
|
getCircleImage('send_msg'),
|
||||||
AppRoutes.Call_out,
|
width: 60.sp,
|
||||||
arguments: {'numbers': numbers});
|
)))
|
||||||
},
|
: Center()
|
||||||
child: Image.asset(
|
],
|
||||||
getCircleImage('send_msg'),
|
);
|
||||||
width: 60.sp,
|
}),
|
||||||
)))
|
),
|
||||||
: Center()
|
);
|
||||||
],
|
|
||||||
);
|
|
||||||
}),
|
|
||||||
),
|
|
||||||
));
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
|
|
||||||
|
import 'package:circle_app/app/circle/view.dart';
|
||||||
import 'package:circle_app/util/util.dart';
|
import 'package:circle_app/util/util.dart';
|
||||||
import 'package:circle_app/view/ExitAppConfirmation.dart';
|
import 'package:circle_app/view/ExitAppConfirmation.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
@ -28,7 +29,7 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
|||||||
return GetBuilder(builder: (HomeLogic controller) {
|
return GetBuilder(builder: (HomeLogic controller) {
|
||||||
return ExitAppConfirmation(child: Scaffold(
|
return ExitAppConfirmation(child: Scaffold(
|
||||||
resizeToAvoidBottomInset: false,
|
resizeToAvoidBottomInset: false,
|
||||||
// backgroundColor: Color.fromRGBO(244, 245, 245, 1.0),
|
backgroundColor: const Color.fromRGBO(15, 10, 31, 1.0),
|
||||||
bottomNavigationBar: Container(
|
bottomNavigationBar: Container(
|
||||||
height: 49.sp + MediaQuery.of(context).padding.bottom,
|
height: 49.sp + MediaQuery.of(context).padding.bottom,
|
||||||
width: Get.width,
|
width: Get.width,
|
||||||
@ -51,13 +52,30 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
body: PageView(
|
body: Stack(
|
||||||
physics: const NeverScrollableScrollPhysics(),
|
children: [
|
||||||
controller: controller.pageController,
|
Container(
|
||||||
onPageChanged: (int index) {
|
width: MediaQuery.of(context).size.width,
|
||||||
// controller.updateIndex(index);
|
height: Get.height - 49.sp + MediaQuery.of(context).padding.bottom,
|
||||||
},
|
decoration: const BoxDecoration(
|
||||||
children: controller.tabs,
|
image: bgWidget),
|
||||||
|
),
|
||||||
|
// Image.asset(
|
||||||
|
// getBaseImage('bg'),
|
||||||
|
// width: Get.width,
|
||||||
|
// height: Get.height - 49.sp + MediaQuery.of(context).padding.bottom,
|
||||||
|
// fit: BoxFit.fill,
|
||||||
|
// gaplessPlayback: true,
|
||||||
|
// ),
|
||||||
|
PageView(
|
||||||
|
physics: const NeverScrollableScrollPhysics(),
|
||||||
|
controller: controller.pageController,
|
||||||
|
onPageChanged: (int index) {
|
||||||
|
// controller.updateIndex(index);
|
||||||
|
},
|
||||||
|
children: controller.tabs,
|
||||||
|
)
|
||||||
|
],
|
||||||
),
|
),
|
||||||
),);
|
),);
|
||||||
});
|
});
|
||||||
@ -88,6 +106,8 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
|||||||
: getTabbarImage('${image}_normal'),
|
: getTabbarImage('${image}_normal'),
|
||||||
width: 34.sp,
|
width: 34.sp,
|
||||||
height: 34.sp,
|
height: 34.sp,
|
||||||
|
excludeFromSemantics: true,
|
||||||
|
gaplessPlayback: true,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -40,42 +40,36 @@ class MinefragmentPage extends StatelessWidget {
|
|||||||
return GetBuilder<MinefragmentLogic>(
|
return GetBuilder<MinefragmentLogic>(
|
||||||
builder: (logic) {
|
builder: (logic) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
body: Container(
|
backgroundColor: Colors.transparent,
|
||||||
width: Get.width,
|
body: Padding(
|
||||||
height: Get.height,
|
padding: EdgeInsets.only(
|
||||||
decoration: const BoxDecoration(
|
top: 20.0 + statusBarHeight.sp,
|
||||||
image: bgWidget
|
left: 11.sp,
|
||||||
|
right: 11.sp,
|
||||||
),
|
),
|
||||||
child: Padding(
|
child: SingleChildScrollView(
|
||||||
padding: EdgeInsets.only(
|
child: Column(
|
||||||
top: 20.0 + statusBarHeight.sp,
|
children: [
|
||||||
left: 11.sp,
|
_buildAvatarRow(logic),
|
||||||
right: 11.sp,
|
_friendsRow(logic),
|
||||||
),
|
GestureDetector(
|
||||||
child: SingleChildScrollView(
|
onTap: () {
|
||||||
child: Column(
|
showRechargeDialog(logic);
|
||||||
children: [
|
},
|
||||||
_buildAvatarRow(logic),
|
child: Stack(children: [
|
||||||
_friendsRow(logic),
|
MyImageWidget,
|
||||||
GestureDetector(
|
Positioned(
|
||||||
onTap: () {
|
top: 54.sp,
|
||||||
showRechargeDialog(logic);
|
left: 72.sp,
|
||||||
},
|
child: Text(logic.vipMsg,style: TextStyle(color: const Color(0x99FFFFFF),fontSize: 12.sp),)),
|
||||||
child: Stack(children: [
|
Positioned(
|
||||||
MyImageWidget,
|
top: 26.sp,
|
||||||
Positioned(
|
left: 70.sp,
|
||||||
top: 54.sp,
|
child: Text("会员-微乐园贵宾",style: TextStyle(color: const Color(0xFFFFFFFF),fontSize: 16.sp),))
|
||||||
left: 72.sp,
|
],),
|
||||||
child: Text(logic.vipMsg,style: TextStyle(color: const Color(0x99FFFFFF),fontSize: 12.sp),)),
|
),
|
||||||
Positioned(
|
_circleLiveView(logic),
|
||||||
top: 26.sp,
|
],
|
||||||
left: 70.sp,
|
|
||||||
child: Text("会员-微乐园贵宾",style: TextStyle(color: const Color(0xFFFFFFFF),fontSize: 16.sp),))
|
|
||||||
],),
|
|
||||||
),
|
|
||||||
_circleLiveView(logic),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -61,12 +61,7 @@ class MsgPage extends StatelessWidget {
|
|||||||
backgroundColor: Colors.transparent,
|
backgroundColor: Colors.transparent,
|
||||||
body: Stack(
|
body: Stack(
|
||||||
children: [
|
children: [
|
||||||
Container(
|
|
||||||
width: MediaQuery.of(context).size.width,
|
|
||||||
height: MediaQuery.of(context).size.height,
|
|
||||||
decoration: const BoxDecoration(
|
|
||||||
image: bgWidget),
|
|
||||||
),
|
|
||||||
SafeArea(
|
SafeArea(
|
||||||
child: GetBuilder(builder: (MsgLogic controller) {
|
child: GetBuilder(builder: (MsgLogic controller) {
|
||||||
return Column(
|
return Column(
|
||||||
|
|||||||
@ -45,12 +45,6 @@ class _WebViewContainerState extends State<WebviewPage> {
|
|||||||
|
|
||||||
},
|
},
|
||||||
onWebResourceError: (WebResourceError error) {},
|
onWebResourceError: (WebResourceError error) {},
|
||||||
onNavigationRequest: (NavigationRequest request) {
|
|
||||||
if (request.url.startsWith('')) {
|
|
||||||
return NavigationDecision.prevent;
|
|
||||||
}
|
|
||||||
return NavigationDecision.navigate;
|
|
||||||
},
|
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
..loadRequest(Uri.parse(url));
|
..loadRequest(Uri.parse(url));
|
||||||
|
|||||||
@ -93,7 +93,7 @@ dependencies:
|
|||||||
#event_bus:
|
#event_bus:
|
||||||
event_bus: ^2.0.0
|
event_bus: ^2.0.0
|
||||||
#安装apk
|
#安装apk
|
||||||
flutter_install_app: 1.3.0
|
# flutter_install_app: 1.3.0
|
||||||
#闪屏页
|
#闪屏页
|
||||||
flutter_native_splash: 2.2.16
|
flutter_native_splash: 2.2.16
|
||||||
#腾讯离线推送
|
#腾讯离线推送
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user