From 82e62a0fad7cf73e4c31854aad348bb5d6735f1c Mon Sep 17 00:00:00 2001 From: Alex Kir <4k1r4.rulez@gmail.com> Date: Wed, 13 May 2015 11:36:05 +0800 Subject: [PATCH] Added function to check state of notifications Sometimes is a good idea to check if notifications are suspended, for example, for changing the icon. This function just returns the value of suspended. Closes https://github.com/awesomeWM/awesome/pull/222. --- lib/naughty/core.lua.in | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/naughty/core.lua.in b/lib/naughty/core.lua.in index 07190e64b..10f218af6 100644 --- a/lib/naughty/core.lua.in +++ b/lib/naughty/core.lua.in @@ -143,6 +143,11 @@ for s = 1, capi.screen.count() do } end +--- Notification state +function naughty.is_suspended() + return suspended +end + --- Suspend notifications function naughty.suspend() suspended = true