Do not cache the tag name.

This commit is contained in:
Xinhao Yuan 2022-06-15 23:33:31 -04:00
parent 7b472770ee
commit 958f989e58
1 changed files with 2 additions and 7 deletions

View File

@ -122,14 +122,9 @@ function module.set_geometry(c, area_lu, area_rd, useless_gap, border_width)
end
end
-- TODO: the string need to be updated when its screen geometry changed.
local function get_machi_tag_string(tag)
if tag.machi_tag_string == nil then
tag.machi_tag_string =
tostring(tag.screen.geometry.width) .. "x" .. tostring(tag.screen.geometry.height) .. "+" ..
return tostring(tag.screen.geometry.width) .. "x" .. tostring(tag.screen.geometry.height) .. "+" ..
tostring(tag.screen.geometry.x) .. "+" .. tostring(tag.screen.geometry.y) .. '+' .. tag.name
end
return tag.machi_tag_string
end
local function sanitize_geometry(geo, parent_area)