mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-18 08:22:15 -07:00
Clean up game scene code.
Took 18 minutes
This commit is contained in:
parent
891e7bf6e4
commit
100b363892
2 changed files with 229 additions and 143 deletions
|
|
@ -50,6 +50,16 @@ public:
|
|||
void startRubberBand(const QPointF &selectionOrigin);
|
||||
void resizeRubberBand(const QPointF &cursorPoint);
|
||||
void stopRubberBand();
|
||||
QList<Player *> collectActivePlayers(int &firstPlayerIndex) const;
|
||||
QList<Player *> rotatePlayers(const QList<Player *> &players, int firstPlayerIndex) const;
|
||||
int determineColumnCount(int playerCount) const;
|
||||
QSizeF computeSceneSizeAndPlayerLayout(const QList<Player *> &playersPlaying, int columns);
|
||||
QList<qreal> calculateMinWidthByColumn() const;
|
||||
qreal calculateNewSceneWidth(const QSize &newSize, qreal minWidth) const;
|
||||
void resizeColumnsAndPlayers(const QList<qreal> &minWidthByColumn, qreal newWidth);
|
||||
CardZone *findTopmostZone(const QList<QGraphicsItem *> &items) const;
|
||||
CardItem *findTopmostCardInZone(const QList<QGraphicsItem *> &items, CardZone *zone) const;
|
||||
void updateHoveredCard(CardItem *newCard);
|
||||
|
||||
void registerAnimationItem(AbstractCardItem *item);
|
||||
void unregisterAnimationItem(AbstractCardItem *card);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue