import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

import 'oto_client_app.dart';

Future<void> applyFullscreenMode() async {
  await SystemChrome.setEnabledSystemUIMode(SystemUiMode.immersiveSticky);
  SystemChrome.setSystemUIOverlayStyle(
    const SystemUiOverlayStyle(
      statusBarColor: Colors.transparent,
      systemNavigationBarColor: Colors.transparent,
      systemNavigationBarDividerColor: Colors.transparent,
    ),
  );
}

Future<void> bootstrapOtoClient() async {
  await applyFullscreenMode();
}

Future<void> runOtoClient() async {
  WidgetsFlutterBinding.ensureInitialized();
  await bootstrapOtoClient();
  runApp(const OtoClientApp());
}
