You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
56 lines
1.8 KiB
Dart
56 lines
1.8 KiB
Dart
import 'dart:io';
|
|
|
|
import 'package:flutter/material.dart';
|
|
import 'package:provider/provider.dart';
|
|
import 'package:queuing_system/core/api.dart';
|
|
import 'package:queuing_system/home/app_provider.dart';
|
|
import 'package:wakelock/wakelock.dart';
|
|
|
|
import 'core/config/size_config.dart';
|
|
import 'home/home_screen.dart';
|
|
// import 'home/home_screen_bkp.dart';
|
|
|
|
void main() {
|
|
//TODO: WE HAVE TO UPDATE THIS BEFORE GOING LIVE.
|
|
HttpOverrides.global = MyHttpOverrides();
|
|
WidgetsFlutterBinding.ensureInitialized();
|
|
Wakelock.enable();
|
|
runApp(const MyApp());
|
|
}
|
|
|
|
//test commit
|
|
|
|
//TODO: WE NEED TO IMPLEMENT THE AVAILABILITY MONITORING OF THE SCREENS LIKE IF THEY ARE TURNED ON OR NOT!!
|
|
|
|
class MyApp extends StatelessWidget {
|
|
const MyApp({Key? key}) : super(key: key);
|
|
|
|
// This widget is the root of your application.
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return LayoutBuilder(
|
|
builder: (context, constraints) {
|
|
return OrientationBuilder(builder: (context, orientation) {
|
|
SizeConfig().init(constraints, orientation);
|
|
return MultiProvider(
|
|
providers: [
|
|
ChangeNotifierProvider<AppProvider>(create: (context) => AppProvider()),
|
|
],
|
|
child: MaterialApp(
|
|
showSemanticsDebugger: false,
|
|
title: 'Doctors App',
|
|
theme: ThemeData(
|
|
primaryColor: Colors.grey,
|
|
fontFamily: 'Poppins',
|
|
dividerColor: Colors.grey[350],
|
|
colorScheme: ColorScheme.fromSwatch(primarySwatch: Colors.grey).copyWith(background: const Color.fromRGBO(255, 255, 255, 1)),
|
|
),
|
|
home: const MyHomePage(),
|
|
debugShowCheckedModeBanner: false,
|
|
));
|
|
});
|
|
},
|
|
);
|
|
}
|
|
}
|