准备构建tab vc
This commit is contained in:
parent
7f611724e6
commit
4be5680456
@ -15,7 +15,7 @@ class _BottomNavigationBarLntState extends State<BottomNavigationBarLnt>{
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final List<Widget> chiledList = [Center(child: const Text("sfdajl",style: TextStyle(color: Colors.red),),),const Text("aaa"),const Text("eeee"),const Text("rrrr")];
|
final List<Widget> chiledList = [Center(child: const Text("dddddsaaaafdajl",style: TextStyle(color: Colors.red),),),const Text("aaa"),const Text("eeee"),const Text("rrrr")];
|
||||||
|
|
||||||
final List<BottomNavigationBarItem> listItem = <BottomNavigationBarItem>[
|
final List<BottomNavigationBarItem> listItem = <BottomNavigationBarItem>[
|
||||||
const BottomNavigationBarItem(
|
const BottomNavigationBarItem(
|
||||||
|
|||||||
@ -1,11 +1,12 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter/widgets.dart';
|
import 'package:flutter/widgets.dart';
|
||||||
|
|
||||||
import 'MyApp.dart';
|
// import 'MyApp.dart';
|
||||||
|
|
||||||
import 'TestApp.dart';
|
|
||||||
|
|
||||||
|
// import 'TestApp.dart';
|
||||||
|
import 'WallPaperApp.dart';
|
||||||
void main() {
|
void main() {
|
||||||
runApp(const BottomNavigationBarLnt());
|
runApp(const WallPaperApp());
|
||||||
|
// runApp(const BottomNavigationBarLnt());
|
||||||
// runApp(const MyApp());
|
// runApp(const MyApp());
|
||||||
}
|
}
|
||||||
|
|||||||
@ -9,10 +9,10 @@ class TabbarPageView extends GetView {
|
|||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
title: const Text("首页"),
|
title: const Text("Tab"),
|
||||||
),
|
),
|
||||||
body: const Center(
|
body: const Center(
|
||||||
child: Text("xxxxx"),
|
child: Text("我是tab页面"),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,21 +8,21 @@ import 'package:get/get.dart';
|
|||||||
|
|
||||||
class AppRoutes {
|
class AppRoutes {
|
||||||
AppRoutes._();
|
AppRoutes._();
|
||||||
static const initialPage = '/home';
|
static const initialPage = '/tabvc';
|
||||||
|
|
||||||
static final routes= [
|
static final routes= [
|
||||||
GetPage(
|
GetPage(
|
||||||
name: 'home',
|
name: initialPage,
|
||||||
|
page: ()=> const TabbarPageView(),
|
||||||
|
binding: TabbarPageBinding(),
|
||||||
|
participatesInRootNavigator: true,
|
||||||
|
),
|
||||||
|
GetPage(
|
||||||
|
name: '/home',
|
||||||
page: ()=> const HomePageView(),
|
page: ()=> const HomePageView(),
|
||||||
binding: HomePageBinding(),
|
binding: HomePageBinding(),
|
||||||
participatesInRootNavigator: true,
|
participatesInRootNavigator: true,
|
||||||
),
|
)
|
||||||
// GetPage(
|
|
||||||
// name: initialPage,
|
|
||||||
// page: ()=> const TabbarPageView(),
|
|
||||||
// binding: TabbarPageBinding(),
|
|
||||||
// participatesInRootNavigator: true,
|
|
||||||
// )
|
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user