forked from qt-creator/qt-creator
UpdateInfo: Do not show multiple update notfications
Remove existing notification before showing a new one. Otherwise checking for updates multiple times results in multiple stacked notifications. Change-Id: I1af07c005e88b297fbaebec7f5358fa46c09a84c Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -207,6 +207,7 @@ void UpdateInfoPlugin::checkForUpdatesFinished()
|
|||||||
label->setContentsMargins(0, 0, 0, 8);
|
label->setContentsMargins(0, 0, 0, 8);
|
||||||
return label;
|
return label;
|
||||||
});
|
});
|
||||||
|
Core::ICore::infoBar()->removeInfo(InstallUpdates); // remove any existing notifications
|
||||||
Core::ICore::infoBar()->unsuppressInfo(InstallUpdates);
|
Core::ICore::infoBar()->unsuppressInfo(InstallUpdates);
|
||||||
Core::ICore::infoBar()->addInfo(info);
|
Core::ICore::infoBar()->addInfo(info);
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user