feat: add Flutter desktop client for Rtty
This commit is contained in:
28
desktop/lib/main.dart
Normal file
28
desktop/lib/main.dart
Normal file
@@ -0,0 +1,28 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
|
||||
import 'src/terminal_screen.dart';
|
||||
import 'src/theme.dart';
|
||||
|
||||
void main() {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
// 锁定竖排字符方向(终端场景无需旋转)。
|
||||
SystemChrome.setPreferredOrientations(DeviceOrientation.values);
|
||||
|
||||
runApp(const RttyApp());
|
||||
}
|
||||
|
||||
class RttyApp extends StatelessWidget {
|
||||
const RttyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
title: 'Rtty Desktop',
|
||||
debugShowCheckedModeBanner: false,
|
||||
theme: RttyTheme.app(),
|
||||
home: const TerminalScreen(),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user