This commit is contained in:
Insality
2024-10-14 11:32:53 +03:00
parent 3c9f539376
commit d11aeb6b18
5 changed files with 62 additions and 17 deletions

View File

@@ -52,7 +52,7 @@ end
local function setup_slider(self)
local slider = self.druid:new_slider("slider_pin", vmath.vector3(95, 0, 0), function(_, value)
gui.set_text(gui.get_node("text_progress_slider"), math.ceil(value * 100) .. "%")
end)
end) --[[@as druid.slider]]
slider:set(0.2)
end

View File

@@ -54,9 +54,10 @@ function init(self)
self.druid:new_scroll("children_scroll_3", "children_scroll_content_3")
-- Content with less size than view
self.druid:new_scroll("scroll_smaller_view", "scroll_smaller_content")
:set_extra_stretch_size(0)
:set_inert(false)
local small_scroll = self.druid:new_scroll("scroll_smaller_view", "scroll_smaller_content") --[[@as druid.scroll]]
small_scroll.style.SMALL_CONTENT_SCROLL = true
small_scroll:set_extra_stretch_size(0) -- it also update scroll size due the change of SMALL_CONTENT_SCROLL
small_scroll:set_inert(false)
-- Scroll with points of interests
self.druid:new_scroll("scroll_with_points", "scroll_with_points_content")