Skip to content

Commit

Permalink
Update unstable-react-profiling to use PerftestDevSupportManager (fac…
Browse files Browse the repository at this point in the history
…ebook#47715)

Summary:
Pull Request resolved: facebook#47715

Changelog: [Internal]

Reviewed By: rubennorte

Differential Revision: D66167302

fbshipit-source-id: 23e6154eedd36c2011062de3195887cba7af8a72
  • Loading branch information
huntie authored and facebook-github-bot committed Nov 26, 2024
1 parent df7b6ae commit 24f010d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ package com.facebook.react.devsupport

import android.content.Context
import com.facebook.react.common.SurfaceDelegateFactory
import com.facebook.react.common.build.ReactBuildConfig
import com.facebook.react.devsupport.interfaces.DevBundleDownloadListener
import com.facebook.react.devsupport.interfaces.DevLoadingViewManager
import com.facebook.react.devsupport.interfaces.DevSupportManager
Expand Down Expand Up @@ -101,7 +102,11 @@ public class DefaultDevSupportManagerFactory : DevSupportManagerFactory {
useDevSupport: Boolean
): DevSupportManager =
if (!useDevSupport) {
ReleaseDevSupportManager()
if (ReactBuildConfig.UNSTABLE_ENABLE_FUSEBOX_RELEASE) {
PerftestDevSupportManager(applicationContext)
} else {
ReleaseDevSupportManager()
}
} else {
BridgelessDevSupportManager(
applicationContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public ReactHostImpl(
mUIExecutor = uiExecutor;
mMemoryPressureRouter = new MemoryPressureRouter(context);
mAllowPackagerServerAccess = allowPackagerServerAccess;
mUseDevSupport = useDevSupport || ReactBuildConfig.UNSTABLE_ENABLE_FUSEBOX_RELEASE;
mUseDevSupport = useDevSupport;
if (devSupportManagerFactory == null) {
devSupportManagerFactory = new DefaultDevSupportManagerFactory();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,9 +130,7 @@ final class ReactInstance {
mQueueConfiguration.getNativeModulesQueueThread();

ReactChoreographer.initialize(AndroidChoreographerProvider.getInstance());
if (useDevSupport) {
devSupportManager.startInspector();
}
devSupportManager.startInspector();

JSTimerExecutor jsTimerExecutor = createJSTimerExecutor();
mJavaTimerManager =
Expand Down

0 comments on commit 24f010d

Please sign in to comment.