Otherwise the positioner will get completely confused.
When a notification is closed, the popup will already be closed in response to sourceRemoved.
Also, when triggering an action, call closePopup instead of hiding the popup.
(cherry picked from commit b97fdfa293dd4de59046c19f08aa6a3b940a790c)