summaryrefslogtreecommitdiff
path: root/scene/resources
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2018-05-07 16:33:12 -0300
committerGitHub <noreply@github.com>2018-05-07 16:33:12 -0300
commit2ba8b5b27c8c2a0a01eca5aa2db0e60870ff1668 (patch)
tree236605ac357a4705d38d588193c4ce7630af9e9c /scene/resources
parent3051bb8a81858b3cbb26f760e572a44a8668c155 (diff)
parent91eb80041d588ef22926422ae2fc39f375e11aec (diff)
Merge pull request #17828 from bojidar-bg/17779-progressbar-minimum-size
Fix StyleBox ignoring region rect and ProgressBar using center size
Diffstat (limited to 'scene/resources')
-rw-r--r--scene/resources/style_box.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/resources/style_box.cpp b/scene/resources/style_box.cpp
index ad5a0fd9ab..7da65ac984 100644
--- a/scene/resources/style_box.cpp
+++ b/scene/resources/style_box.cpp
@@ -186,7 +186,7 @@ Size2 StyleBoxTexture::get_center_size() const {
if (texture.is_null())
return Size2();
- return texture->get_size() - get_minimum_size();
+ return region_rect.size - get_minimum_size();
}
void StyleBoxTexture::set_expand_margin_size(Margin p_expand_margin, float p_size) {