|
@@ -168,52 +168,48 @@ class HomeView extends GetView<HomeController> {
|
|
|
),
|
|
|
),
|
|
|
const SizedBox(height: 40,),
|
|
|
- Align(
|
|
|
- alignment: Alignment.center,
|
|
|
- child: Padding(
|
|
|
- padding: const EdgeInsets.fromLTRB(60, 0, 50, 0),
|
|
|
- child: Row(
|
|
|
- children: [
|
|
|
- ButtonSelect(
|
|
|
- labels: ['setting_mode_rules'.tr,'setting_mode_global'.tr,],
|
|
|
- value: controllers.global.modes.indexOf(controllers.global.modesSelect.value),
|
|
|
- onSelect: (idx) => {
|
|
|
- controllers.global.updateMode(controllers.global.modes[idx])
|
|
|
- },
|
|
|
- ),
|
|
|
- const SizedBox(width: 10,),
|
|
|
- ButtonSelect(
|
|
|
- labels: ['route_sys_tile'.tr,'route_tun_title'.tr,],
|
|
|
- value: controllers.global.routeModes.indexOf(controllers.global.routeModesSelect.value),
|
|
|
- onSelect: (idx) => {
|
|
|
- controllers.global.updateRoute(controllers.global.routeModes[idx])
|
|
|
- }
|
|
|
- ),
|
|
|
-
|
|
|
-
|
|
|
- ],
|
|
|
- ),
|
|
|
- ),
|
|
|
- ),
|
|
|
- Padding(
|
|
|
- padding: const EdgeInsets.fromLTRB(60, 10, 50, 0),
|
|
|
+ Center(
|
|
|
child: Row(
|
|
|
children: [
|
|
|
- ElevatedButton(onPressed: () async {
|
|
|
- if(controller.serviceStuatus.value == false){
|
|
|
- await controller.installService();
|
|
|
- } else{
|
|
|
- await controller.UninstallService();
|
|
|
- }
|
|
|
- }, child: controller.serviceStuatus.value == false ? const Text("安装服务") : const Text("卸载服务")),
|
|
|
- const SizedBox(width: 10,),
|
|
|
- ElevatedButton(onPressed: () async{
|
|
|
- await controller.coreRestart();
|
|
|
- }, child: const Text("重启内核")),
|
|
|
- ],
|
|
|
+ ButtonSelect(
|
|
|
+ labels: ['setting_mode_rules'.tr,'setting_mode_global'.tr,],
|
|
|
+ value: controllers.global.modes.indexOf(controllers.global.modesSelect.value),
|
|
|
+ onSelect: (idx) => {
|
|
|
+ controllers.global.updateMode(controllers.global.modes[idx])
|
|
|
+ },
|
|
|
+ ),
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
|
|
|
+ ],
|
|
|
),
|
|
|
- )
|
|
|
+ ),
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
|
|
|
|
|
|
|