File tree Expand file tree Collapse file tree 1 file changed +6
-11
lines changed
ios/fabric/cpp/react/renderer/components/RNDateTimePicker Expand file tree Collapse file tree 1 file changed +6
-11
lines changed Original file line number Diff line number Diff line change @@ -18,20 +18,15 @@ class RNDateTimePickerComponentDescriptor final : public ConcreteComponentDescri
1818 public:
1919 using ConcreteComponentDescriptor::ConcreteComponentDescriptor;
2020
21- void adopt (ShadowNode::Unshared const & shadowNode) const override {
22- react_native_assert (std::dynamic_pointer_cast <RNDateTimePickerShadowNode>(shadowNode) );
23- auto pickerShadowNode = std::static_pointer_cast<RNDateTimePickerShadowNode>(shadowNode );
21+ void adopt (ShadowNode& shadowNode) const override {
22+ auto & pickerShadowNode = static_cast <RNDateTimePickerShadowNode& >(shadowNode);
23+ auto & layoutableShadowNode = static_cast <YogaLayoutableShadowNode&>(pickerShadowNode );
2424
25- react_native_assert (
26- std::dynamic_pointer_cast<YogaLayoutableShadowNode>(pickerShadowNode));
27- auto layoutableShadowNode =
28- std::static_pointer_cast<YogaLayoutableShadowNode>(pickerShadowNode);
29-
30- auto state = std::static_pointer_cast<const RNDateTimePickerShadowNode::ConcreteState>(shadowNode->getState ());
25+ auto state = std::static_pointer_cast<const RNDateTimePickerShadowNode::ConcreteState>(shadowNode.getState ());
3126 auto stateData = state->getData ();
32-
27+
3328 if (stateData.frameSize .width != 0 && stateData.frameSize .height != 0 ) {
34- layoutableShadowNode-> setSize (Size{stateData.frameSize .width , stateData.frameSize .height });
29+ layoutableShadowNode. setSize (Size{stateData.frameSize .width , stateData.frameSize .height });
3530 }
3631
3732 ConcreteComponentDescriptor::adopt (shadowNode);
You can’t perform that action at this time.
0 commit comments