|
@@ -53,12 +53,10 @@ class _MainScreenState extends State<MainScreen> with RestorationMixin {
|
|
Widget build(BuildContext context) {
|
|
Widget build(BuildContext context) {
|
|
print("build MainScreen");
|
|
print("build MainScreen");
|
|
final selectedItem = <Widget>[
|
|
final selectedItem = <Widget>[
|
|
- BuildView(),
|
|
|
|
PackageView(),
|
|
PackageView(),
|
|
PublishView(),
|
|
PublishView(),
|
|
- AutoTestView(),
|
|
|
|
- MyView(),
|
|
|
|
OperatorListView(),
|
|
OperatorListView(),
|
|
|
|
+ MyView(),
|
|
]; //DOTo
|
|
]; //DOTo
|
|
return Scaffold(
|
|
return Scaffold(
|
|
appBar: AppBar(
|
|
appBar: AppBar(
|
|
@@ -66,97 +64,77 @@ class _MainScreenState extends State<MainScreen> with RestorationMixin {
|
|
AppLocalizations.of(context)!.deploySystem,
|
|
AppLocalizations.of(context)!.deploySystem,
|
|
),
|
|
),
|
|
),
|
|
),
|
|
- body: PlatformUtils.isWindows?PublishProcessView(): Row(
|
|
|
|
- children: [
|
|
|
|
- NavigationRail(
|
|
|
|
- selectedIndex: _selectedIndex.value,
|
|
|
|
- onDestinationSelected: (index) {
|
|
|
|
- setState(() {
|
|
|
|
- var oldIndex = _selectedIndex.value;
|
|
|
|
- print('oldIndex:$oldIndex =>index:$index');
|
|
|
|
- _selectedIndex.value = index;
|
|
|
|
- });
|
|
|
|
- },
|
|
|
|
- labelType: NavigationRailLabelType.all,
|
|
|
|
- destinations: [
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.build_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.build_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- AppLocalizations.of(context)!.build,
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.badge_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.badge_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- AppLocalizations.of(context)!.package,
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.publish_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.publish_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- AppLocalizations.of(context)!.publish,
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.list_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.list_alt_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- AppLocalizations.of(context)!.autoTest,
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.account_circle_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.account_circle_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- "My",
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- NavigationRailDestination(
|
|
|
|
- icon: const Icon(
|
|
|
|
- Icons.list_outlined,
|
|
|
|
- ),
|
|
|
|
- selectedIcon: const Icon(
|
|
|
|
- Icons.list_alt_rounded,
|
|
|
|
- ),
|
|
|
|
- label: Text(
|
|
|
|
- AppLocalizations.of(context)!.operatorList,
|
|
|
|
- ),
|
|
|
|
- ),
|
|
|
|
- ],
|
|
|
|
- ),
|
|
|
|
- const VerticalDivider(thickness: 1, width: 1),
|
|
|
|
- Expanded(
|
|
|
|
- child: Padding(
|
|
|
|
- padding: EdgeInsets.all(16.0),
|
|
|
|
- child: Center(
|
|
|
|
- child: selectedItem[_selectedIndex.value],
|
|
|
|
- )),
|
|
|
|
- ),
|
|
|
|
- ],
|
|
|
|
- ),
|
|
|
|
|
|
+ body: PlatformUtils.isWindows
|
|
|
|
+ ? PublishProcessView()
|
|
|
|
+ : Row(
|
|
|
|
+ children: [
|
|
|
|
+ NavigationRail(
|
|
|
|
+ selectedIndex: _selectedIndex.value,
|
|
|
|
+ onDestinationSelected: (index) {
|
|
|
|
+ setState(() {
|
|
|
|
+ var oldIndex = _selectedIndex.value;
|
|
|
|
+ print('oldIndex:$oldIndex =>index:$index');
|
|
|
|
+ _selectedIndex.value = index;
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ labelType: NavigationRailLabelType.all,
|
|
|
|
+ destinations: [
|
|
|
|
+ NavigationRailDestination(
|
|
|
|
+ icon: const Icon(
|
|
|
|
+ Icons.badge_outlined,
|
|
|
|
+ ),
|
|
|
|
+ selectedIcon: const Icon(
|
|
|
|
+ Icons.badge_rounded,
|
|
|
|
+ ),
|
|
|
|
+ label: Text(
|
|
|
|
+ AppLocalizations.of(context)!.package,
|
|
|
|
+ ),
|
|
|
|
+ ),
|
|
|
|
+ NavigationRailDestination(
|
|
|
|
+ icon: const Icon(
|
|
|
|
+ Icons.publish_outlined,
|
|
|
|
+ ),
|
|
|
|
+ selectedIcon: const Icon(
|
|
|
|
+ Icons.publish_rounded,
|
|
|
|
+ ),
|
|
|
|
+ label: Text(
|
|
|
|
+ AppLocalizations.of(context)!.publish,
|
|
|
|
+ ),
|
|
|
|
+ ),
|
|
|
|
+ NavigationRailDestination(
|
|
|
|
+ icon: const Icon(
|
|
|
|
+ Icons.list_outlined,
|
|
|
|
+ ),
|
|
|
|
+ selectedIcon: const Icon(
|
|
|
|
+ Icons.list_alt_rounded,
|
|
|
|
+ ),
|
|
|
|
+ label: Text(
|
|
|
|
+ AppLocalizations.of(context)!.operatorList,
|
|
|
|
+ ),
|
|
|
|
+ ),
|
|
|
|
+ NavigationRailDestination(
|
|
|
|
+ icon: const Icon(
|
|
|
|
+ Icons.account_circle_outlined,
|
|
|
|
+ ),
|
|
|
|
+ selectedIcon: const Icon(
|
|
|
|
+ Icons.account_circle_rounded,
|
|
|
|
+ ),
|
|
|
|
+ label: Text(
|
|
|
|
+ "My",
|
|
|
|
+ ),
|
|
|
|
+ ),
|
|
|
|
+ ],
|
|
|
|
+ ),
|
|
|
|
+ const VerticalDivider(thickness: 1, width: 1),
|
|
|
|
+ Expanded(
|
|
|
|
+ child: Padding(
|
|
|
|
+ padding: EdgeInsets.all(16.0),
|
|
|
|
+ child: Center(
|
|
|
|
+ child: selectedItem[_selectedIndex.value],
|
|
|
|
+ )),
|
|
|
|
+ ),
|
|
|
|
+ ],
|
|
|
|
+ ),
|
|
);
|
|
);
|
|
}
|
|
}
|
|
}
|
|
}
|