1234567891011121314151617181920212223242526272829303132333435363738394041 |
- import 'package:flutter/material.dart';
- import 'package:get/get.dart';
- import '../controllers/welcome_controller.dart';
- class WelcomeView extends GetView<WelcomeController> {
- const WelcomeView({Key? key}) : super(key: key);
- @override
- Widget build(BuildContext context) {
- return Scaffold(
- backgroundColor: Colors.white,
- body: Obx(() {
- return Center(
- child: controller.isLoading.value
- ? const Column(
- mainAxisAlignment: MainAxisAlignment.center,
- children: <Widget>[
- CircularProgressIndicator(), // 菊花加载指示器
- SizedBox(height: 20), // 用于给加载指示器和文字之间增加一些空间
- Text(
- '正在获取系统配置',
- style: TextStyle(
- fontSize: 16,
- fontWeight: FontWeight.w600,
- ),
- ),
- ],
- )
- : Container(), // 当不在加载时,你可能想要显示其他的 Widget
- );
- }),
- );
- }
- }
|