mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-12 17:14:52 -07:00
Merge branch 'master' of github.com:Daenyth/Cockatrice
This commit is contained in:
commit
db43a0609b
74 changed files with 3062 additions and 77 deletions
|
|
@ -89,4 +89,4 @@ public:
|
|||
static PendingCommand *prepareAdminCommand(const ::google::protobuf::Message &cmd);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -32,4 +32,4 @@ public:
|
|||
void removeArrowTo(ArrowItem *arrow) { arrowsTo.removeAt(arrowsTo.indexOf(arrow)); }
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -331,7 +331,6 @@ void CardItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
|
|||
if (!cardMenu->isEmpty())
|
||||
cardMenu->exec(event->screenPos());
|
||||
} else if ((event->button() == Qt::LeftButton) && !settingsCache->getDoubleClickToPlay()) {
|
||||
setCursor(Qt::OpenHandCursor);
|
||||
|
||||
bool hideCard = false;
|
||||
if (zone->getIsView()) {
|
||||
|
|
@ -345,6 +344,7 @@ void CardItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
|
|||
playCard(event->modifiers().testFlag(Qt::ShiftModifier));
|
||||
}
|
||||
|
||||
setCursor(Qt::OpenHandCursor);
|
||||
AbstractCardItem::mouseReleaseEvent(event);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -50,4 +50,4 @@ signals:
|
|||
void deleteCardInfoPopup(QString cardName);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -26,4 +26,4 @@ Q_DECLARE_METATYPE(QList<ServerInfo_User>)
|
|||
Q_DECLARE_METATYPE(Event_ReplayAdded)
|
||||
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -14,4 +14,4 @@ public:
|
|||
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -21,4 +21,4 @@ public:
|
|||
QSet<QString> getCardColors() const;
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ DlgConnect::DlgConnect(QWidget *parent)
|
|||
settings.beginGroup("server");
|
||||
|
||||
hostLabel = new QLabel(tr("&Host:"));
|
||||
hostEdit = new QLineEdit(settings.value("hostname", "play.cockatrice.de").toString());
|
||||
hostEdit = new QLineEdit(settings.value("hostname", "cockatrice.woogerworks.com").toString());
|
||||
hostLabel->setBuddy(hostEdit);
|
||||
|
||||
portLabel = new QLabel(tr("&Port:"));
|
||||
|
|
|
|||
|
|
@ -5,4 +5,4 @@
|
|||
|
||||
typedef QMap<int, QString> GameTypeMap;
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -18,4 +18,4 @@ private slots:
|
|||
void itemFromServer(const ServerMessage &item);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -20,4 +20,4 @@ public slots:
|
|||
void itemFromClient(const CommandContainer &item);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ void PhaseButton::paint(QPainter *painter, const QStyleOptionGraphicsItem * /*op
|
|||
|
||||
painter->setBrush(QColor(220 * (activeAnimationCounter / 10.0), 220 * (activeAnimationCounter / 10.0), 220 * (activeAnimationCounter / 10.0)));
|
||||
painter->setPen(Qt::gray);
|
||||
painter->drawRect(0.5, 0.5, width - 1, width - 1);
|
||||
painter->drawRect(0, 0, width - 1, width - 1);
|
||||
painter->save();
|
||||
painter->resetTransform();
|
||||
painter->drawPixmap(iconPixmap.rect().translated(round(3 * scaleFactor), round(3 * scaleFactor)), iconPixmap, iconPixmap.rect());
|
||||
|
|
@ -47,7 +47,7 @@ void PhaseButton::paint(QPainter *painter, const QStyleOptionGraphicsItem * /*op
|
|||
|
||||
painter->setBrush(QColor(0, 0, 0, 255 * ((10 - activeAnimationCounter) / 15.0)));
|
||||
painter->setPen(Qt::gray);
|
||||
painter->drawRect(0.5, 0.5, width - 1, width - 1);
|
||||
painter->drawRect(0, 0, width - 1, width - 1);
|
||||
}
|
||||
|
||||
void PhaseButton::setWidth(double _width)
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ QPixmap CountryPixmapGenerator::generatePixmap(int height, const QString &countr
|
|||
QPainter painter(&pixmap);
|
||||
svg.render(&painter, QRectF(0, 0, width, height));
|
||||
painter.setPen(Qt::black);
|
||||
painter.drawRect(0.5, 0.5, width - 1, height - 1);
|
||||
painter.drawRect(0, 0, width - 1, height - 1);
|
||||
|
||||
pmCache.insert(key, pixmap);
|
||||
return pixmap;
|
||||
|
|
|
|||
|
|
@ -35,4 +35,4 @@ public:
|
|||
AbstractCounter *addCounter(int _counterId, const QString &_name, int _value);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -31,4 +31,4 @@ public slots:
|
|||
|
||||
extern SoundEngine *soundEngine;
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -46,4 +46,4 @@ public:
|
|||
bool getLocked() const { return locked; }
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ void ToggleButton::paintEvent(QPaintEvent *event)
|
|||
painter.setPen(QPen(Qt::green, 3));
|
||||
else
|
||||
painter.setPen(QPen(Qt::red, 3));
|
||||
painter.drawRect(1.5, 1.5, width() - 3, height() - 3);
|
||||
painter.drawRect(1, 1, width() - 3, height() - 3);
|
||||
}
|
||||
|
||||
void ToggleButton::setState(bool _state)
|
||||
|
|
|
|||
|
|
@ -24,4 +24,4 @@ public slots:
|
|||
void updateInfo(const QString &userName);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -92,4 +92,4 @@ public:
|
|||
void sortItems();
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -258,7 +258,7 @@ void MainWindow::loginError(Response::ResponseCode r, QString reasonStr, quint32
|
|||
QMessageBox::critical(this, tr("Error"), bannedStr);
|
||||
break;
|
||||
}
|
||||
case Response::RespUserIsBanned:
|
||||
case Response::RespUsernameInvalid:
|
||||
QMessageBox::critical(this, tr("Error"), tr("Invalid username."));
|
||||
break;
|
||||
default:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue