forked from cwtch.im/cwtch-ui
light theme fixes + message cache ! fix
This commit is contained in:
parent
dc5ba7b392
commit
4e2f83ccd9
|
@ -165,7 +165,7 @@ class MessageCache extends ChangeNotifier {
|
|||
int size() {
|
||||
// very naive cache size, assuming MessageInfo are fairly large on average
|
||||
// and everything else is small in comparison
|
||||
int cacheSize = cache.entries.map((e) => e.value.size()).fold(0, (previousValue, element) => previousValue! + element);
|
||||
int cacheSize = cache.entries.map((e) => e.value.size()).fold(0, (previousValue, element) => previousValue + element);
|
||||
return cacheSize + cacheByHash.length * 64 + cacheByIndex.length * 16;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -130,7 +130,7 @@ class _ContactsViewState extends State<ContactsView> {
|
|||
floatingActionButton: FloatingActionButton(
|
||||
onPressed: _modalAddImportChoice,
|
||||
tooltip: AppLocalizations.of(context)!.tooltipAddContact,
|
||||
child: const Icon(CwtchIcons.person_add_alt_1_24px),
|
||||
child: Icon(CwtchIcons.person_add_alt_1_24px, color: Provider.of<Settings>(context).theme.defaultButtonTextColor,),
|
||||
),
|
||||
body: showSearchBar || Provider.of<ContactListState>(context).isFiltered ? _buildFilterable() : _buildContactList());
|
||||
}
|
||||
|
|
|
@ -183,7 +183,7 @@ class _GroupSettingsViewState extends State<GroupSettingsView> {
|
|||
onPressed: () {
|
||||
showAlertDialog(context);
|
||||
},
|
||||
style: ButtonStyle(backgroundColor: MaterialStateProperty.all(Colors.transparent)),
|
||||
style: ButtonStyle(backgroundColor: MaterialStateProperty.all(Provider.of<Settings>(context).theme.backgroundPaneColor), foregroundColor: MaterialStateProperty.all(Provider.of<Settings>(context).theme.mainTextColor)),
|
||||
icon: Icon(CwtchIcons.leave_group),
|
||||
label: Text(
|
||||
AppLocalizations.of(context)!.leaveConversation,
|
||||
|
|
|
@ -269,7 +269,7 @@ class _PeerSettingsViewState extends State<PeerSettingsView> {
|
|||
onPressed: () {
|
||||
showAlertDialog(context);
|
||||
},
|
||||
style: ButtonStyle(backgroundColor: MaterialStateProperty.all(Colors.transparent)),
|
||||
style: ButtonStyle(backgroundColor: MaterialStateProperty.all(Provider.of<Settings>(context).theme.backgroundPaneColor), foregroundColor: MaterialStateProperty.all(Provider.of<Settings>(context).theme.mainTextColor)),
|
||||
icon: Icon(CwtchIcons.leave_group),
|
||||
label: Text(
|
||||
AppLocalizations.of(context)!.leaveConversation,
|
||||
|
|
|
@ -75,6 +75,7 @@ class _ProfileMgrViewState extends State<ProfileMgrView> {
|
|||
child: Icon(
|
||||
Icons.add,
|
||||
semanticLabel: AppLocalizations.of(context)!.addNewProfileBtn,
|
||||
color: Provider.of<Settings>(context).theme.defaultButtonTextColor,
|
||||
),
|
||||
),
|
||||
body: _buildProfileManager(),
|
||||
|
|
|
@ -41,6 +41,7 @@ class _ServersView extends State<ServersView> {
|
|||
child: Icon(
|
||||
Icons.add,
|
||||
semanticLabel: AppLocalizations.of(context)!.addServerTooltip,
|
||||
color: Provider.of<Settings>(context).theme.defaultButtonTextColor,
|
||||
),
|
||||
),
|
||||
body: Consumer<ServerListState>(
|
||||
|
|
Loading…
Reference in New Issue