awful.tooltip: skip set_geometry if not visible
`set_geometry` will be called in `show`, and is not necessary when the tooltip is not visible.
This commit is contained in:
parent
65e9d6d59f
commit
9bcd87c727
|
@ -130,7 +130,9 @@ end
|
||||||
-- `wibox.widget.textbox.set_text`.
|
-- `wibox.widget.textbox.set_text`.
|
||||||
tooltip.set_text = function(self, text)
|
tooltip.set_text = function(self, text)
|
||||||
self.textbox:set_text(text)
|
self.textbox:set_text(text)
|
||||||
|
if self.visible then
|
||||||
set_geometry(self)
|
set_geometry(self)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Change displayed text.
|
--- Change displayed text.
|
||||||
|
@ -140,7 +142,9 @@ end
|
||||||
-- `wibox.widget.textbox.set_markup`.
|
-- `wibox.widget.textbox.set_markup`.
|
||||||
tooltip.set_markup = function(self, text)
|
tooltip.set_markup = function(self, text)
|
||||||
self.textbox:set_markup(text)
|
self.textbox:set_markup(text)
|
||||||
|
if self.visible then
|
||||||
set_geometry(self)
|
set_geometry(self)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Change the tooltip's update interval.
|
--- Change the tooltip's update interval.
|
||||||
|
|
Loading…
Reference in New Issue