barr icon indicating copy to clipboard operation
barr copied to clipboard

support for multiple monitors

Open derrickcope opened this issue 7 years ago • 0 comments

i changed part of the update! function to support my multimonitor setup. not sure if this would be helpful to you.

def desktops
  op = []
  bsp_tree["monitors"].each do |monitor|
    focused = monitor["focusedDesktopId"]
    op << " " + monitor["name"] + ":"
    monitor["desktops"].each do |desktop|
      if desktop["id"] == focused and monitor["id"] == bsp_tree["focusedMonitorId"]
        op << focused_desktop(desktop)
      else
        op << unfocused_desktop(desktop)
      end
    end
  end
  op
end

derrickcope avatar Feb 06 '18 04:02 derrickcope