diff --git a/engine/src/flutter/shell/platform/android/io/flutter/app/FlutterActivityDelegate.java b/engine/src/flutter/shell/platform/android/io/flutter/app/FlutterActivityDelegate.java index 646196e254..95d007a809 100644 --- a/engine/src/flutter/shell/platform/android/io/flutter/app/FlutterActivityDelegate.java +++ b/engine/src/flutter/shell/platform/android/io/flutter/app/FlutterActivityDelegate.java @@ -160,7 +160,7 @@ public final class FlutterActivityDelegate return; } - String appBundlePath = FlutterMain.findAppBundlePath(activity.getApplicationContext()); + String appBundlePath = FlutterMain.findAppBundlePath(); if (appBundlePath != null) { runBundle(appBundlePath); } @@ -340,7 +340,7 @@ public final class FlutterActivityDelegate String appBundlePath = intent.getDataString(); if (appBundlePath == null) { // Fall back to the installation path if no bundle path was specified. - appBundlePath = FlutterMain.findAppBundlePath(activity.getApplicationContext()); + appBundlePath = FlutterMain.findAppBundlePath(); } if (route != null) { flutterView.setInitialRoute(route); diff --git a/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterActivity.java b/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterActivity.java index 2fa4488b9f..3d0345cb3c 100644 --- a/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterActivity.java +++ b/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterActivity.java @@ -345,6 +345,7 @@ public class FlutterActivity extends Activity * manifest file. */ @Nullable + @SuppressWarnings("deprecation") private Drawable getSplashScreenFromManifest() { try { ActivityInfo activityInfo = getPackageManager().getActivityInfo( @@ -599,7 +600,7 @@ public class FlutterActivity extends Activity * When this {@code FlutterActivity} is run by Flutter tooling and a data String is included * in the launching {@code Intent}, that data String is interpreted as an app bundle path. *
- * By default, the app bundle path is obtained from {@link FlutterMain#findAppBundlePath(Context)}. + * By default, the app bundle path is obtained from {@link FlutterMain#findAppBundlePath()}. *
* Subclasses may override this method to return a custom app bundle path. */ @@ -617,7 +618,7 @@ public class FlutterActivity extends Activity // Return the default app bundle path. // TODO(mattcarroll): move app bundle resolution into an appropriately named class. - return FlutterMain.findAppBundlePath(getApplicationContext()); + return FlutterMain.findAppBundlePath(); } /** diff --git a/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterFragment.java b/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterFragment.java index c004d7c8c4..4e3a94b92f 100644 --- a/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterFragment.java +++ b/engine/src/flutter/shell/platform/android/io/flutter/embedding/android/FlutterFragment.java @@ -178,7 +178,7 @@ public class FlutterFragment extends Fragment implements FlutterActivityAndFragm /** * The path to the app bundle which contains the Dart app to execute, defaults - * to {@link FlutterMain#findAppBundlePath(Context)} + * to {@link FlutterMain#findAppBundlePath()} */ @NonNull public Builder appBundlePath(@NonNull String appBundlePath) { @@ -511,14 +511,14 @@ public class FlutterFragment extends Fragment implements FlutterActivityAndFragm /** * Returns the file path to the desired Flutter app's bundle of code. *
- * Defaults to {@link FlutterMain#findAppBundlePath(Context)}. + * Defaults to {@link FlutterMain#findAppBundlePath()}. *
* Used by this {@code FlutterFragment}'s {@link FlutterActivityAndFragmentDelegate.Host} */ @Override @NonNull public String getAppBundlePath() { - return getArguments().getString(ARG_APP_BUNDLE_PATH, FlutterMain.findAppBundlePath(getContextCompat())); + return getArguments().getString(ARG_APP_BUNDLE_PATH, FlutterMain.findAppBundlePath()); } /**