mirror of
https://github.com/A-Star100/simpliplay-android.git
synced 2025-09-18 14:32:17 +00:00
108 lines
3.2 KiB
Dart
108 lines
3.2 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:media3_exoplayer_creator/screens/video_screen.dart'; // Import other files as needed
|
|
|
|
void main() {
|
|
runApp(MyApp());
|
|
}
|
|
|
|
class MyApp extends StatefulWidget {
|
|
const MyApp({super.key});
|
|
|
|
@override
|
|
State<MyApp> createState() => _MyAppState();
|
|
}
|
|
|
|
class _MyAppState extends State<MyApp> {
|
|
bool _isDarkMode = false;
|
|
|
|
void _toggleTheme() {
|
|
setState(() {
|
|
_isDarkMode = !_isDarkMode;
|
|
});
|
|
}
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MaterialApp(
|
|
debugShowCheckedModeBanner: false,
|
|
theme: _isDarkMode
|
|
? ThemeData.dark().copyWith(
|
|
primaryColor: Colors.lightBlue, // Light Blue primary color
|
|
colorScheme: ColorScheme.fromSwatch(primarySwatch: Colors.lightBlue)
|
|
.copyWith(secondary: Colors.lightBlue),
|
|
appBarTheme: AppBarTheme(
|
|
color: Colors.lightBlue,
|
|
titleTextStyle: TextStyle(
|
|
color: Colors.white,
|
|
fontSize: 20,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
textButtonTheme: TextButtonThemeData(
|
|
style: TextButton.styleFrom(
|
|
foregroundColor: Colors.lightBlue, // Light Blue for text buttons
|
|
),
|
|
),
|
|
inputDecorationTheme: InputDecorationTheme(
|
|
filled: true,
|
|
fillColor: Colors.white,
|
|
border: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(8),
|
|
borderSide: BorderSide(
|
|
color: Colors.lightBlue, // Light Blue for borders
|
|
width: 2,
|
|
),
|
|
),
|
|
focusedBorder: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(8),
|
|
borderSide: BorderSide(
|
|
color: Colors.lightBlue, // Light Blue for focused border
|
|
width: 2,
|
|
),
|
|
),
|
|
),
|
|
)
|
|
: ThemeData.light().copyWith(
|
|
primaryColor: Colors.lightBlue, // Light Blue primary color
|
|
scaffoldBackgroundColor: Colors.white,
|
|
colorScheme: ColorScheme.fromSwatch(primarySwatch: Colors.lightBlue)
|
|
.copyWith(secondary: Colors.lightBlue),
|
|
appBarTheme: AppBarTheme(
|
|
color: Colors.lightBlue,
|
|
titleTextStyle: TextStyle(
|
|
color: Colors.white,
|
|
fontSize: 20,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
textButtonTheme: TextButtonThemeData(
|
|
style: TextButton.styleFrom(
|
|
foregroundColor: Colors.lightBlue, // Light Blue for text buttons
|
|
),
|
|
),
|
|
inputDecorationTheme: InputDecorationTheme(
|
|
filled: true,
|
|
fillColor: Colors.white,
|
|
border: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(8),
|
|
borderSide: BorderSide(
|
|
color: Colors.lightBlue, // Light Blue for borders
|
|
width: 2,
|
|
),
|
|
),
|
|
focusedBorder: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(8),
|
|
borderSide: BorderSide(
|
|
color: Colors.lightBlue, // Light Blue for focused border
|
|
width: 2,
|
|
),
|
|
),
|
|
),
|
|
),
|
|
home: Scaffold(
|
|
body: VideoScreen(),
|
|
),
|
|
);
|
|
}
|
|
}
|