InfoBar: Do not suppress info bar if it is closed

Before the patch, any closed infobar was suppressed until Qt Creator was
restarted. With this patch the infobar will just be closed,
as naively expected. To suppress any infobar you have to click
"Do not show again".

Task-number: QTCREATORBUG-26605
Change-Id: I29645e853119286f507cba82c228f372dd80fa64
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Kimmo Leppälä <kimmo.leppala@qt.io>
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Thomas Hartmann
2021-11-24 09:51:21 +01:00
parent a9fc431bd9
commit a95a77bcfc

View File

@@ -344,7 +344,7 @@ void InfoBarDisplay::update()
if (info.m_cancelButtonCallBack)
connect(infoWidgetCloseButton, &QAbstractButton::clicked, info.m_cancelButtonCallBack);
connect(infoWidgetCloseButton, &QAbstractButton::clicked, this, [this, id] {
m_infoBar->suppressInfo(id);
m_infoBar->removeInfo(id);
});
}