Hide load from remote button in local games (#5499)

* Hide load from remote button in local games.

* Minor fix

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
Co-authored-by: ZeldaZach <zahalpern+github@gmail.com>
This commit is contained in:
BruebachL 2025-01-19 13:59:33 +01:00 committed by GitHub
parent ec0caaf421
commit 724db755af
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -65,6 +65,7 @@ DeckViewContainer::DeckViewContainer(int _playerId, TabGame *parent)
connect(sideboardLockButton, SIGNAL(stateChanged()), this, SLOT(updateSideboardLockButtonText()));
if (parentGame->getIsLocalGame()) {
loadRemoteButton->setVisible(false);
loadRemoteButton->setEnabled(false);
} else {
connect(loadRemoteButton, SIGNAL(clicked()), this, SLOT(loadRemoteDeck()));
@ -126,7 +127,7 @@ void DeckViewContainer::switchToDeckSelectView()
deckViewLayout->update();
setVisibility(loadLocalButton, true);
setVisibility(loadRemoteButton, true);
setVisibility(loadRemoteButton, !parentGame->getIsLocalGame());
setVisibility(unloadDeckButton, false);
setVisibility(readyStartButton, false);
setVisibility(sideboardLockButton, false);