@@ -61,10 +61,18 @@ class CinnamonNotificationsApplet extends Applet.TextIconApplet {
6161 if ( MessageTray . extensionsHandlingNotifications === 0 ) {
6262 this . _clear_all ( ) ;
6363 }
64+
65+ this . destroy ( ) ;
6466 }
6567
6668 _openMenu ( ) {
6769 this . _update_timestamp ( ) ;
70+
71+ this . _notificationbin . remove_all_children ( ) ;
72+ this . notifications . forEach ( notification => {
73+ global . reparentActor ( notification . actor , this . _notificationbin ) ;
74+ } ) ;
75+
6876 this . menu . toggle ( ) ;
6977 }
7078
@@ -138,8 +146,6 @@ class CinnamonNotificationsApplet extends Applet.TextIconApplet {
138146 if ( notification . _destroyed ) {
139147 this . notifications . splice ( existing_index , 1 ) ;
140148 } else {
141- notification . _inNotificationBin = true ;
142- global . reparentActor ( notification . actor , this . _notificationbin ) ;
143149 notification . _timeLabel . show ( ) ;
144150 }
145151 this . update_list ( ) ;
@@ -148,11 +154,8 @@ class CinnamonNotificationsApplet extends Applet.TextIconApplet {
148154 return ;
149155 }
150156 // Add notification to list.
151- notification . _inNotificationBin = true ;
152157 this . notifications . push ( notification ) ;
153- // Steal the notification panel.
154- this . _notificationbin . add ( notification . actor ) ;
155- notification . actor . _parent_container = this . _notificationbin ;
158+
156159 notification . actor . add_style_class_name ( 'notification-applet-padding' ) ;
157160 // Register for destruction.
158161 notification . connect ( 'scrolling-changed' , ( notif , scrolling ) => { this . menu . passEvents = scrolling } ) ;
0 commit comments