awful.client.property.set: emit property:: signals only on change
Emit "propery::" signals and call `c:set_xproperty` only if the properties new value has changed.
This commit is contained in:
parent
ae7c7ff382
commit
bd885f59f5
|
@ -937,11 +937,13 @@ function client.property.set(c, prop, value)
|
|||
if not client.data.properties[c] then
|
||||
client.data.properties[c] = {}
|
||||
end
|
||||
if client.data.properties[c][prop] ~= value then
|
||||
if client.data.persistent_properties_registered[prop] then
|
||||
c:set_xproperty("awful.client.property." .. prop, value)
|
||||
end
|
||||
client.data.properties[c][prop] = value
|
||||
c:emit_signal("property::" .. prop)
|
||||
end
|
||||
end
|
||||
|
||||
--- Set a client property to be persistent across restarts (via X properties).
|
||||
|
|
Loading…
Reference in New Issue