drawable: Add more data to the find_widgets metadata table

This commit is contained in:
Emmanuel Lepage Vallee 2016-07-23 00:57:29 -04:00
parent 2e827202ec
commit c159ad3ab2
2 changed files with 11 additions and 1 deletions

View File

@ -68,6 +68,8 @@
-- @tparam number geometry.width The widget
-- @tparam number geometry.height The height
-- @tparam drawable geometry.drawable The `drawable`
-- @tparam table geometry.matrix_to_parent The relative `gears.matrix`
-- @tparam table geometry.matrix_to_device The absolute `gears.matrix`
-- @see mouse
--- When a mouse button is released over the widget.
@ -85,6 +87,8 @@
-- @tparam number geometry.width The widget
-- @tparam number geometry.height The height
-- @tparam drawable geometry.drawable The `drawable`
-- @tparam table geometry.matrix_to_parent The relative `gears.matrix`
-- @tparam table geometry.matrix_to_device The absolute `gears.matrix`
-- @see mouse
--- When the mouse enter a widget.
@ -96,6 +100,8 @@
-- @tparam number geometry.width The widget
-- @tparam number geometry.height The height
-- @tparam drawable geometry.drawable The `drawable`
-- @tparam table geometry.matrix_to_parent The relative `gears.matrix`
-- @tparam table geometry.matrix_to_device The absolute `gears.matrix`
-- @see mouse
--- When the mouse leave a widget.
@ -107,4 +113,6 @@
-- @tparam number geometry.width The widget
-- @tparam number geometry.height The height
-- @tparam drawable geometry.drawable The `drawable`
-- @tparam table geometry.matrix_to_parent The relative `gears.matrix`
-- @tparam table geometry.matrix_to_device The absolute `gears.matrix`
-- @see mouse

View File

@ -170,7 +170,9 @@ local function find_widgets(_drawable, result, _hierarchy, x, y)
0, 0, width, height)
table.insert(result, {
x = x3, y = y3, width = w3, height = h3,
drawable = _drawable, widget = _hierarchy:get_widget()
drawable = _drawable, widget = _hierarchy:get_widget(),
matrix_to_device = _hierarchy:get_matrix_to_device(),
matrix_to_parent = _hierarchy:get_matrix_to_parent(),
})
end
for _, child in ipairs(_hierarchy:get_children()) do