aboutsummaryrefslogtreecommitdiff
path: root/.config/awesome/services
diff options
context:
space:
mode:
Diffstat (limited to '.config/awesome/services')
-rw-r--r--.config/awesome/services/dnd.lua18
-rw-r--r--.config/awesome/services/time.lua18
2 files changed, 36 insertions, 0 deletions
diff --git a/.config/awesome/services/dnd.lua b/.config/awesome/services/dnd.lua
new file mode 100644
index 0000000..d64583c
--- /dev/null
+++ b/.config/awesome/services/dnd.lua
@@ -0,0 +1,18 @@
+local gobject = require "gears.object"
+
+local inner = false
+
+local M = gobject {
+ class = {
+ set_dnd = function(self, value)
+ inner = value
+ self:emit_signal("dnd", inner)
+ end,
+ get_dnd = function()
+ return inner
+ end
+ },
+ enable_properties = true,
+}
+
+return M
diff --git a/.config/awesome/services/time.lua b/.config/awesome/services/time.lua
new file mode 100644
index 0000000..ec33b31
--- /dev/null
+++ b/.config/awesome/services/time.lua
@@ -0,0 +1,18 @@
+local gobject = require "gears.object"
+
+local current = os.date "*t"
+
+local M = gobject {
+ class = {
+ update_current_date = function(self)
+ current = os.date "*t"
+ self:emit_signal("current", current)
+ end,
+ get_current_date = function()
+ return current
+ end
+ },
+ enable_properties = true,
+}
+
+return M