Store weak ref to Notification in ToastEventHandler
This commit is contained in:
parent
ddee77fae4
commit
f4c27c6d29
9 changed files with 32 additions and 47 deletions
|
@ -20,6 +20,21 @@ Notification::~Notification() {
|
|||
delegate()->NotificationDestroyed();
|
||||
}
|
||||
|
||||
void Notification::NotificationClicked() {
|
||||
delegate()->NotificationClick();
|
||||
Destroy();
|
||||
}
|
||||
|
||||
void Notification::NotificationDismissed() {
|
||||
delegate()->NotificationClosed();
|
||||
Destroy();
|
||||
}
|
||||
|
||||
void Notification::NotificationFailed() {
|
||||
delegate()->NotificationFailed();
|
||||
Destroy();
|
||||
}
|
||||
|
||||
void Notification::Destroy() {
|
||||
presenter()->RemoveNotification(this);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue