Pass layout context for Event::LayoutPassStart
Summary: Adds the layout context pointer when publishing `Event::LayoutPassStart`. Reviewed By: SidharthGuglani Differential Revision: D15754425 fbshipit-source-id: 6295ae1ebec9eab72a79c43bc1cb0e05a6d7ae68
This commit is contained in:
committed by
Facebook Github Bot
parent
204e849218
commit
19fd066507
@@ -4013,7 +4013,7 @@ void YGNodeCalculateLayoutWithContext(
|
||||
void* layoutContext) {
|
||||
|
||||
#ifdef YG_ENABLE_EVENTS
|
||||
Event::publish<Event::LayoutPassStart>(node);
|
||||
Event::publish<Event::LayoutPassStart>(node, {layoutContext});
|
||||
#endif
|
||||
// unique pointer to allow ending the marker early
|
||||
std::unique_ptr<marker::MarkerSection<YGMarkerLayout>> marker{
|
||||
|
@@ -72,6 +72,11 @@ struct Event::TypedData<Event::NodeDeallocation> {
|
||||
YGConfig* config;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct Event::TypedData<Event::LayoutPassStart> {
|
||||
void* layoutContext;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct Event::TypedData<Event::LayoutPassEnd> {
|
||||
void* layoutContext;
|
||||
|
Reference in New Issue
Block a user