mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Use C++17 namespace format (#36983)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/36983 Changelog: [Internal] This updates ReactCommon/react code to use C++17 namespace format which was already used partially in other files Reviewed By: NickGerleman Differential Revision: D45121589 fbshipit-source-id: 0be5a7bce75dc9f8cde7856684f730f4d6df9202
This commit is contained in:
committed by
Facebook GitHub Bot
parent
6babe4acfa
commit
79c42e7259
@@ -9,8 +9,7 @@
|
||||
#include <cxxreact/MessageQueueThread.h>
|
||||
#include <algorithm>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
BufferedRuntimeExecutor::BufferedRuntimeExecutor(
|
||||
RuntimeExecutor runtimeExecutor)
|
||||
@@ -58,5 +57,4 @@ void BufferedRuntimeExecutor::unsafeFlush() {
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
#include <atomic>
|
||||
#include <queue>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class BufferedRuntimeExecutor {
|
||||
public:
|
||||
@@ -47,5 +46,4 @@ class BufferedRuntimeExecutor {
|
||||
std::priority_queue<BufferedWork> queue_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
#include <ReactCommon/RuntimeExecutor.h>
|
||||
#include <jsi/jsi.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* Interface for a class that creates and owns an instance of a JS VM
|
||||
@@ -23,5 +22,4 @@ class JSEngineInstance {
|
||||
virtual ~JSEngineInstance() = default;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -9,8 +9,7 @@
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* This interface is implemented by each platform.
|
||||
@@ -30,5 +29,4 @@ class PlatformTimerRegistry {
|
||||
|
||||
using TimerManagerDelegate = PlatformTimerRegistry;
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -22,8 +22,7 @@
|
||||
#include <tuple>
|
||||
#include <utility>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// Looping on \c drainMicrotasks until it completes or hits the retries bound.
|
||||
static void performMicrotaskCheckpoint(jsi::Runtime &runtime) {
|
||||
@@ -454,5 +453,4 @@ void ReactInstance::handleMemoryPressureJs(int pressureLevel) {
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -16,8 +16,7 @@
|
||||
#include <react/bridgeless/TimerManager.h>
|
||||
#include <react/renderer/runtimescheduler/RuntimeScheduler.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
struct CallableModule {
|
||||
explicit CallableModule(jsi::Function factory)
|
||||
@@ -76,5 +75,4 @@ class ReactInstance final {
|
||||
std::shared_ptr<bool> hasFatalJsError_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
#include <cxxreact/SystraceSection.h>
|
||||
#include <utility>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
TimerManager::TimerManager(
|
||||
std::unique_ptr<PlatformTimerRegistry> platformTimerRegistry) noexcept
|
||||
@@ -412,5 +411,4 @@ void TimerManager::attachGlobals(jsi::Runtime &runtime) {
|
||||
}));
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
|
||||
#include "PlatformTimerRegistry.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* A HostObject subclass representing the result of a setTimeout call.
|
||||
@@ -113,5 +112,4 @@ class TimerManager {
|
||||
std::vector<uint32_t> reactNativeMicrotasksQueue_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -18,8 +18,7 @@
|
||||
using namespace facebook::hermes;
|
||||
using namespace facebook::jsi;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
#ifdef HERMES_ENABLE_DEBUGGER
|
||||
|
||||
@@ -119,5 +118,4 @@ std::unique_ptr<jsi::Runtime> HermesInstance::createJSRuntime(
|
||||
return hermesRuntime;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
#include <jsi/jsi.h>
|
||||
#include <react/config/ReactNativeConfig.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class HermesInstance {
|
||||
public:
|
||||
@@ -24,5 +23,4 @@ class HermesInstance {
|
||||
std::shared_ptr<::hermes::vm::CrashManager> cm) noexcept;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -20,8 +20,7 @@
|
||||
using ::testing::_;
|
||||
using ::testing::SaveArg;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class MockTimerRegistry : public PlatformTimerRegistry {
|
||||
public:
|
||||
@@ -866,5 +865,4 @@ function getResult() {
|
||||
EXPECT_EQ(result.getNumber(), 1);
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -12,8 +12,7 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// Helper for passing jsi::Function arg to other methods.
|
||||
class CallbackWrapper : public LongLivedObject {
|
||||
@@ -63,5 +62,4 @@ class CallbackWrapper : public LongLivedObject {
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "LongLivedObject.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// LongLivedObjectCollection
|
||||
LongLivedObjectCollection &LongLivedObjectCollection::get() {
|
||||
@@ -47,5 +46,4 @@ void LongLivedObject::allowRelease() {
|
||||
LongLivedObjectCollection::get().remove(this);
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
#include <mutex>
|
||||
#include <unordered_set>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* A simple wrapper class that can be registered to a collection that keep it
|
||||
@@ -55,5 +54,4 @@ class LongLivedObjectCollection {
|
||||
mutable std::mutex collectionMutex_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "ReactNativeConfig.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* ReactNative configuration as provided by the hosting app.
|
||||
@@ -42,5 +41,4 @@ double EmptyReactNativeConfig::getDouble(const std::string ¶m) const {
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -9,8 +9,7 @@
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* ReactNative configuration as provided by the hosting app.
|
||||
@@ -40,5 +39,4 @@ class EmptyReactNativeConfig : public ReactNativeConfig {
|
||||
double getDouble(const std::string ¶m) const override;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -15,8 +15,7 @@
|
||||
using namespace facebook;
|
||||
using namespace facebook::xplat::module;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
namespace {
|
||||
CxxModule::Callback makeTurboCxxModuleCallback(
|
||||
@@ -225,5 +224,4 @@ jsi::Value TurboCxxModule::invokeMethod(
|
||||
return jsi::Value::undefined();
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -14,8 +14,7 @@
|
||||
|
||||
#include "TurboModule.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* A helper class to convert the legacy CxxModule instance to a TurboModule
|
||||
@@ -47,5 +46,4 @@ class JSI_EXPORT TurboCxxModule : public TurboModule {
|
||||
std::unique_ptr<facebook::xplat::module::CxxModule> cxxModule_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "TurboModule.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
TurboModule::TurboModule(
|
||||
std::string name,
|
||||
@@ -39,5 +38,4 @@ void TurboModule::emitDeviceEvent(
|
||||
});
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
|
||||
#include <ReactCommon/CallInvoker.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* For now, support the same set of return types as existing impl.
|
||||
@@ -139,5 +138,4 @@ class JSI_EXPORT TurboModule : public facebook::jsi::HostObject {
|
||||
using TurboModuleProviderFunctionType =
|
||||
std::function<std::shared_ptr<TurboModule>(const std::string &name)>;
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -15,8 +15,7 @@
|
||||
|
||||
using namespace facebook;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class BridgelessNativeModuleProxy : public jsi::HostObject {
|
||||
std::unique_ptr<TurboModuleBinding> binding_;
|
||||
@@ -207,5 +206,4 @@ jsi::Value TurboModuleBinding::getModule(
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <ReactCommon/TurboModule.h>
|
||||
#include <jsi/jsi.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
enum class TurboModuleBindingMode : uint8_t {
|
||||
HostObject = 0,
|
||||
@@ -57,5 +56,4 @@ class TurboModuleBinding {
|
||||
TurboModuleProviderFunctionType moduleProvider_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "TurboModulePerfLogger.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
namespace TurboModulePerfLogger {
|
||||
|
||||
std::unique_ptr<NativeModulePerfLogger> g_perfLogger = nullptr;
|
||||
@@ -327,5 +326,4 @@ void asyncMethodCallExecutionFail(
|
||||
}
|
||||
|
||||
} // namespace TurboModulePerfLogger
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,8 +10,7 @@
|
||||
#include <reactperflogger/NativeModulePerfLogger.h>
|
||||
#include <memory>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
namespace TurboModulePerfLogger {
|
||||
void enableLogging(std::unique_ptr<NativeModulePerfLogger> &&logger);
|
||||
void disableLogging();
|
||||
@@ -108,5 +107,4 @@ void asyncMethodCallExecutionFail(
|
||||
int32_t id);
|
||||
|
||||
} // namespace TurboModulePerfLogger
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "TurboModuleUtils.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static jsi::Value deepCopyJSIValue(jsi::Runtime &rt, const jsi::Value &value) {
|
||||
if (value.isNull()) {
|
||||
@@ -101,5 +100,4 @@ jsi::Value createPromiseAsJSIValue(
|
||||
return JSPromise.callAsConstructor(rt, fn);
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -15,8 +15,7 @@
|
||||
#include <ReactCommon/CallInvoker.h>
|
||||
#include <ReactCommon/CallbackWrapper.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
jsi::Object deepCopyJSIObject(jsi::Runtime &rt, const jsi::Object &obj);
|
||||
jsi::Array deepCopyJSIArray(jsi::Runtime &rt, const jsi::Array &arr);
|
||||
@@ -56,5 +55,4 @@ class RAIICallbackWrapperDestroyer {
|
||||
std::weak_ptr<CallbackWrapper> callbackWrapper_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,8 +7,7 @@
|
||||
|
||||
#include "JavaInteropTurboModule.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
namespace {
|
||||
|
||||
@@ -188,5 +187,4 @@ std::vector<facebook::jsi::PropNameID> JavaInteropTurboModule::getPropertyNames(
|
||||
return propNames;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -16,8 +16,7 @@
|
||||
|
||||
#include "JavaTurboModule.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class JSI_EXPORT JavaInteropTurboModule : public JavaTurboModule {
|
||||
public:
|
||||
@@ -48,5 +47,4 @@ class JSI_EXPORT JavaInteropTurboModule : public JavaTurboModule {
|
||||
bool exportsConstants();
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -24,8 +24,7 @@
|
||||
|
||||
#include "JavaTurboModule.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
namespace TMPL = TurboModulePerfLogger;
|
||||
|
||||
@@ -850,5 +849,4 @@ jsi::Value JavaTurboModule::invokeJavaMethod(
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -17,8 +17,7 @@
|
||||
#include <react/bridging/CallbackWrapper.h>
|
||||
#include <react/jni/JCallback.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
struct JTurboModule : jni::JavaClass<JTurboModule> {
|
||||
static auto constexpr kJavaDescriptor =
|
||||
@@ -53,5 +52,4 @@ class JSI_EXPORT JavaTurboModule : public TurboModule {
|
||||
std::shared_ptr<CallInvoker> nativeInvoker_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -23,8 +23,7 @@
|
||||
((RCTTurboModuleEnabled() && [(klass) conformsToProtocol:@protocol(RCTTurboModule)]))
|
||||
#define RCT_IS_TURBO_MODULE_INSTANCE(module) RCT_IS_TURBO_MODULE_CLASS([(module) class])
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class CallbackWrapper;
|
||||
class Instance;
|
||||
@@ -93,8 +92,7 @@ class JSI_EXPORT ObjCTurboModule : public TurboModule {
|
||||
jsi::Value createPromise(jsi::Runtime &runtime, std::string methodName, PromiseInvocationBlock invoke);
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@protocol RCTTurboModule <NSObject>
|
||||
- (std::shared_ptr<facebook::react::TurboModule>)getTurboModule:
|
||||
|
||||
+2
-4
@@ -211,8 +211,7 @@ convertJSIFunctionToCallback(jsi::Runtime &runtime, const jsi::Function &value,
|
||||
return [callback copy];
|
||||
}
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
jsi::Value ObjCTurboModule::createPromise(jsi::Runtime &runtime, std::string methodName, PromiseInvocationBlock invoke)
|
||||
{
|
||||
@@ -724,5 +723,4 @@ void ObjCTurboModule::setMethodArgConversionSelector(NSString *methodName, int a
|
||||
methodArgConversionSelectors_[methodName][argIndex] = selectorValue;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
// NOTE: This entire file should be codegen'ed.
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static jsi::Value __hostFunction_NativeSampleTurboCxxModuleSpecJSI_voidFunc(
|
||||
jsi::Runtime &rt,
|
||||
@@ -149,5 +148,4 @@ NativeSampleTurboCxxModuleSpecJSI::NativeSampleTurboCxxModuleSpecJSI(
|
||||
0, __hostFunction_NativeSampleTurboCxxModuleSpecJSI_getConstants};
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
|
||||
#include <ReactCommon/TurboModule.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// TODO: This definition should be codegen'ed for type-safety purpose.
|
||||
class JSI_EXPORT NativeSampleTurboCxxModuleSpecJSI : public TurboModule {
|
||||
@@ -40,5 +39,4 @@ class JSI_EXPORT NativeSampleTurboCxxModuleSpecJSI : public TurboModule {
|
||||
virtual jsi::Object getConstants(jsi::Runtime &rt) = 0;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
|
||||
using namespace facebook;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
SampleTurboCxxModule::SampleTurboCxxModule(
|
||||
std::shared_ptr<CallInvoker> jsInvoker)
|
||||
@@ -94,5 +93,4 @@ jsi::Object SampleTurboCxxModule::getConstants(jsi::Runtime &rt) {
|
||||
return result;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
|
||||
#include "NativeSampleTurboCxxModuleSpecJSI.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* A sample implementation of the C++ spec. In practice, this class can just
|
||||
@@ -41,5 +40,4 @@ class SampleTurboCxxModule : public NativeSampleTurboCxxModuleSpecJSI {
|
||||
jsi::Object getConstants(jsi::Runtime &rt) override;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
#include <ReactCommon/SampleTurboModuleSpec.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static facebook::jsi::Value
|
||||
__hostFunction_NativeSampleTurboModuleSpecJSI_voidFunc(
|
||||
@@ -361,5 +360,4 @@ std::shared_ptr<TurboModule> SampleTurboModuleSpec_ModuleProvider(
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -13,8 +13,7 @@
|
||||
#include <ReactCommon/TurboModule.h>
|
||||
#include <fbjni/fbjni.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* C++ class for module 'SampleTurboModule'
|
||||
@@ -28,5 +27,4 @@ std::shared_ptr<TurboModule> SampleTurboModuleSpec_ModuleProvider(
|
||||
const std::string &moduleName,
|
||||
const JavaTurboModule::InitParams ¶ms);
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -43,8 +43,7 @@
|
||||
|
||||
@end
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* The iOS TurboModule impl specific to SampleTurboModule.
|
||||
@@ -54,5 +53,4 @@ class JSI_EXPORT NativeSampleTurboModuleSpecJSI : public ObjCTurboModule {
|
||||
NativeSampleTurboModuleSpecJSI(const ObjCTurboModule::InitParams ¶ms);
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,8 +7,7 @@
|
||||
|
||||
#import "RCTNativeSampleTurboModuleSpec.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static facebook::jsi::Value __hostFunction_NativeSampleTurboModuleSpecJSI_voidFunc(
|
||||
facebook::jsi::Runtime &rt,
|
||||
@@ -227,5 +226,4 @@ NativeSampleTurboModuleSpecJSI::NativeSampleTurboModuleSpecJSI(const ObjCTurboMo
|
||||
methodMap_["getConstants"] = MethodMetadata{0, __hostFunction_NativeSampleTurboModuleSpecJSI_getConstants};
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
|
||||
using namespace facebook::xplat::module;
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
SampleTurboCxxModuleLegacyImpl::SampleTurboCxxModuleLegacyImpl() {}
|
||||
|
||||
@@ -175,5 +174,4 @@ void SampleTurboCxxModuleLegacyImpl::getValueWithPromise(
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
#import <cxxreact/CxxModule.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* A sample CxxModule (legacy system) implementation.
|
||||
@@ -44,5 +43,4 @@ class SampleTurboCxxModuleLegacyImpl
|
||||
const facebook::xplat::module::CxxModule::Callback &reject);
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,8 +10,7 @@
|
||||
#include <jsi/jsi.h>
|
||||
#include <memory>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class LayoutAnimationCallbackWrapper {
|
||||
public:
|
||||
@@ -30,5 +29,4 @@ class LayoutAnimationCallbackWrapper {
|
||||
mutable std::shared_ptr<jsi::Function> callback_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/core/ReactPrimitives.h>
|
||||
#include <react/renderer/mounting/ShadowViewMutation.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class LayoutAnimationDriver : public LayoutAnimationKeyFrameManager {
|
||||
public:
|
||||
@@ -32,5 +31,4 @@ class LayoutAnimationDriver : public LayoutAnimationKeyFrameManager {
|
||||
uint64_t now) const override;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -21,8 +21,7 @@
|
||||
|
||||
#include <optional>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
#ifdef LAYOUT_ANIMATION_VERBOSE_LOGGING
|
||||
void PrintMutationInstruction(
|
||||
@@ -176,5 +175,4 @@ class LayoutAnimationKeyFrameManager : public UIManagerAnimationDelegate,
|
||||
ShadowViewMutationList const &mutations) const;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
|
||||
#include <optional>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static inline std::optional<AnimationType> parseAnimationType(
|
||||
std::string param) {
|
||||
@@ -208,5 +207,4 @@ static inline std::optional<LayoutAnimationConfig> parseLayoutAnimationConfig(
|
||||
duration, *createConfig, *updateConfig, *deleteConfig};
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
#include <react/renderer/mounting/ShadowViewMutation.h>
|
||||
#include <vector>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// This corresponds exactly with JS.
|
||||
enum class AnimationType {
|
||||
@@ -101,5 +100,4 @@ struct LayoutAnimation {
|
||||
std::vector<AnimationKeyFrame> keyFrames;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/graphics/Float.h>
|
||||
#include <react/renderer/mounting/ShadowViewMutation.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static inline bool shouldFirstComeBeforeSecondRemovesOnly(
|
||||
ShadowViewMutation const &lhs,
|
||||
@@ -77,5 +76,4 @@ std::pair<Float, Float> calculateAnimationProgress(
|
||||
LayoutAnimation const &animation,
|
||||
AnimationConfig const &mutationConfig);
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -17,8 +17,7 @@
|
||||
#include <react/renderer/debug/DebugStringConvertible.h>
|
||||
#include <react/renderer/mounting/ShadowView.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class AttributedString;
|
||||
|
||||
@@ -117,8 +116,7 @@ class AttributedString : public Sealable, public DebugStringConvertible {
|
||||
Fragments fragments_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
namespace std {
|
||||
template <>
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
|
||||
#include <react/renderer/attributedstring/AttributedString.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Represents an object storing a shared `AttributedString` or a shared pointer
|
||||
@@ -61,8 +60,7 @@ class AttributedStringBox final {
|
||||
bool operator==(AttributedStringBox const &lhs, AttributedStringBox const &rhs);
|
||||
bool operator!=(AttributedStringBox const &lhs, AttributedStringBox const &rhs);
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
template <>
|
||||
struct std::hash<facebook::react::AttributedStringBox> {
|
||||
|
||||
+2
-4
@@ -14,8 +14,7 @@
|
||||
#include <react/renderer/debug/DebugStringConvertible.h>
|
||||
#include <react/renderer/graphics/Float.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class ParagraphAttributes;
|
||||
|
||||
@@ -81,8 +80,7 @@ class ParagraphAttributes : public DebugStringConvertible {
|
||||
#endif
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
namespace std {
|
||||
|
||||
|
||||
@@ -20,8 +20,7 @@
|
||||
#include <react/renderer/graphics/Float.h>
|
||||
#include <react/renderer/graphics/Size.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class TextAttributes;
|
||||
|
||||
@@ -98,8 +97,7 @@ class TextAttributes : public DebugStringConvertible {
|
||||
#endif
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
namespace std {
|
||||
|
||||
|
||||
@@ -30,8 +30,7 @@
|
||||
|
||||
#include <glog/logging.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
inline std::string toString(const DynamicTypeRamp &dynamicTypeRamp) {
|
||||
switch (dynamicTypeRamp) {
|
||||
@@ -1306,5 +1305,4 @@ inline MapBuffer toMapBuffer(const AttributedString &attributedString) {
|
||||
|
||||
#endif
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
#include <functional>
|
||||
#include <limits>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
enum class FontStyle { Normal, Italic, Oblique };
|
||||
|
||||
@@ -151,8 +150,7 @@ enum class HyphenationFrequency {
|
||||
Full // Standard amount of hyphenation.
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
namespace std {
|
||||
template <>
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/attributedstring/primitives.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
#ifdef ANDROID
|
||||
|
||||
@@ -43,5 +42,4 @@ TEST(AttributedStringTest, testToDynamic) {
|
||||
|
||||
#endif
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/attributedstring/primitives.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
#ifdef ANDROID
|
||||
|
||||
@@ -35,5 +34,4 @@ TEST(TextAttributesTest, testToDynamic) {
|
||||
|
||||
#endif
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -15,8 +15,7 @@
|
||||
|
||||
#include "ComponentDescriptorRegistry.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* A factory to provide hosting app specific set of ComponentDescriptor's.
|
||||
@@ -30,5 +29,4 @@ using ComponentRegistryFactory =
|
||||
|
||||
ComponentRegistryFactory getDefaultComponentRegistryFactory();
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/core/EventDispatcher.h>
|
||||
#include <react/utils/ContextContainer.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Callable signature that represents the signature of `ComponentDescriptor`
|
||||
@@ -70,5 +69,4 @@ ComponentDescriptorProvider concreteComponentDescriptorProvider() {
|
||||
&concreteComponentDescriptorConstructor<ComponentDescriptorT>};
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -13,8 +13,7 @@
|
||||
#include <react/renderer/componentregistry/ComponentDescriptorRegistry.h>
|
||||
#include <react/renderer/core/ComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
using ComponentDescriptorProviderRequest =
|
||||
std::function<void(ComponentName componentName)>;
|
||||
@@ -67,5 +66,4 @@ class ComponentDescriptorProviderRegistry final {
|
||||
componentDescriptorProviderRequest_{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -16,8 +16,7 @@
|
||||
#include <react/renderer/core/ComponentDescriptor.h>
|
||||
#include <react/utils/ContextContainer.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class ComponentDescriptorProviderRegistry;
|
||||
class ComponentDescriptorRegistry;
|
||||
@@ -91,5 +90,4 @@ class ComponentDescriptorRegistry {
|
||||
ContextContainer::Shared contextContainer_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,13 +9,11 @@
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* Provides mapping from old view name format to the new format.
|
||||
*/
|
||||
std::string componentNameByReactViewName(std::string viewName);
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
|
||||
#include <jsi/jsi.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/**
|
||||
* An app/platform-specific provider function to determine if a component
|
||||
@@ -57,5 +56,4 @@ class NativeComponentRegistryBinding {
|
||||
HasComponentProviderFunctionType hasComponentProvider_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/imagemanager/ImageManager.h>
|
||||
#include <react/utils/ContextContainer.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <Image> component.
|
||||
@@ -40,5 +39,4 @@ class ImageComponentDescriptor final
|
||||
const SharedImageManager imageManager_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
#include <react/renderer/components/view/ViewEventEmitter.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class ImageEventEmitter : public ViewEventEmitter {
|
||||
public:
|
||||
@@ -24,5 +23,4 @@ class ImageEventEmitter : public ViewEventEmitter {
|
||||
void onPartialLoad() const;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
#include <react/renderer/graphics/Color.h>
|
||||
#include <react/renderer/imagemanager/primitives.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
// TODO (T28334063): Consider for codegen.
|
||||
class ImageProps final : public ViewProps {
|
||||
@@ -39,5 +38,4 @@ class ImageProps final : public ViewProps {
|
||||
std::string internal_analyticTag{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
#include <react/renderer/imagemanager/ImageManager.h>
|
||||
#include <react/renderer/imagemanager/primitives.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char ImageComponentName[];
|
||||
|
||||
@@ -61,5 +60,4 @@ class ImageShadowNode final : public ConcreteViewShadowNode<
|
||||
void updateStateIfNeeded();
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -15,8 +15,7 @@
|
||||
#include <react/renderer/mapbuffer/MapBufferBuilder.h>
|
||||
#endif
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* State for <Image> component.
|
||||
@@ -66,5 +65,4 @@ class ImageState final {
|
||||
Float const blurRadius_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -15,8 +15,7 @@
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <react/renderer/imagemanager/primitives.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
inline void fromRawValue(
|
||||
const PropsParserContext &context,
|
||||
@@ -139,5 +138,4 @@ inline std::string toString(const ImageResizeMode &value) {
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/components/inputaccessory/InputAccessoryShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <InputAccessoryView> component.
|
||||
@@ -42,5 +41,4 @@ class InputAccessoryComponentDescriptor final
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,10 +7,8 @@
|
||||
|
||||
#include "InputAccessoryShadowNode.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char InputAccessoryComponentName[] = "InputAccessoryView";
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/components/rncore/Props.h>
|
||||
#include <react/renderer/components/view/ConcreteViewShadowNode.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char InputAccessoryComponentName[];
|
||||
|
||||
@@ -35,5 +34,4 @@ class InputAccessoryShadowNode final : public ConcreteViewShadowNode<
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,8 +10,7 @@
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <react/renderer/graphics/Float.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* State for <InputAccessoryView> component.
|
||||
@@ -24,5 +23,4 @@ class InputAccessoryState final {
|
||||
const Size viewportSize{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,8 +10,7 @@
|
||||
#include <react/renderer/components/legacyviewmanagerinterop/LegacyViewManagerInteropShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class LegacyViewManagerInteropComponentDescriptor final
|
||||
: public ConcreteComponentDescriptor<LegacyViewManagerInteropShadowNode> {
|
||||
@@ -34,5 +33,4 @@ class LegacyViewManagerInteropComponentDescriptor final
|
||||
std::shared_ptr<void> const _coordinator;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -16,8 +16,7 @@
|
||||
#include "LegacyViewManagerInteropState.h"
|
||||
#include "RCTLegacyViewManagerInteropCoordinator.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
static std::string moduleNameFromComponentName(const std::string &componentName)
|
||||
{
|
||||
@@ -117,5 +116,4 @@ void LegacyViewManagerInteropComponentDescriptor::adopt(ShadowNode::Unshared con
|
||||
|
||||
legacyViewManagerInteropShadowNode->setStateData(std::move(state));
|
||||
}
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -5,11 +5,9 @@
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char LegacyViewManagerInteropComponentName[] =
|
||||
"LegacyViewManagerInterop";
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/components/legacyviewmanagerinterop/LegacyViewManagerInteropViewProps.h>
|
||||
#include <react/renderer/components/view/ConcreteViewShadowNode.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char LegacyViewManagerInteropComponentName[];
|
||||
|
||||
@@ -23,5 +22,4 @@ using LegacyViewManagerInteropShadowNode = ConcreteViewShadowNode<
|
||||
LegacyViewManagerInteropViewEventEmitter,
|
||||
LegacyViewManagerInteropState>;
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
#import <memory>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* State for <LegacyViewManagerInterop> component.
|
||||
@@ -20,5 +19,4 @@ class LegacyViewManagerInteropState final {
|
||||
std::shared_ptr<void> coordinator;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,7 +7,5 @@
|
||||
|
||||
#include "LegacyViewManagerInteropState.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
namespace facebook::react {
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -8,13 +8,11 @@
|
||||
#include "LegacyViewManagerInteropViewEventEmitter.h"
|
||||
#include <iostream>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
void LegacyViewManagerInteropViewEventEmitter::dispatchEvent(
|
||||
std::string const &type,
|
||||
folly::dynamic const &payload) const {
|
||||
EventEmitter::dispatchEvent(type, payload);
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -13,8 +13,7 @@
|
||||
#include <react/renderer/components/view/ViewEventEmitter.h>
|
||||
#include <react/renderer/core/EventEmitter.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class LegacyViewManagerInteropViewEventEmitter;
|
||||
|
||||
@@ -29,5 +28,4 @@ class LegacyViewManagerInteropViewEventEmitter : public ViewEventEmitter {
|
||||
const;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -8,8 +8,7 @@
|
||||
#include "LegacyViewManagerInteropViewProps.h"
|
||||
#include <react/renderer/core/DynamicPropsUtilities.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
LegacyViewManagerInteropViewProps::LegacyViewManagerInteropViewProps(
|
||||
const PropsParserContext &context,
|
||||
@@ -20,5 +19,4 @@ LegacyViewManagerInteropViewProps::LegacyViewManagerInteropViewProps(
|
||||
mergeDynamicProps(sourceProps.otherProps, (folly::dynamic)rawProps)) {
|
||||
}
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,8 +10,7 @@
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <unordered_map>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class LegacyViewManagerInteropViewProps final : public ViewProps {
|
||||
public:
|
||||
@@ -26,5 +25,4 @@ class LegacyViewManagerInteropViewProps final : public ViewProps {
|
||||
folly::dynamic const otherProps;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <UnstableReactLegacyComponent> component.
|
||||
@@ -34,5 +33,4 @@ class UnstableLegacyViewManagerInteropComponentDescriptor
|
||||
private:
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/components/modal/ModalHostViewShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <ModalHostView> component.
|
||||
@@ -43,5 +42,4 @@ class ModalHostViewComponentDescriptor final
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/components/rncore/Props.h>
|
||||
#include <react/renderer/components/view/ConcreteViewShadowNode.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char ModalHostViewComponentName[];
|
||||
|
||||
@@ -35,5 +34,4 @@ class ModalHostViewShadowNode final : public ConcreteViewShadowNode<
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -16,8 +16,7 @@
|
||||
#include <react/renderer/mapbuffer/MapBufferBuilder.h>
|
||||
#endif
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* State for <ModalHostView> component.
|
||||
@@ -51,5 +50,4 @@ class ModalHostViewState final {
|
||||
#pragma mark - Getters
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include "AndroidProgressBarMeasurementsManager.h"
|
||||
#include "AndroidProgressBarShadowNode.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <AndroidProgressBar> component.
|
||||
@@ -48,5 +47,4 @@ class AndroidProgressBarComponentDescriptor final
|
||||
measurementsManager_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -13,8 +13,7 @@
|
||||
#include <react/renderer/core/LayoutConstraints.h>
|
||||
#include <react/utils/ContextContainer.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class AndroidProgressBarMeasurementsManager {
|
||||
public:
|
||||
@@ -34,5 +33,4 @@ class AndroidProgressBarMeasurementsManager {
|
||||
mutable Size cachedMeasurement_{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/components/rncore/Props.h>
|
||||
#include <react/renderer/components/view/ConcreteViewShadowNode.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char AndroidProgressBarComponentName[];
|
||||
|
||||
@@ -42,5 +41,4 @@ class AndroidProgressBarShadowNode final : public ConcreteViewShadowNode<
|
||||
std::shared_ptr<AndroidProgressBarMeasurementsManager> measurementsManager_;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
#include <react/renderer/components/rncore/Props.h>
|
||||
#include <react/renderer/core/propsConversions.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
#ifdef ANDROID
|
||||
inline folly::dynamic toDynamic(AndroidProgressBarProps const &props) {
|
||||
@@ -26,5 +25,4 @@ inline folly::dynamic toDynamic(AndroidProgressBarProps const &props) {
|
||||
}
|
||||
#endif
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,10 +10,8 @@
|
||||
#include <react/renderer/components/root/RootShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
using RootComponentDescriptor = ConcreteComponentDescriptor<RootShadowNode>;
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
#include <react/renderer/core/LayoutContext.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class RootProps final : public ViewProps {
|
||||
public:
|
||||
@@ -36,5 +35,4 @@ class RootProps final : public ViewProps {
|
||||
LayoutContext layoutContext{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
@@ -14,8 +14,7 @@
|
||||
#include <react/renderer/core/LayoutContext.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class RootShadowNode;
|
||||
|
||||
@@ -59,5 +58,4 @@ class RootShadowNode final
|
||||
Transform getTransform() const override;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -11,8 +11,7 @@
|
||||
#include <react/renderer/components/safeareaview/SafeAreaViewShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* Descriptor for <SafeAreaView> component.
|
||||
@@ -43,5 +42,4 @@ class SafeAreaViewComponentDescriptor final
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -7,10 +7,8 @@
|
||||
|
||||
#include "SafeAreaViewShadowNode.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char SafeAreaViewComponentName[] = "SafeAreaView";
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -12,8 +12,7 @@
|
||||
#include <react/renderer/components/safeareaview/SafeAreaViewState.h>
|
||||
#include <react/renderer/components/view/ConcreteViewShadowNode.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
extern const char SafeAreaViewComponentName[];
|
||||
|
||||
@@ -35,5 +34,4 @@ class SafeAreaViewShadowNode final : public ConcreteViewShadowNode<
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+1
-3
@@ -7,6 +7,4 @@
|
||||
|
||||
#include "SafeAreaViewState.h"
|
||||
|
||||
namespace facebook {
|
||||
namespace react {} // namespace react
|
||||
} // namespace facebook
|
||||
namespace facebook::react {} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -9,8 +9,7 @@
|
||||
|
||||
#include <react/renderer/graphics/RectangleEdges.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
/*
|
||||
* State for <SafeAreaView> component.
|
||||
@@ -20,5 +19,4 @@ class SafeAreaViewState final {
|
||||
EdgeInsets padding{};
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -10,11 +10,9 @@
|
||||
#include <react/renderer/components/scrollview/ScrollViewShadowNode.h>
|
||||
#include <react/renderer/core/ConcreteComponentDescriptor.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
using ScrollViewComponentDescriptor =
|
||||
ConcreteComponentDescriptor<ScrollViewShadowNode>;
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
+2
-4
@@ -13,8 +13,7 @@
|
||||
#include <react/renderer/components/view/ViewEventEmitter.h>
|
||||
#include <react/renderer/core/EventEmitter.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
namespace facebook::react {
|
||||
|
||||
class ScrollViewMetrics {
|
||||
public:
|
||||
@@ -42,5 +41,4 @@ class ScrollViewEventEmitter : public ViewEventEmitter {
|
||||
EventPriority priority = EventPriority::AsynchronousBatched) const;
|
||||
};
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
||||
} // namespace facebook::react
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user