Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.8 to 3.25.9.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/github/codeql-action/blob/main/CHANGELOG.md">github/codeql-action's changelog</a>.</em></p>
<blockquote>
<h1>CodeQL Action Changelog</h1>
<p>See the <a href="https://github.com/github/codeql-action/releases">releases page</a> for the relevant changes to the CodeQL CLI and language packs.</p>
<p>Note that the only difference between <code>v2</code> and <code>v3</code> of the CodeQL Action is the node version they support, with <code>v3</code> running on node 20 while we continue to release <code>v2</code> to support running on node 16. For example <code>3.22.11</code> was the first <code>v3</code> release and is functionally identical to <code>2.22.11</code>. This approach ensures an easy way to track exactly which features are included in different versions, indicated by the minor and patch version numbers.</p>
<h2>[UNRELEASED]</h2>
<ul>
<li>Update default CodeQL bundle version to 2.17.5. <a href="https://redirect.github.com/github/codeql-action/pull/2327">#2327</a></li>
</ul>
<h2>3.25.9 - 12 Jun 2024</h2>
<ul>
<li>Avoid failing database creation if the database folder already exists and contains some unexpected files. Requires CodeQL 2.18.0 or higher. <a href="https://redirect.github.com/github/codeql-action/pull/2330">#2330</a></li>
<li>The init Action will attempt to clean up the database cluster directory before creating a new database and at the end of the job. This will help to avoid issues where the database cluster directory is left in an inconsistent state. <a href="https://redirect.github.com/github/codeql-action/pull/2332">#2332</a></li>
</ul>
<h2>3.25.8 - 04 Jun 2024</h2>
<ul>
<li>Update default CodeQL bundle version to 2.17.4. <a href="https://redirect.github.com/github/codeql-action/pull/2321">#2321</a></li>
</ul>
<h2>3.25.7 - 31 May 2024</h2>
<ul>
<li>We are rolling out a feature in May/June 2024 that will reduce the Actions cache usage of the Action by keeping only the newest TRAP cache for each language. <a href="https://redirect.github.com/github/codeql-action/pull/2306">#2306</a></li>
</ul>
<h2>3.25.6 - 20 May 2024</h2>
<ul>
<li>Update default CodeQL bundle version to 2.17.3. <a href="https://redirect.github.com/github/codeql-action/pull/2295">#2295</a></li>
</ul>
<h2>3.25.5 - 13 May 2024</h2>
<ul>
<li>Add a compatibility matrix of supported CodeQL Action, CodeQL CLI, and GitHub Enterprise Server versions to the <a href="https://github.com/github/codeql-action/blob/main/README.md">https://github.com/github/codeql-action/blob/main/README.md</a>. <a href="https://redirect.github.com/github/codeql-action/pull/2273">#2273</a></li>
<li>Avoid printing out a warning for a missing <code>on.push</code> trigger when the CodeQL Action is triggered via a <code>workflow_call</code> event. <a href="https://redirect.github.com/github/codeql-action/pull/2274">#2274</a></li>
<li>The <code>tools: latest</code> input to the <code>init</code> Action has been renamed to <code>tools: linked</code>. This option specifies that the Action should use the tools shipped at the same time as the Action. The old name will continue to work for backwards compatibility, but we recommend that new workflows use the new name. <a href="https://redirect.github.com/github/codeql-action/pull/2281">#2281</a></li>
</ul>
<h2>3.25.4 - 08 May 2024</h2>
<ul>
<li>Update default CodeQL bundle version to 2.17.2. <a href="https://redirect.github.com/github/codeql-action/pull/2270">#2270</a></li>
</ul>
<h2>3.25.3 - 25 Apr 2024</h2>
<ul>
<li>Update default CodeQL bundle version to 2.17.1. <a href="https://redirect.github.com/github/codeql-action/pull/2247">#2247</a></li>
<li>Workflows running on <code>macos-latest</code> using CodeQL CLI versions before v2.15.1 will need to either upgrade their CLI version to v2.15.1 or newer, or change the platform to an Intel MacOS runner, such as <code>macos-12</code>. ARM machines with SIP disabled, including the newest <code>macos-latest</code> image, are unsupported for CLI versions before 2.15.1. <a href="https://redirect.github.com/github/codeql-action/pull/2261">#2261</a></li>
</ul>
<h2>3.25.2 - 22 Apr 2024</h2>
<p>No user facing changes.</p>
<h2>3.25.1 - 17 Apr 2024</h2>
<ul>
<li>We are rolling out a feature in April/May 2024 that improves the reliability and performance of analyzing code when analyzing a compiled language with the <code>autobuild</code> <a href="https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages#codeql-build-modes">build mode</a>. <a href="https://redirect.github.com/github/codeql-action/pull/2235">#2235</a></li>
<li>Fix a bug where the <code>init</code> Action would fail if <code>--overwrite</code> was specified in <code>CODEQL_ACTION_EXTRA_OPTIONS</code>. <a href="https://redirect.github.com/github/codeql-action/pull/2245">#2245</a></li>
</ul>
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="530d4feaa9"><code>530d4fe</code></a> Merge pull request <a href="https://redirect.github.com/github/codeql-action/issues/2334">#2334</a> from github/update-v3.25.9-37809d1f1</li>
<li><a href="65db484585"><code>65db484</code></a> Update changelog for v3.25.9</li>
<li><a href="37809d1f16"><code>37809d1</code></a> Merge pull request <a href="https://redirect.github.com/github/codeql-action/issues/2332">#2332</a> from github/henrymercer/cleanup-db-location</li>
<li><a href="159d9119ac"><code>159d911</code></a> Tweak changelog entries</li>
<li><a href="ed34eb9af4"><code>ed34eb9</code></a> Skip init-post cleanup on GitHub-hosted runners</li>
<li><a href="31fe7dd0a6"><code>31fe7dd</code></a> Merge pull request <a href="https://redirect.github.com/github/codeql-action/issues/2326">#2326</a> from github/dependabot/npm_and_yarn/npm-8402b9d28a</li>
<li><a href="d8d73c0e76"><code>d8d73c0</code></a> Clean up DB cluster directory at the end of each job</li>
<li><a href="3d849e9df2"><code>3d849e9</code></a> Include underlying error in error message</li>
<li><a href="945bb878ef"><code>945bb87</code></a> Merge pull request <a href="https://redirect.github.com/github/codeql-action/issues/2331">#2331</a> from github/igfoo/bash</li>
<li><a href="9ee83fa7ef"><code>9ee83fa</code></a> Update checked-in dependencies</li>
<li>Additional commits viewable in <a href="2e230e8fe0...530d4feaa9">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github/codeql-action&package-manager=github_actions&previous-version=3.25.8&new-version=3.25.9)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Relands https://github.com/flutter/flutter/pull/149739 which was reverted due to https://github.com/flutter/flutter/issues/149851
---
fixes [`SegmentedButton` doesn't clip properly when one of the segments has `ColorFiltered`](https://github.com/flutter/flutter/issues/144990)
### Code sample
<details>
<summary>expand to view the code sample</summary>
```dart
import 'package:flutter/material.dart';
void main() => runApp(const MyApp());
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: Center(
child: SegmentedButton<int>(
segments: const <ButtonSegment<int>>[
ButtonSegment<int>(
value: 0,
label: ColorFiltered(
colorFilter:
ColorFilter.mode(Colors.amber, BlendMode.colorBurn),
child: Text('Option 1'),
),
),
ButtonSegment<int>(
value: 1,
label: Text('Option 2'),
),
],
onSelectionChanged: (Set<int> selected) {},
selected: const <int>{0},
),
),
),
);
}
}
```
</details>
### Before
![before](https://github.com/flutter/flutter/assets/48603081/b402fc51-d575-4208-8a71-f798ef2b2bf5)
### After
![after](https://github.com/flutter/flutter/assets/48603081/77a5cac2-ecef-4381-a043-dbb5c91407ec)
*Replace this paragraph with a description of what this PR is changing or adding, and why. Consider including before/after screenshots.*
*List which issues are fixed by this PR. You must list at least one issue. An issue is not required if the PR fixes something trivial like a typo.*
*If you had to change anything in the [flutter/tests] repo, include a link to the migration guide as per the [breaking change policy].*
Adds `mouseCursor` property in `Radio` to `CupertinoRadio` and `Radio.adaptive`.
The `mouseCursor` property added is of type `MouseCursor` and not `WidgetStateProperty<MouseCursor>` to match `Radio`'s `mouseCursor`.
This is intended to replace the currently internal-only document for flutter/packages gardeners. It is a hybrid of the existing document and the Flutter-Framework-Gardener-Rotation.md document (in order to try to improve consistency relative to just moving the existing doc as-is).
## Description
This PRs fixes `DropdownMenu` behaviors when disabled.
Before this PR the `DropdownMenu` value can be changed when `DropdownMenu.enabled` was false because the inner `IconButton` was not disabled so it can get focus (for instance using tab key).
After this PR, the inner `TextField` and the inner `IconButton` are disabled when `DropdownMenu.enabled` is false.
## Related Issue
Fixes https://github.com/flutter/flutter/issues/149598.
## Tests
Updates 1 test.
Adds 1 test.
The widget under test already contains a MaterialApp, so there's no need to wrap it again with one in the test. In fact, the additional MaterialApp could hide problems in the widget under test.
The new service extension `getRootWidgetTree` can be used instead of the existing:
* `getRootWidgetSummaryTree` --> use`getRootWidgetTree` with parameters `isSummaryTree=true`
* `getRootWidgetSummaryTreeWithPreviews` --> use `getRootWidgetTree` with parameters `isSummaryTree=true` and `withPreviews=true`
This new service extension will enable Flutter DevTools to combine the widget summary tree with the widget details tree by calling `getRootWidgetTree` with `isSummary=false` and `withPreviews=true`.
Closes https://github.com/flutter/devtools/issues/7894
Currently, the error message displayed to regenerate the lockfiles gives a Unix-like command ./gradlew, which will be incorrect for Windows environments. This PR uses globals.platform.isWindows to give the appropriate command.
closes#136763
## Description
This fixes the `ColorScheme` example to actually work. The test had wrapped the app in an additional `MaterialApp`, which allowed the tests to work, but the real problem was using a `context` that was outside the `MaterialApp` to open the bottom sheet, which caused an exception when you actually try to run it interactively.
This fixes the example and the test.
## Tests
- Fixed the test to not artificially add a second `MaterialApp`.
Contributes to https://github.com/flutter/flutter/issues/130459
It adds a test for
- `examples/api/lib/material/scaffold/scaffold.drawer.0.dart`
- `examples/api/lib/material/scaffold/scaffold.end_drawer.0.dart`
This sentence didn't make a lot of sense as written. It looks like
it was probably based on the doc of invokeMapMethod, and then
incompletely adapted. So, fix it.
Reverts: flutter/flutter#150015
Initiated by: vashworth
Reason for reverting: Still failing tree on goldens
Original PR Author: dkwingsmt
Reviewed By: {chunhtai}
This change reverts the following previous change:
Relands #149568, which was reverted in https://github.com/flutter/flutter/pull/149998 due to unverified golden tests post-commit. (Honestly I don't know what happened but I guess resubmitting should resolve it.)
No code is changed.
Dart2Wasm doesn't officially support `dart:ffi` (only a small sketchy
subset needed in flutter web engine). We have seen user reporting issues
where existing packages don't work with dart2wasm due to using
`dart.library.ffi` in `bool.fromEnvironment` or in conditional imports
and it doing the wrong thing. So we're going to make `dart.library.ffi`
`false` in the compiler.
We therefore update the code to detect whether it runs under wasm via a
new `dart.tool.dart2wasm` environment variable.
This is a preparation for the change in dart2wasm which will start
making `const bool.fromEnvironment('dart.library.ffi')` return `false`
instead of `true`.
Notifies the engine when `PointerSignalEvents` have been ignored by the framework, through the `ui.PointerData.respond` method.
This allows the web to "preventDefault" (or not) on `wheel` events.
## Issues
* Fixes (partially): https://github.com/flutter/flutter/issues/139263
## Tests
* Added tests to ensure `respond` is called at the right time, with the right value.
## Demo
* https://dit-multiview-scroll.web.app
<details>
<summary>
## Previous versions
</summary>
1. Modified `PointerScrollEvent`, not shippable.
2. Modified when events were handled, instead of the opposite.
</details>
This PR addresses an issue with TextPainter's caret position calculation for text containing full-width spaces. Currently, the caret position is not accurately calculated for strings with full-width spaces. To resolve this, the following changes have been made:
Corrected the logic for caret position calculation when full-width spaces are present in the text.
Added and updated test cases to ensure accurate caret position calculation.
These changes ensure that the caret position for text with full-width spaces is computed correctly.
This issue was introduced by the commit [a0a854a](a0a854a78b).
Related Issue: [#149099](https://github.com/flutter/flutter/issues/149099)
- When `--web-renderer` is omitted, keep the value `null` until it later materializes to either `canvaskit` or `skwasm`.
- No more hardcoded defaults anywhere. We use `WebRendererMode.defaultForJs/defaultForWasm` instead.
- When in `--wasm` mode, the JS fallback is now `canvaskit` instead of `auto`.
- Add test for defaulting to `skwasm` when `--wasm` is enabled.
Fixes https://github.com/flutter/flutter/issues/149826
This reverts commit 32081aab69.
Reason for revert: Appears to be failing tests in tree
```
01:48 +2991 ~18: /Volumes/Work/s/w/ir/x/w/flutter/packages/flutter/test/cupertino/action_sheet_test.dart: Taps on a button can be slided to other buttons
âââ¡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK âââââââââââââââââââââââââââââââââââââââââââââââââââââ
The following SkiaException was thrown while running async test code:
Skia Gold received an unapproved image in post-submit
testing. Golden file images in flutter/flutter are triaged
in pre-submit during code review for the given PR.
Visit https://flutter-gold.skia.org/ to view and approve
the image(s), or revert the associated change. For more
information, visit the wiki:
https://github.com/flutter/flutter/wiki/Writing-a-golden-file-test-for-package:flutter
Debug information for Gold --------------------------------
stdout: Given image with hash 601f421e3bb643f437cc12395de96152 for test
cupertino.cupertinoActionSheet.press-drag
Expectation for test: ce8ef79c146857d162663b1161fd6d5c (positive)
Expectation for test: 3bb57a8782f67836c6ad3ece7f00729a (positive)
Expectation for test: 3f8c592774caf3c760fbbd318a7dc5af (positive)
Expectation for test: 61863f38217aa3349c239eeb49b84930 (positive)
Expectation for test: 98af16e9b7eb3fb810b44c74bb18ffb9 (positive)
Untriaged or negative image:
https://flutter-gold.skia.org//detail?grouping=name%3Dcupertino.cupertinoActionSheet.press-drag%26source_type%3Dflutter&digest=601f421e3bb643f437cc12395de96152
stderr: Test: cupertino.cupertinoActionSheet.press-drag FAIL
result-state.json: No result file found.
```
This PR matches the various colors of `CupertinoActionSheet` more closely with the native one.
The following colors are changed.
* Sheet background color
* Pressed button color
* Cancel button color
* Pressed cancel button color
* Divider color
* Content text color
The resulting colors match with native one with deviation of at most 1 (in terms of 0~255 RGB).
The following are comparison (left to right: Native, Flutter after PR, Flutter current)
<img width="1295" alt="image" src="https://github.com/flutter/flutter/assets/1596656/3703a4a8-a856-42b1-9395-a6e14b1881ca">
<img width="1268" alt="image" src="https://github.com/flutter/flutter/assets/1596656/1eb9964e-41f1-414a-99ae-0a2e7da8d3fd">
_Note: The divider thickness is adjusted to `1/dpr` instead of 0.3 in both Flutter version to make them look more native, as will be proposed in https://github.com/flutter/flutter/pull/149636._
### Derivation
All the colors are derived through color picker and calculation. The algorithm is as followed:
* Assume all colors are translucent grey colors, i.e. having the same value `x` for R, G, and B, with an alpha `a`.
* Given the barrier color is `x_B1=0` when the background is black, and `x_B2=204` when the background is white.
* Pick the target color `x_t1` when the background is black, and `x_t2` when the background is white
* Solve the following equations for `x` and `a`
```
a * x + (1-a) * x_B1 = x_t1
a * x + (1-a) * x_B2 = x_t2
a = 1 - (x_t1 - x_t2) / (x_B1 - x_B2)
x = (x_t1 - (1-a) * x_B1) / a
```
These equations use a linear model for color composition, which might not be exact, but is close enough for an accuracy of (1/255).
The full table is as follows:
<img width="1091" alt="image" src="https://github.com/flutter/flutter/assets/1596656/0fb76291-c3cc-4bb5-aefa-03ac6ac9bf1f">
* The first two columns are colors picked from XCode.
* The 3~4 columns are the colors picked from the current Flutter. Notice the deviation, which is sometimes drastic.
* The 5~6 columns are the colors picked from Flutter after this PR. The deviation is at most 1.
* The last few columns are calculation.
* There are two rows whose calculation is based on adjusted numbers, since the original results are not accurate enough, possibly due to the linear composition.
During the calculation, I assumed these colors vary between light and dark modes, but it turns out that both modes use the same set of colors.
### Screenshots
Instead I've added @andrewkolos for tools tests and @jtmcdole for engine
tests. This doesn't mean you have to investigate and solve the issues
filed by the flake bot. Instead, an assignee is just the mechanism used
by the flake bot to ensure that the issues are triaged at the
appropriate team triage meetings.
FYI @christopherfujino
This reverts commit 9d1de7b674.
Reverts due to log spam and crashing of the dependency version checker (which doesn't block the build but still isn't the desired outcome).