delete overloaded signal in PendingCommand (#5477)

* remove overloaded signal since no one was using it

* remove usages of qOverload

* turns out new slot/signal syntax can ignore extra params
This commit is contained in:
RickyRister 2025-01-15 05:16:06 -08:00 committed by GitHub
parent 3a740f0bde
commit 2d02955f8b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 21 additions and 39 deletions

View file

@ -194,9 +194,7 @@ void GameSelector::actCreate()
updateTitle();
}
void GameSelector::checkResponse(const Response &response,
const CommandContainer & /* commandContainer */,
const QVariant & /* extraData */)
void GameSelector::checkResponse(const Response &response)
{
// NB: We re-enable buttons for the currently selected game, which may not
// be the same game as the one for which we are processing a response.
@ -274,8 +272,7 @@ void GameSelector::actJoin()
}
PendingCommand *pend = r->prepareRoomCommand(cmd);
connect(pend, qOverload<const Response &, const CommandContainer &, const QVariant &>(&PendingCommand::finished),
this, &GameSelector::checkResponse);
connect(pend, &PendingCommand::finished, this, &GameSelector::checkResponse);
r->sendRoomCommand(pend);
disableButtons();

View file

@ -29,7 +29,7 @@ private slots:
void actCreate();
void actJoin();
void actSelectedGameChanged(const QModelIndex &current, const QModelIndex &previous);
void checkResponse(const Response &response, const CommandContainer &, const QVariant &);
void checkResponse(const Response &response);
void ignoreListReceived(const QList<ServerInfo_User> &_ignoreList);
void processAddToListEvent(const Event_AddToList &event);

View file

@ -77,9 +77,7 @@ void ZoneViewZone::initializeCards(const QList<const ServerInfo_Card *> &cardLis
cmd.set_is_reversed(isReversed);
PendingCommand *pend = player->prepareGameCommand(cmd);
connect(pend,
qOverload<const Response &, const CommandContainer &, const QVariant &>(&PendingCommand::finished),
this, &ZoneViewZone::zoneDumpReceived);
connect(pend, &PendingCommand::finished, this, &ZoneViewZone::zoneDumpReceived);
player->sendGameCommand(pend);
} else {
const CardList &c = origZone->getCards();
@ -93,9 +91,7 @@ void ZoneViewZone::initializeCards(const QList<const ServerInfo_Card *> &cardLis
}
}
void ZoneViewZone::zoneDumpReceived(const Response &r,
const CommandContainer & /* commandContainer */,
const QVariant & /* extraData */)
void ZoneViewZone::zoneDumpReceived(const Response &r)
{
const Response_DumpZone &resp = r.GetExtension(Response_DumpZone::ext);
const int respCardListSize = resp.zone_info().card_list_size();

View file

@ -95,7 +95,7 @@ public slots:
void setSortBy(CardList::SortOption _sortBy);
void setPileView(int _pileView);
private slots:
void zoneDumpReceived(const Response &r, const CommandContainer &, const QVariant &);
void zoneDumpReceived(const Response &r);
signals:
void beingDeleted();
void optimumRectChanged();