servatrice/cockatrice
Basile Clement 00c9efe541
Enable buttons for current game when receiving server response (#4737)
* Enable buttons for current game when receiving server response

Previously, upon joining a game, we were unconditionally re-enabling the
"Join" button in the lobby, even if it was not enabled in the first
place, causing #4698. This could also lead to issues where if the user
selects a different game after joining (which they can do in case of
e.g. network connectivity issues), the "Join as spectator" button could
get incorrectly disabled.

This fixes #4698 by re-enabling the buttons based on the state of the
currently selected game at the time the response is received. This also
avoids inconsistencies if a different game has been selected in between
joining and receiving a response from the server.

* Typo: enable gameButton in enableButtons

The "create game" button was incorrectly being disabled in enableButtons
whereas (as the name indicates) it should have been enabled

* Remove misleading comment about race conditions
2023-02-06 13:49:45 +01:00
..
resources add kosovo flag (#4597) 2022-03-19 20:07:40 -05:00
sounds Add cmake format (#4618) 2022-05-08 21:22:43 +02:00
src Enable buttons for current game when receiving server response (#4737) 2023-02-06 13:49:45 +01:00
themes Add cmake format (#4618) 2022-05-08 21:22:43 +02:00
translations Apply translations in it (#4714) 2022-12-11 23:42:51 +01:00
.qdevelop icon_draw and icon_untap added, icon_general and icon_messages modified 2009-07-31 13:37:16 +02:00
CMakeLists.txt FIX #4665: Address missing sound on Qt5 Builds (#4733) 2023-02-05 22:05:47 -05:00
cockatrice.desktop Updated Spanish translation 2011-07-16 11:38:57 +02:00
cockatrice.qrc add kosovo flag (#4597) 2022-03-19 20:07:40 -05:00
cockatrice.rc Included uninstaller for Windows version 2010-09-17 15:26:07 +02:00
cockatrice_en@source.ts Support Qt6, Min Qt5.8, Fix Win32, Fix Servatrice 2022-05-06 17:31:08 -04:00