diff --git a/Source/ASDisplayNodeExtras.mm b/Source/ASDisplayNodeExtras.mm index 2839e1a6c..385343ae6 100644 --- a/Source/ASDisplayNodeExtras.mm +++ b/Source/ASDisplayNodeExtras.mm @@ -70,7 +70,7 @@ extern ASInterfaceState ASInterfaceStateForDisplayNode(ASDisplayNode *displayNod // Directly clear the visible bit if we are not in a window. This means that the interface state is, // if not already, about to be set to invisible as it is not possible for an element to be visible // while outside of a window. - ASInterfaceState interfaceState = displayNode.interfaceState; + ASInterfaceState interfaceState = displayNode.pendingInterfaceState; return (window == nil ? (interfaceState &= (~ASInterfaceStateVisible)) : interfaceState); } else { // For not range managed nodes we might be on our own to try to guess if we're visible.