Commit Graph

2 Commits

Author SHA1 Message Date
Emmanuel Lepage Vallee 9dcfde32e0 naughty: Never hold a strong reference to the notification in the box.
luajit was failing to GC the notification about 5% of the time. This
commit stores all widget notifications in a weak table and don't let
any lambda access the parent object notification object.

Each of those changes reduces the failure rate. There might still be
a couple in there, but the test passed 200x on my laptop with 100%
success rate.
2021-10-31 19:30:17 -07:00
Emmanuel Lepage Vallee 6e50ee2a41 naughty: Add a shared default widget_template for the notifications.
This will be shared by the notifications stored in a wibox/wibar and the
ones using a popup. It extends the constraint and margins container
to take care of some boilerplate code. While other widgets have their
own public API, those 2 are private since they are not different enough
to warrent a new public module.
2019-06-08 18:56:08 -04:00