Limpieza de peso de imágenes
This commit is contained in:
@@ -283,68 +283,50 @@ class _PantallaResultadoState extends State<PantallaResultado>
|
||||
final partida = estado.partida;
|
||||
if (partida == null) return const SizedBox.shrink();
|
||||
|
||||
// Comprobar si la partida terminó
|
||||
final finPartida = estado.comprobarFinPartida();
|
||||
|
||||
if (finPartida) {
|
||||
return SizedBox(
|
||||
width: double.infinity,
|
||||
height: 56,
|
||||
child: ElevatedButton.icon(
|
||||
onPressed: () {
|
||||
Navigator.pushReplacement(
|
||||
context,
|
||||
MaterialPageRoute(builder: (_) => const PantallaFinPartida()),
|
||||
);
|
||||
},
|
||||
icon: const Icon(Icons.emoji_events),
|
||||
label: Text(l10n.seeEndResult),
|
||||
),
|
||||
return BotonFarolero(
|
||||
texto: l10n.seeEndResult,
|
||||
icono: Icons.emoji_events,
|
||||
onPressed: () {
|
||||
Navigator.pushReplacement(
|
||||
context,
|
||||
MaterialPageRoute(builder: (_) => const PantallaFinPartida()),
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
// Si era impostor, puede intentar adivinar
|
||||
if (widget.resultado.eraImpostor) {
|
||||
return Column(
|
||||
children: [
|
||||
SizedBox(
|
||||
width: double.infinity,
|
||||
height: 56,
|
||||
child: OutlinedButton.icon(
|
||||
onPressed: () {
|
||||
Navigator.pushReplacement(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (_) => const PantallaAdivinanza(),
|
||||
),
|
||||
);
|
||||
},
|
||||
icon: const Text('🎯', style: TextStyle(fontSize: 18)),
|
||||
label: Text(l10n.impostorGuessWord),
|
||||
),
|
||||
BotonFarolero.oscuro(
|
||||
texto: l10n.impostorGuessWord,
|
||||
icono: Icons.gps_fixed,
|
||||
onPressed: () {
|
||||
Navigator.pushReplacement(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (_) => const PantallaAdivinanza(),
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
const SizedBox(height: 12),
|
||||
SizedBox(
|
||||
width: double.infinity,
|
||||
height: 56,
|
||||
child: ElevatedButton.icon(
|
||||
onPressed: () => _siguienteRonda(context, estado),
|
||||
icon: const Icon(Icons.skip_next),
|
||||
label: Text(l10n.nextRound),
|
||||
),
|
||||
BotonFarolero(
|
||||
texto: l10n.nextRound,
|
||||
icono: Icons.skip_next,
|
||||
onPressed: () => _siguienteRonda(context, estado),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
return SizedBox(
|
||||
width: double.infinity,
|
||||
height: 56,
|
||||
child: ElevatedButton.icon(
|
||||
onPressed: () => _siguienteRonda(context, estado),
|
||||
icon: const Icon(Icons.skip_next),
|
||||
label: Text(l10n.nextRound),
|
||||
),
|
||||
return BotonFarolero(
|
||||
texto: l10n.nextRound,
|
||||
icono: Icons.skip_next,
|
||||
onPressed: () => _siguienteRonda(context, estado),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user