mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-30 18:43:55 -07:00
Fix Windows FlowWidget duplication (#5460)
- Delete the item widget right away, as the delay is too great with deleteLater
This commit is contained in:
parent
767e83c879
commit
6309e7e318
1 changed files with 2 additions and 2 deletions
|
|
@ -102,8 +102,8 @@ void FlowWidget::clearLayout()
|
||||||
if (flowLayout != nullptr) {
|
if (flowLayout != nullptr) {
|
||||||
QLayoutItem *item;
|
QLayoutItem *item;
|
||||||
while ((item = flowLayout->takeAt(0)) != nullptr) {
|
while ((item = flowLayout->takeAt(0)) != nullptr) {
|
||||||
item->widget()->deleteLater(); // Delete the widget
|
delete item->widget(); // Delete the widget
|
||||||
delete item; // Delete the layout item
|
delete item; // Delete the layout item
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (scrollArea->horizontalScrollBarPolicy() != Qt::ScrollBarAlwaysOff &&
|
if (scrollArea->horizontalScrollBarPolicy() != Qt::ScrollBarAlwaysOff &&
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue