Skip to content

Commit

Permalink
Remove unneeded vars
Browse files Browse the repository at this point in the history
  • Loading branch information
Hedon-dev committed Dec 1, 2024
1 parent 33fab6f commit 1f3346e
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,6 @@ class ViewerApp extends StatefulWidget {
}

class ViewerAppState extends State<ViewerApp> {
static final _defaultLightColorScheme =
ColorScheme.fromSwatch(primarySwatch: Colors.green);
static final _defaultDarkColorScheme = ColorScheme.fromSwatch(
primarySwatch: Colors.green, brightness: Brightness.dark);

bool updateAvailable = false;
bool isDownloadingUpdate = false;
bool updateFailed = false;
Expand Down Expand Up @@ -104,12 +99,17 @@ class ViewerAppState extends State<ViewerApp> {
return const SizedBox();
}
return MaterialApp(
title: 'Hedon haven',
title: "Hedon haven",
// Try to use system colors first and fallback to Green
theme: ThemeData(
colorScheme: lightColorScheme ?? _defaultLightColorScheme,
colorScheme: lightColorScheme ??
ColorScheme.fromSwatch(primarySwatch: Colors.green),
),
darkTheme: ThemeData(
colorScheme: darkColorScheme ?? _defaultDarkColorScheme,
colorScheme: darkColorScheme ??
ColorScheme.fromSwatch(
primarySwatch: Colors.green,
brightness: Brightness.dark),
),
themeMode: snapshot.data,
home: updateAvailable
Expand Down

0 comments on commit 1f3346e

Please sign in to comment.