From 0f9c27c19a73a71dc400af90cd47479d0286b8fa Mon Sep 17 00:00:00 2001 From: Sasha Koshka Date: Sun, 26 May 2024 15:20:11 -0400 Subject: [PATCH] Fix ContainerBox's SetTexture methods --- containerbox.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/containerbox.go b/containerbox.go index 378bbb9..5321014 100644 --- a/containerbox.go +++ b/containerbox.go @@ -36,9 +36,15 @@ func (this *containerBox) SetColor (c color.Color) { this.invalidateTransparentChildren() } -func (this *containerBox) SetTexture (texture canvas.Texture) { +func (this *containerBox) SetTextureTile (texture canvas.Texture) { if this.texture == texture { return } - this.box.SetTexture(texture) + this.box.SetTextureTile(texture) + this.invalidateTransparentChildren() +} + +func (this *containerBox) SetTextureCenter (texture canvas.Texture) { + if this.texture == texture { return } + this.box.SetTextureTile(texture) this.invalidateTransparentChildren() }