mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-30 16:29:30 +01:00
CircularProgressIndicator.adaptive(
This commit is contained in:
parent
eca3905e0c
commit
4ab57c2900
@ -222,9 +222,7 @@ class _KeyVerificationPageState extends State<KeyVerificationDialog> {
|
||||
children: <Widget>[
|
||||
Image.asset('assets/verification.png', fit: BoxFit.contain),
|
||||
const SizedBox(height: 16),
|
||||
PlatformInfos.isCupertinoStyle
|
||||
? CupertinoActivityIndicator()
|
||||
: CircularProgressIndicator(),
|
||||
CircularProgressIndicator.adaptive(strokeWidth: 2),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
L10n.of(context).waitingPartnerAcceptRequest,
|
||||
@ -307,9 +305,7 @@ class _KeyVerificationPageState extends State<KeyVerificationDialog> {
|
||||
body = Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: <Widget>[
|
||||
PlatformInfos.isCupertinoStyle
|
||||
? CupertinoActivityIndicator()
|
||||
: CircularProgressIndicator(),
|
||||
CircularProgressIndicator.adaptive(strokeWidth: 2),
|
||||
SizedBox(height: 10),
|
||||
Text(
|
||||
acceptText,
|
||||
|
@ -37,7 +37,8 @@ class ArchiveView extends StatelessWidget {
|
||||
));
|
||||
}
|
||||
if (!snapshot.hasData) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(strokeWidth: 2));
|
||||
} else {
|
||||
controller.archive = snapshot.data;
|
||||
if (controller.archive.isEmpty) {
|
||||
|
@ -54,7 +54,9 @@ class ChatEncryptionSettingsView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (!snapshot.hasData) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child:
|
||||
CircularProgressIndicator.adaptive(strokeWidth: 2));
|
||||
}
|
||||
final deviceKeys = snapshot.data;
|
||||
return ListView.builder(
|
||||
|
@ -104,7 +104,9 @@ class ChatPermissionsSettingsView extends StatelessWidget {
|
||||
future: room.client.getCapabilities(),
|
||||
builder: (context, snapshot) {
|
||||
if (!snapshot.hasData) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2));
|
||||
}
|
||||
final String roomVersion = room
|
||||
.getState(EventTypes.RoomCreate)
|
||||
|
@ -243,7 +243,8 @@ class ChatView extends StatelessWidget {
|
||||
builder: (BuildContext context, snapshot) {
|
||||
if (controller.timeline == null) {
|
||||
return Center(
|
||||
child: CircularProgressIndicator(strokeWidth: 2),
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2),
|
||||
);
|
||||
}
|
||||
|
||||
@ -279,7 +280,8 @@ class ChatView extends StatelessWidget {
|
||||
return i == controller.filteredEvents.length + 1
|
||||
? controller.timeline.isRequestingHistory
|
||||
? Center(
|
||||
child: CircularProgressIndicator(),
|
||||
child: CircularProgressIndicator
|
||||
.adaptive(),
|
||||
)
|
||||
: controller.canLoadMore
|
||||
? Center(
|
||||
|
@ -33,7 +33,8 @@ class DevicesSettingsView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (!snapshot.hasData || controller.devices == null) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(strokeWidth: 2));
|
||||
}
|
||||
return Column(
|
||||
children: <Widget>[
|
||||
@ -55,7 +56,7 @@ class DevicesSettingsView extends StatelessWidget {
|
||||
style: TextStyle(color: Colors.red),
|
||||
),
|
||||
trailing: controller.loadingDeletingDevices
|
||||
? CircularProgressIndicator()
|
||||
? CircularProgressIndicator.adaptive(strokeWidth: 2)
|
||||
: Icon(Icons.delete_outline),
|
||||
onTap: controller.loadingDeletingDevices
|
||||
? null
|
||||
|
@ -49,7 +49,8 @@ class HomeserverPickerView extends StatelessWidget {
|
||||
child: FluffyBanner(),
|
||||
),
|
||||
controller.isLoading
|
||||
? Center(child: CircularProgressIndicator())
|
||||
? Center(
|
||||
child: CircularProgressIndicator.adaptive(strokeWidth: 2))
|
||||
: controller.error != null
|
||||
? Center(
|
||||
child: Padding(
|
||||
@ -76,7 +77,9 @@ class HomeserverPickerView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (!snapshot.hasData) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2));
|
||||
}
|
||||
return Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
|
@ -62,7 +62,7 @@ class InvitationSelectionView extends StatelessWidget {
|
||||
builder: (BuildContext context, snapshot) {
|
||||
if (!snapshot.hasData) {
|
||||
return Center(
|
||||
child: CircularProgressIndicator(),
|
||||
child: CircularProgressIndicator.adaptive(strokeWidth: 2),
|
||||
);
|
||||
}
|
||||
final contacts = snapshot.data;
|
||||
|
@ -139,7 +139,9 @@ class SearchView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (snapshot.connectionState != ConnectionState.done) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2));
|
||||
}
|
||||
final publicRoomsResponse = snapshot.data;
|
||||
if (publicRoomsResponse.chunk.isEmpty) {
|
||||
|
@ -39,7 +39,8 @@ class Settings3PidView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (!snapshot.hasData) {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
return Center(
|
||||
child: CircularProgressIndicator.adaptive(strokeWidth: 2));
|
||||
}
|
||||
final identifier = snapshot.data;
|
||||
return Column(
|
||||
|
@ -99,7 +99,9 @@ class SettingsNotificationsView extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
if (snapshot.connectionState != ConnectionState.done) {
|
||||
Center(child: CircularProgressIndicator());
|
||||
Center(
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2));
|
||||
}
|
||||
final pushers = snapshot.data ?? [];
|
||||
return ListView.builder(
|
||||
|
@ -41,7 +41,7 @@ class VideoViewerView extends StatelessWidget {
|
||||
child: controller.error != null
|
||||
? Text(controller.error.toString())
|
||||
: (controller.chewieController == null
|
||||
? CircularProgressIndicator(strokeWidth: 2)
|
||||
? CircularProgressIndicator.adaptive(strokeWidth: 2)
|
||||
: Chewie(
|
||||
controller: controller.chewieController,
|
||||
)),
|
||||
|
@ -56,7 +56,7 @@ class _ConnectionStatusHeaderState extends State<ConnectionStatusHeader> {
|
||||
SizedBox(
|
||||
width: 24,
|
||||
height: 24,
|
||||
child: CircularProgressIndicator(
|
||||
child: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2,
|
||||
value: _connected ? 1.0 : _status.progress,
|
||||
),
|
||||
|
@ -135,7 +135,7 @@ class _AudioPlayerState extends State<AudioPlayerWidget> {
|
||||
Container(
|
||||
width: 30,
|
||||
child: status == AudioPlayerStatus.downloading
|
||||
? CircularProgressIndicator(strokeWidth: 2)
|
||||
? CircularProgressIndicator.adaptive(strokeWidth: 2)
|
||||
: IconButton(
|
||||
icon: Icon(
|
||||
audioPlayer.state == PlayerState.PLAYING
|
||||
|
@ -249,7 +249,7 @@ class _ImageBubbleState extends State<ImageBubble> {
|
||||
children: <Widget>[
|
||||
if (blurhash != null) blurhash,
|
||||
Center(
|
||||
child: child ?? CircularProgressIndicator(strokeWidth: 2),
|
||||
child: child ?? CircularProgressIndicator.adaptive(strokeWidth: 2),
|
||||
),
|
||||
],
|
||||
);
|
||||
|
@ -79,7 +79,8 @@ class ProfileBottomSheet extends StatelessWidget {
|
||||
child: snapshot.hasError
|
||||
? Text(snapshot.error
|
||||
.toLocalizedString(context))
|
||||
: CircularProgressIndicator(),
|
||||
: CircularProgressIndicator.adaptive(
|
||||
strokeWidth: 2),
|
||||
)
|
||||
: ContentBanner(
|
||||
profile.avatarUrl,
|
||||
|
Loading…
Reference in New Issue
Block a user