mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
remove const from UIManager::createNode and UIManager::cloneNode
Summary: changelog: [internal] These shadow nodes are freshly created and unsealed. Return non-const. Reviewed By: NickGerleman Differential Revision: D50796024 fbshipit-source-id: 6e2a61bb03efbc6f63a489928787e645971780df
This commit is contained in:
committed by
Facebook GitHub Bot
parent
475b835e43
commit
ae85be3e92
@@ -78,7 +78,7 @@ class ComponentDescriptor {
|
||||
/*
|
||||
* Creates a new `ShadowNode` of a particular component type.
|
||||
*/
|
||||
virtual ShadowNode::Shared createShadowNode(
|
||||
virtual std::shared_ptr<ShadowNode> createShadowNode(
|
||||
const ShadowNodeFragment& fragment,
|
||||
const ShadowNodeFamily::Shared& family) const = 0;
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@ class ConcreteComponentDescriptor : public ComponentDescriptor {
|
||||
return ShadowNodeT::BaseTraits();
|
||||
}
|
||||
|
||||
ShadowNode::Shared createShadowNode(
|
||||
std::shared_ptr<ShadowNode> createShadowNode(
|
||||
const ShadowNodeFragment& fragment,
|
||||
const ShadowNodeFamily::Shared& family) const override {
|
||||
auto shadowNode =
|
||||
|
||||
@@ -62,7 +62,7 @@ UIManager::~UIManager() {
|
||||
<< ").";
|
||||
}
|
||||
|
||||
ShadowNode::Shared UIManager::createNode(
|
||||
std::shared_ptr<ShadowNode> UIManager::createNode(
|
||||
Tag tag,
|
||||
const std::string& name,
|
||||
SurfaceId surfaceId,
|
||||
@@ -109,7 +109,7 @@ ShadowNode::Shared UIManager::createNode(
|
||||
return shadowNode;
|
||||
}
|
||||
|
||||
ShadowNode::Shared UIManager::cloneNode(
|
||||
std::shared_ptr<ShadowNode> UIManager::cloneNode(
|
||||
const ShadowNode& shadowNode,
|
||||
const ShadowNode::SharedListOfShared& children,
|
||||
const RawProps* rawProps) const {
|
||||
|
||||
@@ -130,14 +130,14 @@ class UIManager final : public ShadowTreeDelegate {
|
||||
const RootShadowNode::Shared& oldRootShadowNode,
|
||||
const RootShadowNode::Unshared& newRootShadowNode) const override;
|
||||
|
||||
ShadowNode::Shared createNode(
|
||||
std::shared_ptr<ShadowNode> createNode(
|
||||
Tag tag,
|
||||
const std::string& componentName,
|
||||
SurfaceId surfaceId,
|
||||
const RawProps& props,
|
||||
const InstanceHandle::Shared& instanceHandle) const;
|
||||
|
||||
ShadowNode::Shared cloneNode(
|
||||
std::shared_ptr<ShadowNode> cloneNode(
|
||||
const ShadowNode& shadowNode,
|
||||
const ShadowNode::SharedListOfShared& children = nullptr,
|
||||
const RawProps* rawProps = nullptr) const;
|
||||
|
||||
Reference in New Issue
Block a user