Fix maximum width of dropdown boxes in settings
continuous-integration/drone/pr Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
This commit is contained in:
parent
ecdcef2192
commit
0146436cb3
|
@ -107,7 +107,9 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.settingLanguage, style: TextStyle(color: settings.current().mainTextColor)),
|
title: Text(AppLocalizations.of(context)!.settingLanguage, style: TextStyle(color: settings.current().mainTextColor)),
|
||||||
leading: Icon(CwtchIcons.change_language, color: settings.current().mainTextColor),
|
leading: Icon(CwtchIcons.change_language, color: settings.current().mainTextColor),
|
||||||
trailing: DropdownButton(
|
trailing: Container(
|
||||||
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
|
child: DropdownButton(
|
||||||
value: Provider.of<Settings>(context).locale.languageCode,
|
value: Provider.of<Settings>(context).locale.languageCode,
|
||||||
onChanged: (String? newValue) {
|
onChanged: (String? newValue) {
|
||||||
setState(() {
|
setState(() {
|
||||||
|
@ -120,7 +122,7 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
value: value.languageCode,
|
value: value.languageCode,
|
||||||
child: Text(getLanguageFull(context, value.languageCode)),
|
child: Text(getLanguageFull(context, value.languageCode)),
|
||||||
);
|
);
|
||||||
}).toList())),
|
}).toList()))),
|
||||||
SwitchListTile(
|
SwitchListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.settingTheme, style: TextStyle(color: settings.current().mainTextColor)),
|
title: Text(AppLocalizations.of(context)!.settingTheme, style: TextStyle(color: settings.current().mainTextColor)),
|
||||||
value: settings.current().mode == mode_light,
|
value: settings.current().mode == mode_light,
|
||||||
|
@ -140,7 +142,9 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.themeColorLabel),
|
title: Text(AppLocalizations.of(context)!.themeColorLabel),
|
||||||
trailing: DropdownButton<String>(
|
trailing: Container(
|
||||||
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
|
child: DropdownButton<String>(
|
||||||
key: Key("DropdownTheme"),
|
key: Key("DropdownTheme"),
|
||||||
isDense: true,
|
isDense: true,
|
||||||
value: Provider.of<Settings>(context).theme.theme,
|
value: Provider.of<Settings>(context).theme.theme,
|
||||||
|
@ -155,13 +159,15 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
value: themeId,
|
value: themeId,
|
||||||
child: Text(getThemeName(context, themeId)), //"ddi_$themeId", key: Key("ddi_$themeId")),
|
child: Text(getThemeName(context, themeId)), //"ddi_$themeId", key: Key("ddi_$themeId")),
|
||||||
);
|
);
|
||||||
}).toList()),
|
}).toList())),
|
||||||
leading: Icon(CwtchIcons.change_theme, color: settings.current().mainTextColor),
|
leading: Icon(CwtchIcons.change_theme, color: settings.current().mainTextColor),
|
||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.settingUIColumnPortrait, style: TextStyle(color: settings.current().mainTextColor)),
|
title: Text(AppLocalizations.of(context)!.settingUIColumnPortrait, style: TextStyle(color: settings.current().mainTextColor)),
|
||||||
leading: Icon(Icons.table_chart, color: settings.current().mainTextColor),
|
leading: Icon(Icons.table_chart, color: settings.current().mainTextColor),
|
||||||
trailing: DropdownButton(
|
trailing: Container(
|
||||||
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
|
child: DropdownButton(
|
||||||
value: settings.uiColumnModePortrait.toString(),
|
value: settings.uiColumnModePortrait.toString(),
|
||||||
onChanged: (String? newValue) {
|
onChanged: (String? newValue) {
|
||||||
settings.uiColumnModePortrait = Settings.uiColumnModeFromString(newValue!);
|
settings.uiColumnModePortrait = Settings.uiColumnModeFromString(newValue!);
|
||||||
|
@ -172,7 +178,7 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
value: value.toString(),
|
value: value.toString(),
|
||||||
child: Text(Settings.uiColumnModeToString(value, context)),
|
child: Text(Settings.uiColumnModeToString(value, context)),
|
||||||
);
|
);
|
||||||
}).toList())),
|
}).toList()))),
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(
|
title: Text(
|
||||||
AppLocalizations.of(context)!.settingUIColumnLandscape,
|
AppLocalizations.of(context)!.settingUIColumnLandscape,
|
||||||
|
@ -182,6 +188,8 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
),
|
),
|
||||||
leading: Icon(Icons.table_chart, color: settings.current().mainTextColor),
|
leading: Icon(Icons.table_chart, color: settings.current().mainTextColor),
|
||||||
trailing: Container(
|
trailing: Container(
|
||||||
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
|
child: Container(
|
||||||
width: MediaQuery.of(context).size.width / 4,
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
child: DropdownButton(
|
child: DropdownButton(
|
||||||
isExpanded: true,
|
isExpanded: true,
|
||||||
|
@ -198,7 +206,7 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
overflow: TextOverflow.ellipsis,
|
overflow: TextOverflow.ellipsis,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}).toList()))),
|
}).toList())))),
|
||||||
SwitchListTile(
|
SwitchListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.streamerModeLabel, style: TextStyle(color: settings.current().mainTextColor)),
|
title: Text(AppLocalizations.of(context)!.streamerModeLabel, style: TextStyle(color: settings.current().mainTextColor)),
|
||||||
subtitle: Text(AppLocalizations.of(context)!.descriptionStreamerMode),
|
subtitle: Text(AppLocalizations.of(context)!.descriptionStreamerMode),
|
||||||
|
@ -238,7 +246,9 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(AppLocalizations.of(context)!.notificationPolicySettingLabel),
|
title: Text(AppLocalizations.of(context)!.notificationPolicySettingLabel),
|
||||||
subtitle: Text(AppLocalizations.of(context)!.notificationPolicySettingDescription),
|
subtitle: Text(AppLocalizations.of(context)!.notificationPolicySettingDescription),
|
||||||
trailing: DropdownButton(
|
trailing: Container(
|
||||||
|
width: MediaQuery.of(context).size.width / 4,
|
||||||
|
child: DropdownButton(
|
||||||
value: settings.notificationPolicy,
|
value: settings.notificationPolicy,
|
||||||
onChanged: (NotificationPolicy? newValue) {
|
onChanged: (NotificationPolicy? newValue) {
|
||||||
settings.notificationPolicy = newValue!;
|
settings.notificationPolicy = newValue!;
|
||||||
|
@ -252,7 +262,7 @@ class _GlobalSettingsViewState extends State<GlobalSettingsView> {
|
||||||
overflow: TextOverflow.ellipsis,
|
overflow: TextOverflow.ellipsis,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}).toList()),
|
}).toList())),
|
||||||
leading: Icon(CwtchIcons.chat_bubble_empty_24px, color: settings.current().mainTextColor),
|
leading: Icon(CwtchIcons.chat_bubble_empty_24px, color: settings.current().mainTextColor),
|
||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
|
|
Loading…
Reference in New Issue