Skip to content

Commit 5a1cef6

Browse files
committed
allow to override default player
1 parent 10aeeb7 commit 5a1cef6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

mpris-widget/init.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ local wibox = require("wibox")
1212
local gears = require("gears")
1313

1414
local playerctl = {
15-
player_name = 'mpv',
15+
player_name = nil,
1616
}
1717

1818
function playerctl:set_player(name)
@@ -191,6 +191,8 @@ local function worker(user_args)
191191
local library_icon = args.library_icon or path_to_icons .. "/symbolic/places/folder-music-symbolic.svg"
192192
local popup_width = args.popup_width or 300
193193

194+
playerctl.player_name = args.default_player or 'mpv'
195+
194196
local icon = wibox.widget {
195197
widget = wibox.widget.imagebox,
196198
image = play_icon

0 commit comments

Comments
 (0)