Add TV update flow in Tentang and fix startup zone

This commit is contained in:
dwindown
2026-04-01 14:20:04 +07:00
parent 081ed9f695
commit 925189417d
12 changed files with 953 additions and 44 deletions

View File

@@ -13,38 +13,39 @@ import 'core/sacred_tokens.dart';
import 'data/local/models.dart';
import 'features/home/home_view.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
FlutterError.onError = (details) {
FlutterError.presentError(details);
debugPrint('[Fatal][FlutterError] ${details.exceptionAsString()}');
};
PlatformDispatcher.instance.onError = (error, stack) {
debugPrint('[Fatal][PlatformDispatcher] $error');
debugPrintStack(stackTrace: stack);
return true;
};
ErrorWidget.builder = (details) {
return const Material(
color: SacredColors.background,
child: Center(
child: Padding(
padding: EdgeInsets.all(32),
child: Text(
'Terjadi gangguan tampilan.\nAplikasi tetap berjalan dalam mode aman.',
textAlign: TextAlign.center,
style: TextStyle(
color: SacredColors.onSurface,
fontSize: 24,
fontWeight: FontWeight.w700,
void main() {
runZonedGuarded(() async {
WidgetsFlutterBinding.ensureInitialized();
FlutterError.onError = (details) {
FlutterError.presentError(details);
debugPrint('[Fatal][FlutterError] ${details.exceptionAsString()}');
};
PlatformDispatcher.instance.onError = (error, stack) {
debugPrint('[Fatal][PlatformDispatcher] $error');
debugPrintStack(stackTrace: stack);
return true;
};
ErrorWidget.builder = (details) {
return const Material(
color: SacredColors.background,
child: Center(
child: Padding(
padding: EdgeInsets.all(32),
child: Text(
'Terjadi gangguan tampilan.\nAplikasi tetap berjalan dalam mode aman.',
textAlign: TextAlign.center,
style: TextStyle(
color: SacredColors.onSurface,
fontSize: 24,
fontWeight: FontWeight.w700,
),
),
),
),
),
);
};
);
};
await runZonedGuarded(() async {
await _bootstrapAndRun();
}, (error, stack) {
debugPrint('[Fatal][Zone] $error');