mirror of
https://github.com/krille-chan/fluffychat
synced 2024-10-05 13:52:46 +00:00
chore: Follow up audomessage speed button design
This commit is contained in:
parent
73c08c3fdd
commit
9b82614fba
1 changed files with 21 additions and 23 deletions
|
@ -211,29 +211,6 @@ class AudioPlayerState extends State<AudioPlayerWidget> {
|
|||
child: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: <Widget>[
|
||||
AnimatedSize(
|
||||
duration: FluffyThemes.animationDuration,
|
||||
curve: FluffyThemes.animationCurve,
|
||||
child: audioPlayer == null
|
||||
? const SizedBox.shrink()
|
||||
: SizedBox(
|
||||
height: 36,
|
||||
width: 36,
|
||||
child: IconButton(
|
||||
padding: EdgeInsets.zero,
|
||||
onPressed: _toggleSpeed,
|
||||
//radius: AppConfig.borderRadius * 2,
|
||||
icon: Text(
|
||||
'${audioPlayer.speed.toString()}x',
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 12,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
const SizedBox(width: 8),
|
||||
SizedBox(
|
||||
width: buttonSize,
|
||||
height: buttonSize,
|
||||
|
@ -307,6 +284,27 @@ class AudioPlayerState extends State<AudioPlayerWidget> {
|
|||
),
|
||||
),
|
||||
),
|
||||
Stack(
|
||||
children: [
|
||||
IconButton(
|
||||
icon: Icon(Icons.mic_none_outlined, color: widget.color),
|
||||
onPressed: _toggleSpeed,
|
||||
),
|
||||
if (audioPlayer != null)
|
||||
Positioned(
|
||||
bottom: 0,
|
||||
right: 0,
|
||||
child: Text(
|
||||
'${audioPlayer.speed.toString()}x',
|
||||
textAlign: TextAlign.right,
|
||||
style: TextStyle(
|
||||
fontSize: 9.0,
|
||||
color: widget.color,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue