| 5809 | |
| 5810 | // Used to store ancestor hierarchy in top level callback |
| 5811 | function getTopLevelCallbackBookKeeping(topLevelType, nativeEvent, targetInst) { |
| 5812 | if (callbackBookkeepingPool.length) { |
| 5813 | var instance = callbackBookkeepingPool.pop(); |
| 5814 | instance.topLevelType = topLevelType; |
| 5815 | instance.nativeEvent = nativeEvent; |
| 5816 | instance.targetInst = targetInst; |
| 5817 | return instance; |
| 5818 | } |
| 5819 | return { |
| 5820 | topLevelType: topLevelType, |
| 5821 | nativeEvent: nativeEvent, |
| 5822 | targetInst: targetInst, |
| 5823 | ancestors: [] |
| 5824 | }; |
| 5825 | } |
| 5826 | |
| 5827 | function releaseTopLevelCallbackBookKeeping(instance) { |
| 5828 | instance.topLevelType = null; |