mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-12-13 11:35:56 +00:00
refactor ThemeData
This commit is contained in:
@@ -121,7 +121,7 @@ class _ConnectionPageState extends State<ConnectionPage> {
|
||||
width: 320 + 20 * 2,
|
||||
padding: const EdgeInsets.fromLTRB(20, 24, 20, 22),
|
||||
decoration: BoxDecoration(
|
||||
color: MyTheme.color(context).bg,
|
||||
color: Theme.of(context).backgroundColor,
|
||||
borderRadius: const BorderRadius.all(Radius.circular(13)),
|
||||
),
|
||||
child: Ink(
|
||||
@@ -131,7 +131,10 @@ class _ConnectionPageState extends State<ConnectionPage> {
|
||||
children: [
|
||||
Text(
|
||||
translate('Control Remote Desktop'),
|
||||
style: const TextStyle(fontSize: 19, height: 1),
|
||||
style: Theme.of(context)
|
||||
.textTheme
|
||||
.titleLarge
|
||||
?.merge(TextStyle(height: 1)),
|
||||
),
|
||||
],
|
||||
).marginOnly(bottom: 15),
|
||||
@@ -150,13 +153,12 @@ class _ConnectionPageState extends State<ConnectionPage> {
|
||||
height: 1,
|
||||
),
|
||||
maxLines: 1,
|
||||
cursorColor: MyTheme.color(context).text!,
|
||||
cursorColor:
|
||||
Theme.of(context).textTheme.titleLarge?.color,
|
||||
decoration: InputDecoration(
|
||||
hintText: inputFocused.value
|
||||
? null
|
||||
: translate('Enter Remote ID'),
|
||||
hintStyle: TextStyle(
|
||||
color: MyTheme.color(context).placeholder),
|
||||
border: OutlineInputBorder(
|
||||
borderRadius: BorderRadius.zero,
|
||||
borderSide: BorderSide(
|
||||
@@ -219,8 +221,11 @@ class _ConnectionPageState extends State<ConnectionPage> {
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
color: ftPressed.value
|
||||
? MyTheme.color(context).bg
|
||||
: MyTheme.color(context).text),
|
||||
? Theme.of(context).backgroundColor
|
||||
: Theme.of(context)
|
||||
.textTheme
|
||||
.titleLarge
|
||||
?.color),
|
||||
).marginSymmetric(horizontal: 12),
|
||||
),
|
||||
)),
|
||||
@@ -260,7 +265,7 @@ class _ConnectionPageState extends State<ConnectionPage> {
|
||||
),
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
color: MyTheme.color(context).bg),
|
||||
color: Theme.of(context).backgroundColor),
|
||||
),
|
||||
).marginSymmetric(horizontal: 12),
|
||||
)),
|
||||
|
||||
Reference in New Issue
Block a user