Commit bfdfba1
Expose RuntimeExecutor on ReactContext (#56987)
Summary:
Add `ReactContext.getRuntimeExecutor()` so callers can obtain the `RuntimeExecutor` without reaching into `CatalystInstance`. The bridge subclass forwards to `CatalystInstance.getRuntimeExecutor()`; the bridgeless subclass forwards to `ReactHost.runtimeExecutor`; `ThemedReactContext` proxies to its wrapped `ReactApplicationContext`. Previously, callers that needed the runtime executor had to reach through `catalystInstance.getRuntimeExecutor()`, which is bridge-only and required a `NoGetCatalystInstance` lint suppression. The new accessor works uniformly in both bridged and bridgeless modes.
Changelog:
[Android][Added] - Add `ReactContext.getRuntimeExecutor()`
Reviewed By: mdvacca
Differential Revision: D1066472331 parent f363f6b commit bfdfba1
5 files changed
Lines changed: 16 additions & 0 deletions
File tree
- packages/react-native/ReactAndroid
- api
- src/main/java/com/facebook/react
- bridge
- runtime
- uimanager
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
967 | 967 | | |
968 | 968 | | |
969 | 969 | | |
| 970 | + | |
970 | 971 | | |
971 | 972 | | |
972 | 973 | | |
| |||
4162 | 4163 | | |
4163 | 4164 | | |
4164 | 4165 | | |
| 4166 | + | |
4165 | 4167 | | |
4166 | 4168 | | |
4167 | 4169 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
282 | 282 | | |
283 | 283 | | |
284 | 284 | | |
| 285 | + | |
| 286 | + | |
285 | 287 | | |
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
203 | 209 | | |
204 | 210 | | |
205 | 211 | | |
| |||
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| |||
180 | 181 | | |
181 | 182 | | |
182 | 183 | | |
| 184 | + | |
| 185 | + | |
183 | 186 | | |
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| |||
162 | 163 | | |
163 | 164 | | |
164 | 165 | | |
| 166 | + | |
| 167 | + | |
165 | 168 | | |
166 | 169 | | |
167 | 170 | | |
| |||
0 commit comments