summaryrefslogtreecommitdiff
path: root/scene/gui
diff options
context:
space:
mode:
authorGeequlim <geequlim@gmail.com>2016-06-04 04:04:44 +0800
committerGeequlim <geequlim@gmail.com>2016-06-05 00:45:53 +0800
commit9546b2ffd4a73001b4e00248b8f7dc893c133a06 (patch)
tree80c9510abea02c399d03b5b15b8dd153b07a8440 /scene/gui
parentdc3cef7c4d7d596dd2e6a171a0912971c21df89b (diff)
Add plugin to pick texture region and patch margins for Patch9Frame
Diffstat (limited to 'scene/gui')
-rw-r--r--scene/gui/patch_9_frame.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/scene/gui/patch_9_frame.cpp b/scene/gui/patch_9_frame.cpp
index 90565bfcb1..3ecee7328b 100644
--- a/scene/gui/patch_9_frame.cpp
+++ b/scene/gui/patch_9_frame.cpp
@@ -95,6 +95,20 @@ void Patch9Frame::set_patch_margin(Margin p_margin,int p_size) {
margin[p_margin]=p_size;
update();
minimum_size_changed();
+ switch (p_margin) {
+ case MARGIN_LEFT:
+ _change_notify("patch_margin/left");
+ break;
+ case MARGIN_TOP:
+ _change_notify("patch_margin/top");
+ break;
+ case MARGIN_RIGHT:
+ _change_notify("patch_margin/right");
+ break;
+ case MARGIN_BOTTOM:
+ _change_notify("patch_margin/bottom");
+ break;
+ }
}
int Patch9Frame::get_patch_margin(Margin p_margin) const{