mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-15 03:28:49 -07:00
Sorting views
+ When viewing a sorted view (like revealing hand, or looking at library), the cards will now be sorted in columns based on the main card type. + Settings are now saved.
This commit is contained in:
parent
8fee9c6c4b
commit
e4e3a1d2e5
6 changed files with 136 additions and 49 deletions
|
|
@ -19,12 +19,17 @@ private:
|
|||
CardZone *origZone;
|
||||
bool revealZone, writeableRevealZone;
|
||||
bool sortByName, sortByType;
|
||||
bool pileView;
|
||||
public:
|
||||
ZoneViewZone(Player *_p, CardZone *_origZone, int _numberCards = -1, bool _revealZone = false, bool _writeableRevealZone = false, QGraphicsItem *parent = 0);
|
||||
~ZoneViewZone();
|
||||
QRectF boundingRect() const;
|
||||
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
|
||||
void reorganizeCards();
|
||||
|
||||
void setPileViewPositions(int cardCount, CardList &cardsToDisplay, int &typeColumn, int &longestRow);
|
||||
|
||||
|
||||
void initializeCards(const QList<const ServerInfo_Card *> &cardList = QList<const ServerInfo_Card *>());
|
||||
void removeCard(int position);
|
||||
int getNumberCards() const { return numberCards; }
|
||||
|
|
@ -36,6 +41,7 @@ public:
|
|||
public slots:
|
||||
void setSortByName(int _sortByName);
|
||||
void setSortByType(int _sortByType);
|
||||
void setPileView(int _pileView);
|
||||
private slots:
|
||||
void zoneDumpReceived(const Response &r);
|
||||
signals:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue