Skip to content

Commit bf466e8

Browse files
authored
Fix the stub for layerActionForKey: to let CA continue the search (#1441)
* Fix the stub for layerActionForKey: to let CA continue the search * Kick CI
1 parent d970dc3 commit bf466e8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Source/ASDisplayNode.mm

+4-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,10 @@ BOOL ASDisplayNodeNeedsSpecialPropertiesHandling(BOOL isSynchronous, BOOL isLaye
106106
void StubImplementationWithNoArgs(id receiver, SEL _cmd) {}
107107
void StubImplementationWithSizeRange(id receiver, SEL _cmd, ASSizeRange sr) {}
108108
void StubImplementationWithTwoInterfaceStates(id receiver, SEL _cmd, ASInterfaceState s0, ASInterfaceState s1) {}
109-
id StubLayerActionImplementation(id receiver, SEL _cmd, NSString *key) { return (id)kCFNull; }
109+
110+
/// Returning nil here won't trigger unwanted default actions, because we override
111+
/// +defaultActionForKey: to return kCFNull.
112+
id StubLayerActionImplementation(id receiver, SEL _cmd, NSString *key) { return nil; }
110113

111114
/**
112115
* Returns ASDisplayNodeFlags for the given class/instance. instance MAY BE NIL.

0 commit comments

Comments
 (0)