]> git.madduck.net Git - etc/awesome.git/blobdiff - widgets/mpd.lua

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

widgets fix
[etc/awesome.git] / widgets / mpd.lua
index 016f2a3a4e5de2a150e7276c810e7507601548ea..cd97b37cb5fee86377b85d2bca9e218ecbddbdc2 100644 (file)
@@ -40,7 +40,7 @@ local function worker(args)
 
     mpd.widget = wibox.widget.textbox('')
 
 
     mpd.widget = wibox.widget.textbox('')
 
-    notification_preset = {
+    mpd_notification_preset = {
         title   = "Now playing",
         timeout = 6
     }
         title   = "Now playing",
         timeout = 6
     }
@@ -73,8 +73,8 @@ local function worker(args)
 
         f:close()
 
 
         f:close()
 
-        notification_preset.text = string.format("%s (%s) - %s\n%s", mpd_now.artist,
-                                   mpd_now.album, mpd_now.date, mpd_now.title)
+        mpd_notification_preset.text = string.format("%s (%s) - %s\n%s", mpd_now.artist,
+                                       mpd_now.album, mpd_now.date, mpd_now.title)
         widget = mpd.widget
         settings()
 
         widget = mpd.widget
         settings()
 
@@ -87,7 +87,7 @@ local function worker(args)
                 os.execute(string.format("%s %q %q", mpdcover, music_dir, mpd_now.file))
 
                 mpd.id = naughty.notify({
                 os.execute(string.format("%s %q %q", mpdcover, music_dir, mpd_now.file))
 
                 mpd.id = naughty.notify({
-                    preset = notification_preset,
+                    preset = mpd_notification_preset,
                     icon = "/tmp/mpdcover.png",
                     replaces_id = mpd.id
                 }).id
                     icon = "/tmp/mpdcover.png",
                     replaces_id = mpd.id
                 }).id