mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-24 23:53:54 -07:00
phases toolbar improvement
This commit is contained in:
parent
a5280946c2
commit
0dbc580b8a
6 changed files with 33 additions and 18 deletions
|
|
@ -12,16 +12,16 @@ class PhaseButton : public QPushButton {
|
|||
private:
|
||||
QString phaseText;
|
||||
bool active;
|
||||
QAction *doubleClickAction;
|
||||
public:
|
||||
PhaseButton();
|
||||
PhaseButton(QIcon);
|
||||
PhaseButton(const QIcon &icon, QAction *_doubleClickAction = 0);
|
||||
void setPhaseText(const QString &_phaseText);
|
||||
QString getPhaseText() const { return phaseText; }
|
||||
void setActive(bool _active) { active = _active; update(); }
|
||||
public slots:
|
||||
void update();
|
||||
bool getActive() const { return active; }
|
||||
protected:
|
||||
void paintEvent(QPaintEvent *event);
|
||||
void mouseDoubleClickEvent(QMouseEvent *event);
|
||||
};
|
||||
|
||||
class PhasesToolbar : public QFrame {
|
||||
|
|
@ -38,6 +38,8 @@ private slots:
|
|||
signals:
|
||||
void signalSetPhase(int phase);
|
||||
void signalNextTurn();
|
||||
void signalUntapAll();
|
||||
void signalDrawCard();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue