Add remote commands support

This commit is contained in:
2025-10-29 17:27:23 +00:00
parent 11806119df
commit a21e716475
13 changed files with 238 additions and 115 deletions
+7
View File
@@ -20,12 +20,15 @@ def handle_event(event)
when :create
$all_windows << event[:window]
return unless event[:override_redirect].zero?
X.subscribe event[:window]
when :closed
$all_windows.delete event[:window]
$windows[event[:window]]&.delete
X.focus $root
when :enter
@@ -37,6 +40,10 @@ def handle_event(event)
if $windows[event[:window]].nil?
monitor[:workspaces][monitor[:selected_workspace]].create event[:window]
X.show event[:window]
$all_windows.each do |window|
above = `xprop -id #{window} _NET_WM_STATE`
X.send_to_top window if above.include?("ABOVE")
end
end