summaryrefslogtreecommitdiff
path: root/scene/gui
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2018-07-29 12:46:53 -0300
committerJuan Linietsky <reduzio@gmail.com>2018-07-29 12:48:17 -0300
commitc752c2642720820e17ed7d0ca223f60aee3b2739 (patch)
tree8e1c36bf91d8f34c8ca58dbb61496bca14d19c3c /scene/gui
parent0fcc28b6f370c478d1990af51070f9fbee531c20 (diff)
Expose _clips_input as a virtual function, closes #15358
Diffstat (limited to 'scene/gui')
-rw-r--r--scene/gui/control.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp
index 12aeed1520..18f06eca31 100644
--- a/scene/gui/control.cpp
+++ b/scene/gui/control.cpp
@@ -663,6 +663,9 @@ void Control::_notification(int p_notification) {
bool Control::clips_input() const {
+ if (get_script_instance()) {
+ return get_script_instance()->call(SceneStringNames::get_singleton()->_clips_input);
+ }
return false;
}
bool Control::has_point(const Point2 &p_point) const {
@@ -2828,6 +2831,7 @@ void Control::_bind_methods() {
BIND_VMETHOD(MethodInfo(Variant::BOOL, "can_drop_data", PropertyInfo(Variant::VECTOR2, "position"), PropertyInfo(Variant::NIL, "data")));
BIND_VMETHOD(MethodInfo("drop_data", PropertyInfo(Variant::VECTOR2, "position"), PropertyInfo(Variant::NIL, "data")));
BIND_VMETHOD(MethodInfo(Variant::OBJECT, "_make_custom_tooltip", PropertyInfo(Variant::STRING, "for_text")));
+ BIND_VMETHOD(MethodInfo(Variant::BOOL, "_clips_input"));
ADD_GROUP("Anchor", "anchor_");
ADD_PROPERTYI(PropertyInfo(Variant::REAL, "anchor_left", PROPERTY_HINT_RANGE, "0,1,0.01"), "_set_anchor", "get_anchor", MARGIN_LEFT);