xorg window properties added

This commit is contained in:
milarin 2023-10-09 12:27:02 +02:00
parent 041e3540e8
commit 51d0d89897

13
node.go
View File

@ -16,7 +16,6 @@ type Node struct {
WindowRect Rect `json:"window_rect"` WindowRect Rect `json:"window_rect"`
Geometry Rect `json:"geometry"` Geometry Rect `json:"geometry"`
Name string `json:"name"` Name string `json:"name"`
XorgWindowID *int64 `json:"window"`
Nodes []Node `json:"nodes"` Nodes []Node `json:"nodes"`
FloatingNodes []Node `json:"floating_nodes"` FloatingNodes []Node `json:"floating_nodes"`
Focus []NodeID `json:"focus"` Focus []NodeID `json:"focus"`
@ -30,6 +29,10 @@ type Node struct {
InhibitIdle bool `json:"inhibit_idle"` InhibitIdle bool `json:"inhibit_idle"`
IdleInhibitors IdleInhibitors `json:"idle_inhibitors"` IdleInhibitors IdleInhibitors `json:"idle_inhibitors"`
// Xorg compatibility
XorgWindowID *int64 `json:"window"`
XorgProperties *XorgProperties `json:"window_properties"`
// NodeTypeOutput only // NodeTypeOutput only
Primary bool `json:"primary"` Primary bool `json:"primary"`
Make string `json:"make"` Make string `json:"make"`
@ -153,3 +156,11 @@ const (
OrientationHorizontal Orientation = "horizontal" OrientationHorizontal Orientation = "horizontal"
OrientationVertical Orientation = "vertical" OrientationVertical Orientation = "vertical"
) )
type XorgProperties struct {
Title string `json:"title"`
Instance string `json:"instance"`
Class string `json:"class"`
Role string `json:"window_role"`
Transient NodeID `json:"transient_for"`
}