Add Framework name to Attach selection
Reviewed By: Hypuk, javache Differential Revision: D5389047 fbshipit-source-id: 90e2a5f805561e47e7705e7935ced7556a374616
This commit is contained in:
parent
221286be13
commit
a1e053cc50
|
@ -288,6 +288,7 @@ struct RCTInstanceCallback : public InstanceCallback {
|
||||||
[self.delegate shouldBridgeUseCustomJSC:self];
|
[self.delegate shouldBridgeUseCustomJSC:self];
|
||||||
// The arg is a cache dir. It's not used with standard JSC.
|
// The arg is a cache dir. It's not used with standard JSC.
|
||||||
executorFactory.reset(new JSCExecutorFactory(folly::dynamic::object
|
executorFactory.reset(new JSCExecutorFactory(folly::dynamic::object
|
||||||
|
("OwnerIdentity", "ReactNative")
|
||||||
("UseCustomJSC", (bool)useCustomJSC)
|
("UseCustomJSC", (bool)useCustomJSC)
|
||||||
#if RCT_PROFILE
|
#if RCT_PROFILE
|
||||||
("StartSamplingProfilerOnInit", (bool)self.devSettings.startSamplingProfilerOnLaunch)
|
("StartSamplingProfilerOnInit", (bool)self.devSettings.startSamplingProfilerOnLaunch)
|
||||||
|
|
|
@ -18,6 +18,7 @@ public class JSCJavaScriptExecutor extends JavaScriptExecutor {
|
||||||
private ReadableNativeMap mJSCConfig;
|
private ReadableNativeMap mJSCConfig;
|
||||||
|
|
||||||
public Factory(WritableNativeMap jscConfig) {
|
public Factory(WritableNativeMap jscConfig) {
|
||||||
|
jscConfig.putString("OwnerIdentity", "ReactNative");
|
||||||
mJSCConfig = jscConfig;
|
mJSCConfig = jscConfig;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -219,8 +219,9 @@ void JSCExecutor::initOnJSVMThread() throw(JSException) {
|
||||||
|
|
||||||
#ifdef WITH_INSPECTOR
|
#ifdef WITH_INSPECTOR
|
||||||
if (canUseInspector(m_context)) {
|
if (canUseInspector(m_context)) {
|
||||||
|
const std::string ownerId = m_jscConfig.getDefault("OwnerIdentity", "main").getString();
|
||||||
IInspector* pInspector = JSC_JSInspectorGetInstance(true);
|
IInspector* pInspector = JSC_JSInspectorGetInstance(true);
|
||||||
pInspector->registerGlobalContext("main", m_context);
|
pInspector->registerGlobalContext(ownerId, m_context);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue