mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-18 16:32:16 -07:00
Fix Windows FlowWidget duplication
- Delete the item widget right away, as the delay is too great with deleteLater
This commit is contained in:
parent
497e4f1be0
commit
67b4fa7d49
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