mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-24 07:05:35 +00:00
A debug feature on ASControlNode to visualize tap-able areas (by adding a highlight overlay ASDisplayNode as a subnode) when addTarget:action:ControlEvent: is called. Uses hitTestSlop to get ASControlNode's UIEdgeInset and set the highlight overlay's frame to be the ASControlNode frame + edge insets. Disables clip to bounds on ASControlNode. Enabled by calling +[ASControlNode setEnableHitTestDebug:YES];
This commit is contained in:
@@ -120,6 +120,11 @@ typedef NS_OPTIONS(NSUInteger, ASControlState) {
|
||||
*/
|
||||
- (void)sendActionsForControlEvents:(ASControlNodeEvent)controlEvents withEvent:(nullable UIEvent *)event;
|
||||
|
||||
/**
|
||||
Class method to enable a visualization overlay of the tapable area on the ASControlNode. For app debugging purposes only.
|
||||
@param enabled Specify YES to make this debug feature enabled when messaging the ASControlNode class.
|
||||
*/
|
||||
+ (void)setEnableHitTestDebug:(BOOL)enable;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
Reference in New Issue
Block a user