Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ void SurfaceHandler::start() const noexcept {
if (!parameters.moduleName.empty()) {
link_.uiManager->startSurface(
std::move(shadowTree),
parameters.moduleName,
parameters.props,
std::move(parameters.moduleName),
std::move(parameters.props),
parameters_.displayMode);
} else {
link_.uiManager->startEmptySurface(std::move(shadowTree));
Expand Down Expand Up @@ -118,8 +118,8 @@ void SurfaceHandler::setDisplayMode(DisplayMode displayMode) const noexcept {

link_.uiManager->setSurfaceProps(
parameters.surfaceId,
parameters.moduleName,
parameters.props,
std::move(parameters.moduleName),
std::move(parameters.props),
parameters.displayMode);

applyDisplayMode(displayMode);
Expand Down Expand Up @@ -164,8 +164,8 @@ void SurfaceHandler::setProps(const folly::dynamic& props) const noexcept {
if (link_.status == Status::Running) {
link_.uiManager->setSurfaceProps(
parameters.surfaceId,
parameters.moduleName,
parameters.props,
std::move(parameters.moduleName),
std::move(parameters.props),
parameters.displayMode);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,8 @@ void UIManager::setIsJSResponder(

void UIManager::startSurface(
ShadowTree::Unique&& shadowTree,
const std::string& moduleName,
const folly::dynamic& props,
std::string moduleName,
folly::dynamic props,
DisplayMode displayMode) const noexcept {
TraceSection s("UIManager::startSurface");

Expand All @@ -249,7 +249,10 @@ void UIManager::startSurface(
}
});

runtimeExecutor_([=](jsi::Runtime& runtime) {
runtimeExecutor_([surfaceId,
moduleName = std::move(moduleName),
props = std::move(props),
displayMode](jsi::Runtime& runtime) {
TraceSection s("UIManager::startSurface::onRuntime");
AppRegistryBinding::startSurface(
runtime, surfaceId, moduleName, props, displayMode);
Expand All @@ -264,12 +267,15 @@ void UIManager::startEmptySurface(

void UIManager::setSurfaceProps(
SurfaceId surfaceId,
const std::string& moduleName,
const folly::dynamic& props,
std::string moduleName,
folly::dynamic props,
DisplayMode displayMode) const noexcept {
TraceSection s("UIManager::setSurfaceProps");

runtimeExecutor_([=](jsi::Runtime& runtime) {
runtimeExecutor_([surfaceId,
moduleName = std::move(moduleName),
props = std::move(props),
displayMode](jsi::Runtime& runtime) {
AppRegistryBinding::setSurfaceProps(
runtime, surfaceId, moduleName, props, displayMode);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,17 +116,14 @@ class UIManager final : public ShadowTreeDelegate {

void startSurface(
ShadowTree::Unique &&shadowTree,
const std::string &moduleName,
const folly::dynamic &props,
std::string moduleName,
folly::dynamic props,
DisplayMode displayMode) const noexcept;

void startEmptySurface(ShadowTree::Unique &&shadowTree) const noexcept;

void setSurfaceProps(
SurfaceId surfaceId,
const std::string &moduleName,
const folly::dynamic &props,
DisplayMode displayMode) const noexcept;
void setSurfaceProps(SurfaceId surfaceId, std::string moduleName, folly::dynamic props, DisplayMode displayMode)
const noexcept;

ShadowTree::Unique stopSurface(SurfaceId surfaceId) const;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class PointerEventsProcessorTest : public ::testing::Test {
componentDescriptorProviderRegistry.createComponentDescriptorRegistry(
ComponentDescriptorParameters{
.eventDispatcher = eventDispatcher,
.contextContainer = std::move(contextContainer),
.contextContainer = contextContainer,
.flavor = nullptr});

componentDescriptorProviderRegistry.add(
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAndroidDebugCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -5288,10 +5288,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAndroidNewarchCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -5099,10 +5099,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAndroidReleaseCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -5279,10 +5279,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAppleDebugCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -7480,10 +7480,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAppleNewarchCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -7319,10 +7319,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactAppleReleaseCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -7471,10 +7471,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactCommonDebugCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -3746,10 +3746,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactCommonNewarchCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -3597,10 +3597,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
4 changes: 2 additions & 2 deletions scripts/cxx-api/api-snapshots/ReactCommonReleaseCxx.api
Original file line number Diff line number Diff line change
Expand Up @@ -3737,10 +3737,10 @@ class facebook::react::UIManager : public facebook::react::ShadowTreeDelegate {
public void setDelegate(facebook::react::UIManagerDelegate* delegate);
public void setIsJSResponder(const std::shared_ptr<const facebook::react::ShadowNode>& shadowNode, bool isJSResponder, bool blockNativeResponder) const;
public void setNativeAnimatedDelegate(std::weak_ptr<facebook::react::UIManagerNativeAnimatedDelegate> delegate);
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void setSurfaceProps(facebook::react::SurfaceId surfaceId, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void setViewTransitionDelegate(facebook::react::UIManagerViewTransitionDelegate* delegate);
public void startEmptySurface(facebook::react::ShadowTree::Unique&& shadowTree) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, const std::string& moduleName, const folly::dynamic& props, facebook::react::DisplayMode displayMode) const noexcept;
public void startSurface(facebook::react::ShadowTree::Unique&& shadowTree, std::string moduleName, folly::dynamic props, facebook::react::DisplayMode displayMode) const noexcept;
public void stopSurfaceForAnimationDelegate(facebook::react::SurfaceId surfaceId) const;
public void synchronouslyUpdateViewOnUIThread(facebook::react::Tag tag, const folly::dynamic& props);
public void unregisterCommitHook(facebook::react::UIManagerCommitHook& commitHook);
Expand Down
Loading