diff --git a/React/Fabric/RCTFabricPlatformUIOperationManager.h b/React/Fabric/RCTFabricPlatformUIOperationManager.h deleted file mode 100644 index fe6c89ea2..000000000 --- a/React/Fabric/RCTFabricPlatformUIOperationManager.h +++ /dev/null @@ -1,46 +0,0 @@ -/** - * Copyright (c) 2015-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -#import -#import - -#import - -#include - -@class RCTFabricPlatformUIOperationManager; - -namespace facebook { -namespace react { - -/** - * Connector class (from C++ to ObjC++) to allow FabricUIManager to invoke native UI operations/updates. - * UIKit-related impl doesn't live here, but this class gets passed to the FabricUIManager C++ impl directly. - */ -class RCTFabricPlatformUIOperationManagerConnector : public IFabricPlatformUIOperationManager { -public: - RCTFabricPlatformUIOperationManagerConnector(); - virtual ~RCTFabricPlatformUIOperationManagerConnector(); - - void performUIOperation(); - -private: - void *self_; - RCTFabricPlatformUIOperationManager *manager_; -}; - -} // namespace react -} // namespace facebook - -/** - * Actual ObjC++ implementation of the UI operations. - */ -@interface RCTFabricPlatformUIOperationManager : NSObject - -- (void)performUIOperation; - -@end diff --git a/React/Fabric/RCTFabricPlatformUIOperationManager.mm b/React/Fabric/RCTFabricPlatformUIOperationManager.mm deleted file mode 100644 index 3bccc58e0..000000000 --- a/React/Fabric/RCTFabricPlatformUIOperationManager.mm +++ /dev/null @@ -1,48 +0,0 @@ -/** - * Copyright (c) 2015-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -#import "RCTFabricPlatformUIOperationManager.h" - -namespace facebook { -namespace react { - -RCTFabricPlatformUIOperationManagerConnector::RCTFabricPlatformUIOperationManagerConnector() { - self_ = (__bridge_retained void *)[RCTFabricPlatformUIOperationManager new]; - manager_ = (__bridge RCTFabricPlatformUIOperationManager *)self_; -} - -RCTFabricPlatformUIOperationManagerConnector::~RCTFabricPlatformUIOperationManagerConnector() { - CFRelease(self_); - self_ = NULL; - manager_ = NULL; -} - -void RCTFabricPlatformUIOperationManagerConnector::performUIOperation() { - [manager_ performUIOperation]; -} - -} // namespace react -} // namespace facebook - -// ----------------------------------------------------------------------------- -// Start of ObjC++ impl -// Access UIKit here. -// ----------------------------------------------------------------------------- -@implementation RCTFabricPlatformUIOperationManager - -- (void)dealloc -{ - NSLog(@"RCTFabricPlatformUIOperationManager: dealloc()"); -} - -- (void)performUIOperation -{ - // TODO - NSLog(@"RCTFabricPlatformUIOperationManager: performUIOperation()"); -} - -@end diff --git a/React/Fabric/RCTFabricUIManagerWrapper.h b/React/Fabric/RCTFabricUIManagerWrapper.h deleted file mode 100644 index d40ef78c3..000000000 --- a/React/Fabric/RCTFabricUIManagerWrapper.h +++ /dev/null @@ -1,44 +0,0 @@ -/** - * Copyright (c) 2015-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -#import - -#import - -#import -#import -#import - -namespace facebook { -namespace react { - -class FabricUIManager; - -} // namespace react -} // namespace facebook - -using namespace facebook::react; - -/** - * An ObjC++ wrapper around the C++ FabricUIManager instance, so that the RCTCxxBridge can access it as needed. - */ -@interface RCTFabricUIManagerWrapper : NSObject - -- (std::shared_ptr)manager; - -@end - -@interface RCTBridge (RCTFabricUIManagerWrapper) - -/** - * To access via the bridge: - * - * std::shared_ptr fabricUIManager = [_bridge fabricUIManager]; - */ -- (std::shared_ptr)fabricUIManager; - -@end diff --git a/React/Fabric/RCTFabricUIManagerWrapper.mm b/React/Fabric/RCTFabricUIManagerWrapper.mm deleted file mode 100644 index 0d4613b0c..000000000 --- a/React/Fabric/RCTFabricUIManagerWrapper.mm +++ /dev/null @@ -1,62 +0,0 @@ -/** - * Copyright (c) 2015-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -#import "RCTFabricUIManagerWrapper.h" - -#include -#include -#include -#include -#include - -#import "RCTFabricPlatformUIOperationManager.h" - -// This file contains experimental placeholders, nothing is finalized. -@implementation RCTFabricUIManagerWrapper -{ - std::shared_ptr _manager; - std::shared_ptr _platformUIOperationManager; -} - -- (instancetype)init -{ - self = [super init]; - if (self) { - _platformUIOperationManager = std::make_shared(); - - auto componentDescriptorRegistry = std::make_shared(); - SharedComponentDescriptor viewComponentDescriptor = std::make_shared(); - componentDescriptorRegistry->registerComponentDescriptor(viewComponentDescriptor); - - _manager = std::make_shared(componentDescriptorRegistry); - } - return self; -} - -- (std::shared_ptr)manager -{ - return _manager; -} - -- (void)invalidate -{ -} - -@end - -@implementation RCTBridge (RCTFabricUIManagerWrapper) - -- (std::shared_ptr)fabricUIManager -{ - RCTFabricUIManagerWrapper *wrapper = [self jsBoundExtraModuleForClass:[RCTFabricUIManagerWrapper class]]; - if (wrapper) { - return [wrapper manager]; - } - return nullptr; -} - -@end diff --git a/ReactCommon/fabric/uimanager/IFabricPlatformUIOperationManager.h b/ReactCommon/fabric/uimanager/IFabricPlatformUIOperationManager.h deleted file mode 100644 index ff1434c75..000000000 --- a/ReactCommon/fabric/uimanager/IFabricPlatformUIOperationManager.h +++ /dev/null @@ -1,23 +0,0 @@ -/** - * Copyright (c) 2015-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -#pragma once - -namespace facebook { -namespace react { - -/** - * An interface for FabricUIManager to perform platform-specific UI operations, like updating native UIView's in iOS. - */ -class IFabricPlatformUIOperationManager { -public: - // TODO: add meaningful methods - virtual void performUIOperation() = 0; -}; - -} // namespace react -} // namespace facebook