Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,13 @@ private static String[] getArgsFromIntent(Intent intent) {
if (intent.getBooleanExtra("verbose-logging", false)) {
args.add("--verbose-logging");
}
final int observatoryPort = intent.getIntExtra("observatory-port", 0);
if (observatoryPort > 0) {
args.add("--observatory-port=" + Integer.toString(observatoryPort));
}
if (intent.getBooleanExtra("disable-service-auth-codes", false)) {
args.add("--disable-service-auth-codes");
}
// NOTE: all flags provided with this argument are subject to filtering
// based on a whitelist in shell/common/switches.cc. If any flag provided
// is not present in the whitelist, the process will immediately
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ public class FlutterShellArgs {
public static final String ARG_DUMP_SHADER_SKP_ON_SHADER_COMPILATION = "--dump-skp-on-shader-compilation";
public static final String ARG_KEY_VERBOSE_LOGGING = "verbose-logging";
public static final String ARG_VERBOSE_LOGGING = "--verbose-logging";
public static final String ARG_KEY_OBSERVATORY_PORT = "observatory-port";
public static final String ARG_OBSERVATORY_PORT = "--observatory-port=";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this "=" be here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It either has to be here or in the concatenation below. I don't have a strong preference - this is the only arg like this right now in here.


@NonNull
public static FlutterShellArgs fromIntent(@NonNull Intent intent) {
Expand All @@ -58,6 +60,10 @@ public static FlutterShellArgs fromIntent(@NonNull Intent intent) {
if (intent.getBooleanExtra(ARG_KEY_START_PAUSED, false)) {
args.add(ARG_START_PAUSED);
}
final int observatoryPort = intent.getIntExtra(ARG_KEY_OBSERVATORY_PORT, 0);
if (observatoryPort > 0) {
args.add(ARG_OBSERVATORY_PORT + Integer.toString(observatoryPort));
}
if (intent.getBooleanExtra(ARG_KEY_DISABLE_SERVICE_AUTH_CODES, false)) {
args.add(ARG_DISABLE_SERVICE_AUTH_CODES);
}
Expand Down