Fix team select buttons sometimes not having the full width (
bug #737)
--- a/QTfrontend/ui/widget/frameTeam.cpp Tue May 14 18:04:15 2019 +0200
+++ b/QTfrontend/ui/widget/frameTeam.cpp Tue May 14 19:46:43 2019 +0200
@@ -163,3 +163,11 @@
setStyleSheet("FrameTeams{ border: transparent }");
}
}
+
+void FrameTeams::resizeEvent(QResizeEvent * event)
+{
+ Q_UNUSED(event);
+
+ QResizeEvent* pevent=new QResizeEvent(parentWidget()->size(), parentWidget()->size());
+ QCoreApplication::postEvent(parentWidget(), pevent);
+}
--- a/QTfrontend/ui/widget/frameTeam.h Tue May 14 18:04:15 2019 +0200
+++ b/QTfrontend/ui/widget/frameTeam.h Tue May 14 19:46:43 2019 +0200
@@ -53,6 +53,9 @@
void addTeam(HWTeam team, bool willPlay);
void removeTeam(HWTeam team);
+ protected:
+ virtual void resizeEvent(QResizeEvent * event);
+
private:
int currentColor;