summaryrefslogtreecommitdiff
path: root/engine/UI/Menu.go
diff options
context:
space:
mode:
authorPhyscik <mynameisgennadiy@vk.com>2026-01-30 03:04:43 +0500
committerPhyscik <mynameisgennadiy@vk.com>2026-01-30 03:04:43 +0500
commit95b7170acdfa73c5842db002ec64f78125fe2f90 (patch)
treebcf1255a4133e53888faf48d04a6cf1740441178 /engine/UI/Menu.go
parent45b7d0ce612921729d925a7111e4d1aeba3ef849 (diff)
Text formation
Diffstat (limited to 'engine/UI/Menu.go')
-rw-r--r--engine/UI/Menu.go22
1 files changed, 4 insertions, 18 deletions
diff --git a/engine/UI/Menu.go b/engine/UI/Menu.go
index c376839..e046a0e 100644
--- a/engine/UI/Menu.go
+++ b/engine/UI/Menu.go
@@ -60,6 +60,10 @@ func (base *Menu) Create(manager *coreobjects.SceneManager) {
base.manager = manager
base.cache = &layoutCache{}
base.generateLayout()
+
+ for _, v := range base.Rows {
+ v.Init(base)
+ }
}
func (base *Menu) Destroy() {
@@ -145,21 +149,3 @@ func (base *Menu) getWeightToPixelRatio() float32 {
func (base *Menu) GetMousePosition() rl.Vector2 {
return rl.GetMousePosition()
}
-
-type GridRow struct {
- // A portion of the screen the row will occupy
- HeightWeight float32
- // The objects that lay in this row
- Objects []UIElement
-
- location rl.Rectangle
-}
-
-func (base *GridRow) Draw(span rl.Rectangle) {
- // TODO: Add horizontal spacing
- for _, v := range base.Objects {
- v.Draw(&span)
- }
-}
-
-