play_by_seed fires NewGameRequestEvent { confirmed: false } — forces unwanted confirm dialog #27

Closed
opened 2026-05-19 18:44:35 +00:00 by funman300 · 0 comments
Owner

File

solitaire_engine/src/play_by_seed_plugin.rs lines 411–415

Description

When the player types a seed and presses Play, handle_confirm fires NewGameRequestEvent { confirmed: false }. This causes handle_new_game to spawn a second "Abandon current game?" dialog on top of the already-dismissed Play-by-Seed dialog. The player must confirm twice to start the game they explicitly requested.

The player already made an affirmative choice by clicking Play in the seed dialog — confirmed: false contradicts the user's intent.

Fix

Set confirmed: true in handle_confirm so the new game starts immediately after the seed dialog is dismissed.

## File `solitaire_engine/src/play_by_seed_plugin.rs` lines 411–415 ## Description When the player types a seed and presses Play, `handle_confirm` fires `NewGameRequestEvent { confirmed: false }`. This causes `handle_new_game` to spawn a second "Abandon current game?" dialog on top of the already-dismissed Play-by-Seed dialog. The player must confirm twice to start the game they explicitly requested. The player already made an affirmative choice by clicking Play in the seed dialog — `confirmed: false` contradicts the user's intent. ## Fix Set `confirmed: true` in `handle_confirm` so the new game starts immediately after the seed dialog is dismissed.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: funman300/Ferrous-Solitaire#27