Skip to content

[url_launcher] Convert implementation to Kotlin - #13663

Merged
auto-submit[bot] merged 12 commits into
flutter:mainfrom
stuartmorgan:url-launcher-kotlin
Nov 17, 2026
Merged

auto-submit[bot] merged 12 commits into
flutter:mainfrom
stuartmorgan:url-launcher-kotlin

Conversation

@stuartmorgan

Copy link
Copy Markdown
Contributor

Converts url_launcher_android native implementation code from Java to Kotlin.

Similar to my other conversions, the process was:

  • Use the Android Studio deterministic auto-conversion.
  • Do manual cleanup and improvement as a separate commit.
  • Do a local Gemini review for where the code could be improved as Kotlin code, and address most of that feedback.

Includes minor test changes because a SAM used for test DI was replaced with a simple lambda.

Part of flutter/flutter#188630

Pre-Review Checklist

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. ↩ ↩2

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request converts the Android native implementation of the url_launcher plugin from Java to Kotlin, affecting UrlLauncher, UrlLauncherPlugin, and WebViewActivity, alongside corresponding test updates. The review feedback suggests two improvements in UrlLauncher.kt: utilizing default parameter values in the primary constructor to eliminate the secondary constructor, and simplifying Intent creation by passing the action and URI directly to the constructor.

@stuartmorgan stuartmorgan changed the title Url launcher kotlin [url_launcher] Convert implementation to Kotlin Nov 14, 2026
gmackall
gmackall previously approved these changes Nov 16, 2026

@gmackall gmackall left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm but I left some suggestions on a comment+kdoc that look out of date

@stuartmorgan

Copy link
Copy Markdown
Contributor Author

This will need re-approval since repo policy just changed.

@gmackall gmackall left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks Stuart!

@stuartmorgan stuartmorgan added the autosubmit Merge PR when tree becomes green via auto submit App label Nov 17, 2026
@auto-submit
auto-submit Bot merged commit 0a7765d into flutter:main Nov 17, 2026
13 checks passed
ditman pushed a commit to ditman/flutter-flutter that referenced this pull request Nov 17, 2026
…r#196812)

flutter/packages@4c6a7d3...9af69be

2026-11-17 [email protected] [in_app_purchase_storekit] add warm up
test to preaction (flutter/packages#13661)
2026-11-17 [email protected] Roll Flutter from
d8bd864 to 2f09f96 (27 revisions) (flutter/packages#13695)
2026-11-17 [email protected] [url_launcher] Convert implementation
to Kotlin (flutter/packages#13663)
2026-11-17 [email protected] [cupertino_ui] Prevent null-check crash
during CupertinoTextSelectionToolbar pagination (flutter/packages#13659)
2026-11-17 [email protected] [ci] Allow
backfilling missed releases via workflow_dispatch
(flutter/packages#13612)

If this roll has caused a breakage, revert this CL and set the roller
to dry run mode using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected] on the revert to ensure that a
human
is aware of the problem.

To file a bug in Flutter:
https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
LahaLuhem pushed a commit to LahaLuhem/flutter-packages that referenced this pull request Nov 19, 2026
Converts `url_launcher_android` native implementation code from Java to Kotlin.

Similar to my other conversions, the process was:
- Use the Android Studio deterministic auto-conversion.
- Do manual cleanup and improvement as a separate commit.
- Do a local Gemini review for where the code could be improved as Kotlin code, and address most of that feedback.

Includes minor test changes because a SAM used for test DI was replaced with a simple lambda.

Part of flutter/flutter#188630

## Pre-Review Checklist

[^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App CICD Run CI/CD p: url_launcher platform-android

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants