gerrit widget - place popup close to the parent widget

This commit is contained in:
Pavel Makhov 2019-10-03 22:59:40 -04:00
parent 79e22c6940
commit 0ec62ab51e
1 changed files with 5 additions and 2 deletions

View File

@ -170,8 +170,11 @@ local function worker(args)
awful.util.table.join( awful.util.table.join(
awful.button({}, 1, function() awful.button({}, 1, function()
gerrit_widget:set_unseen_review(false) gerrit_widget:set_unseen_review(false)
awful.placement.top_right(popup, { margins = { top = 25, right = 10}, parent = awful.screen.focused() }) if popup.visible then
popup.visible = not popup.visible popup.visible = not popup.visible
else
popup:move_next_to(mouse.current_widget_geometry)
end
end) end)
) )
) )