1
0
mirror of https://github.com/stonega/tsacdop synced 2024-12-16 10:22:23 +01:00
tsacdop-podcast-app-android/lib/main.dart
stonegate 69dfc393ba modified: lib/class/audiostate.dart
modified:   lib/class/episodebrief.dart
	modified:   lib/class/importompl.dart
	modified:   lib/class/podcast_group.dart
	modified:   lib/class/podcastlocal.dart
	modified:   lib/episodes/episodedetail.dart
	modified:   lib/episodes/episodedownload.dart
	modified:   lib/home/appbar/addpodcast.dart
	modified:   lib/home/appbar/popupmenu.dart
	modified:   lib/home/audio_player.dart
	modified:   lib/home/homescroll.dart
	modified:   lib/local_storage/sqflite_localpodcast.dart
	modified:   lib/main.dart
	modified:   lib/podcasts/podcastdetail.dart
	modified:   lib/podcasts/podcastgroup.dart
	modified:   lib/podcasts/podcastlist.dart
	modified:   lib/util/episodegrid.dart
2020-02-20 23:44:42 +08:00

45 lines
1.4 KiB
Dart

import 'package:flutter/material.dart';
import 'package:flutter_statusbarcolor/flutter_statusbarcolor.dart';
import 'package:provider/provider.dart';
import 'package:flutter/services.dart';
import 'package:flutter_downloader/flutter_downloader.dart';
import 'package:tsacdop/class/podcast_group.dart';
import 'package:tsacdop/home/appbar/addpodcast.dart';
import 'package:tsacdop/class/audiostate.dart';
import 'package:tsacdop/class/importompl.dart';
import 'package:tsacdop/class/settingstate.dart';
void main() async {
runApp(
MultiProvider(
providers: [
ChangeNotifierProvider(create: (context) => AudioPlay()),
ChangeNotifierProvider(create: (context) => ImportOmpl()),
ChangeNotifierProvider(create: (context) => SettingState()),
ChangeNotifierProvider(create: (context) => GroupList()),
],
child: MyApp(),
),
);
WidgetsFlutterBinding.ensureInitialized();
await FlutterDownloader.initialize();
await SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]);
await FlutterStatusbarcolor.setStatusBarColor(Colors.grey[100]);
await FlutterStatusbarcolor.setNavigationBarColor(Colors.grey[100]);
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: false,
title: 'TsacDop',
theme: ThemeData(
primaryColor: Colors.white,
),
home: MyHomePage(),
);
}
}