File tree Expand file tree Collapse file tree
packages/react-native/ReactAndroid/src/main/java/com/facebook/react Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,13 +17,13 @@ import android.view.Window
1717 * apply their configuration to all active windows.
1818 *
1919 * Third-party libraries can both implement this listener and emit window events through
20- * [ReactContext.onExtraWindowCreated ] and [ReactContext.onExtraWindowDestroyed ].
20+ * [ReactContext.onExtraWindowCreate ] and [ReactContext.onExtraWindowDestroy ].
2121 */
2222public interface ExtraWindowEventListener {
2323
2424 /* * Called when a new [Window] is created (e.g. a Dialog window for a Modal). */
25- public fun onExtraWindowCreated (window : Window )
25+ public fun onExtraWindowCreate (window : Window )
2626
2727 /* * Called when a [Window] is destroyed (e.g. on Dialog window dismiss). */
28- public fun onExtraWindowDestroyed (window : Window )
28+ public fun onExtraWindowDestroy (window : Window )
2929}
Original file line number Diff line number Diff line change @@ -368,23 +368,23 @@ public void onActivityResult(
368368 }
369369
370370 @ ThreadConfined (UI )
371- public void onExtraWindowCreated (Window window ) {
371+ public void onExtraWindowCreate (Window window ) {
372372 UiThreadUtil .assertOnUiThread ();
373373 for (ExtraWindowEventListener listener : mExtraWindowEventListeners ) {
374374 try {
375- listener .onExtraWindowCreated (window );
375+ listener .onExtraWindowCreate (window );
376376 } catch (RuntimeException e ) {
377377 handleException (e );
378378 }
379379 }
380380 }
381381
382382 @ ThreadConfined (UI )
383- public void onExtraWindowDestroyed (Window window ) {
383+ public void onExtraWindowDestroy (Window window ) {
384384 UiThreadUtil .assertOnUiThread ();
385385 for (ExtraWindowEventListener listener : mExtraWindowEventListeners ) {
386386 try {
387- listener .onExtraWindowDestroyed (window );
387+ listener .onExtraWindowDestroy (window );
388388 } catch (RuntimeException e ) {
389389 handleException (e );
390390 }
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ internal class StatusBarModule(reactContext: ReactApplicationContext?) :
4343 reactApplicationContext.removeExtraWindowEventListener(this )
4444 }
4545
46- override fun onExtraWindowCreated (window : Window ) {
46+ override fun onExtraWindowCreate (window : Window ) {
4747 extraWindows.add(window)
4848
4949 UiThreadUtil .runOnUiThread {
@@ -57,7 +57,7 @@ internal class StatusBarModule(reactContext: ReactApplicationContext?) :
5757 }
5858 }
5959
60- override fun onExtraWindowDestroyed (window : Window ) {
60+ override fun onExtraWindowDestroy (window : Window ) {
6161 extraWindows.remove(window)
6262 }
6363
Original file line number Diff line number Diff line change @@ -77,12 +77,12 @@ public class ThemedReactContext(
7777 reactApplicationContext.removeExtraWindowEventListener(listener)
7878 }
7979
80- override fun onExtraWindowCreated (window : Window ) {
81- reactApplicationContext.onExtraWindowCreated (window)
80+ override fun onExtraWindowCreate (window : Window ) {
81+ reactApplicationContext.onExtraWindowCreate (window)
8282 }
8383
84- override fun onExtraWindowDestroyed (window : Window ) {
85- reactApplicationContext.onExtraWindowDestroyed (window)
84+ override fun onExtraWindowDestroy (window : Window ) {
85+ reactApplicationContext.onExtraWindowDestroy (window)
8686 }
8787
8888 override fun hasCurrentActivity (): Boolean = reactApplicationContext.hasCurrentActivity()
Original file line number Diff line number Diff line change @@ -197,7 +197,7 @@ public class ReactModalHostView(context: ThemedReactContext) :
197197
198198 dialog?.let { nonNullDialog ->
199199 nonNullDialog.window?.let { window ->
200- (context as ThemedReactContext ).onExtraWindowDestroyed (window)
200+ (context as ThemedReactContext ).onExtraWindowDestroy (window)
201201 }
202202 if (nonNullDialog.isShowing) {
203203 val dialogContext =
@@ -344,7 +344,7 @@ public class ReactModalHostView(context: ThemedReactContext) :
344344 newDialog.show()
345345 updateSystemAppearance()
346346 window.clearFlags(WindowManager .LayoutParams .FLAG_NOT_FOCUSABLE )
347- (context as ThemedReactContext ).onExtraWindowCreated (window)
347+ (context as ThemedReactContext ).onExtraWindowCreate (window)
348348 }
349349 }
350350
You can’t perform that action at this time.
0 commit comments