MCPcopy Create free account
hub / github.com/axmolengine/axmol / _containsTouchPoint

Function _containsTouchPoint

core/ui/UITextFieldEx.cpp:63–77  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

61}
62
63static bool _containsTouchPoint(ax::Node* target, ax::Touch* touch)
64{
65 assert(target != nullptr);
66
67 ax::Point pt = target->convertTouchToNodeSpace(touch);
68
69 const Vec2& size = target->getContentSize();
70
71 ax::Rect rc(0, 0, size.width, size.height);
72
73 bool contains = (rc.containsPoint(pt));
74
75 // AXLOGD("check {:#x} coordinate:({}, {}), contains:{}", target, pt.x, pt.y, contains);
76 return contains;
77}
78
79static bool engine_inj_containsPoint(ax::Node* target, const ax::Vec2& worldPoint)
80{

Callers 1

enableIMEMethod · 0.85

Calls 3

getContentSizeMethod · 0.45
containsPointMethod · 0.45

Tested by

no test coverage detected