mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-15 03:28:49 -07:00
Add card selection counter (#6685)
* feat(game): add drag selection counter overlay Display count of selected cards inside the lasso during drag selection. Count appears near cursor, repositioning to stay within selection bounds. Includes SelectionRubberBand subclass to allow label to appear above band. QRubberBand calls raise() in showEvent/changeEvent to stay on top - this subclass suppresses that behavior so dragCountLabel can be visible. Adds user setting to enable/disable the drag count overlay. * feat(game): add persistent selection counter overlay. Display total count of selected cards in bottom-right corner when multiple cards are selected. Updates on selection changes and window resize. The counter connects to QGraphicsScene::selectionChanged to stay up-to-date without requiring manual refresh. Adds user setting to enable/disable the total count overlay. --------- Co-authored-by: RickyRister <42636155+RickyRister@users.noreply.github.com>
This commit is contained in:
parent
69c046cca4
commit
fc453c68a7
9 changed files with 170 additions and 11 deletions
|
|
@ -521,9 +521,9 @@ void GameScene::startRubberBand(const QPointF &selectionOrigin)
|
|||
emit sigStartRubberBand(selectionOrigin);
|
||||
}
|
||||
|
||||
void GameScene::resizeRubberBand(const QPointF &cursorPoint)
|
||||
void GameScene::resizeRubberBand(const QPointF &cursorPoint, int selectedCount)
|
||||
{
|
||||
emit sigResizeRubberBand(cursorPoint);
|
||||
emit sigResizeRubberBand(cursorPoint, selectedCount);
|
||||
}
|
||||
|
||||
void GameScene::stopRubberBand()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue