11728 Commits

Author SHA1 Message Date
xubaolin
778b3fa322
support updating dragDecices at runtime (#120336) 2023-02-13 21:38:27 +00:00
Qun Cheng
f858302a6b
Remove brightness from AppBar/SliverAppBar/AppBarTheme/AppBarTheme.copyWith (#120575) 2023-02-13 13:12:13 -08:00
Ben Konyi
2df140f40d
Remove references to Observatory (#118577)
Observatory is being deprecated for Dart 3.0 so it should no longer be
referenced in tooling messaging / flags.

See https://github.com/dart-lang/sdk/issues/50233
2023-02-13 14:29:30 -05:00
Qun Cheng
7bacc25eea
Remove accentColorBrightness usage (#120577) 2023-02-13 10:18:18 -08:00
xubaolin
b0c24e8d3d
fix a Slider theme update bug (#120432)
* fix a Slider theme update bug

* Code review feedback
2023-02-13 10:11:28 +00:00
Casey Hillers
0db47bdd07
Revert "Fix BottomAppBar & BottomSheet M3 shadow (#119819)" (#120492)
This reverts commit 0a97ef85c8706330c94abb57841680d19292fcc7.
2023-02-11 11:44:56 +00:00
Flutter GitHub Bot
d63c54c9c2
roll packages (#120493) 2023-02-10 23:11:53 +00:00
Kate Lovett
780c9a8de1
Remove deprecated SystemChrome.setEnabledSystemUIOverlays (#119576) 2023-02-10 14:03:01 -06:00
Michael Goderbauer
298c874eac
Fix classes that shouldn't be extended/instantiated/mixedin (#120409) 2023-02-10 17:35:37 +00:00
Pierre-Louis
f05a555bcb
Fix lerping for NavigationRailThemeData icon themes (#120066)
* Fix lerping for NavigationRail icon themes

* fix typo
2023-02-10 17:32:43 +00:00
Renzo Olivares
5dbd281012
Use String.codeUnitAt instead of String.codeUnits[] in ParagraphBoundary (#120234)
* paragraph-boundary-opt

* address comments

* address comments

---------

Co-authored-by: Renzo Olivares <roliv@google.com>
2023-02-10 17:31:07 +00:00
Qun Cheng
91dc513a39
Add missing parameters to CheckboxListTile (#120118)
* Add missing parameters to CheckboxListTile

* Update test message and api doc

* Reorder parameters

---------

Co-authored-by: Qun Cheng <quncheng@google.com>
2023-02-09 18:41:09 +00:00
chunhtai
3fdd6ee46f
Reland "Overlay always applies clip (#113770)" (#116674)
* Reland "Overlay always applies clip (#113770)"

This reverts commit d0afbd72a782eb20657f01b082ef29a2517eee54.

* Root navigator will not clip
2023-02-09 18:38:47 +00:00
Hans Muller
42b20cf953
Added ListTile.titleAlignment, ListTileThemeData.titleAlignment (#119872)
* added ListTile.textAlignment

* changed titlesHeight to titleHeight

* fixed a typo

* Add tests and example

* Update tests

* update example test

---------

Co-authored-by: tahatesser <tessertaha@gmail.com>
2023-02-09 18:34:01 +00:00
Qun Cheng
5e506aeb61
Add missing parameters to SwitchListTile (#120115)
* Add missing parameters to SwitchListTile

* Update SwitchListTile doc

* Update doc for existing APIs

* Address comment

* Fix typo

---------

Co-authored-by: Qun Cheng <quncheng@google.com>
2023-02-09 18:32:49 +00:00
Eilidh Southren
9996126740
Add proper disabled values for input chips (#120192)
* add proper disabled values for input chips

* added test
2023-02-09 16:51:26 +00:00
Christopher Fujino
b1c4d5686e
Fix widget inspector null check (#120143)
* add failing test

* fix

* remove extra whitespace

* fix test failure

* disable trackrebuilddirtywidgets in teardown

* remove no-shuffle annotation

* fix
2023-02-09 00:55:05 +00:00
Hans Muller
212bac80d1
Revert "Update ExpansionTile to support Material 3 & add an example (#119712)" (#120300)
This reverts commit e8eac0d047cd44feabf0a62ab06bcecbbcf24b1b.
2023-02-08 10:53:55 -08:00
Qun Cheng
51227a9a50
Add missing parameters to RadioListTile (#120117) 2023-02-08 10:53:24 -08:00
Gabriel Terwesten
ec289f1eb4
Don't call PlatformViewCreatedCallbacks after AndroidViewController is disposed (#116854)
* Don't call `PlatformViewCreatedCallback`s after `AndroidViewController` is disposed

Before this change it was possible that, if a `AndroidViewController` was disposed before we got the notification that the platform view was created, `PlatformViewCreatedCallback`s where called even after calling `AndroidViewController.dispose`.

Also makes `_PlatformViewLinkState._onPlatformViewCreated` more carful to only call `setState` when mounted.

Closes #84628
Closes #96384

* Allow all widgets to remove listeners from controller

* Remove assert

* Add expectations to test
2023-02-08 18:51:50 +00:00
Eilidh Southren
0a97ef85c8
Fix BottomAppBar & BottomSheet M3 shadow (#119819)
* remove m3 shadows

* fix

* fix that test over there
2023-02-08 18:04:21 +00:00
MarchMore
0588b925a0
Removed "if" on resolving text color at "SnackBarAction" (#120050)
* Removed "if" on resolving text color at "SnackBarAction"

Removed multiple "if" for "resolveForegroundColor" method at "SnackBarAction". At least one of the multiple "if" ("defaults.actionTextColor is MaterialStateColor") led to not applying a custom set color (e.g. MaterialColor "Colors.red") for the action text when using Material 3.

The second "if" ("snackBarTheme.actionTextColor is MaterialStateColor") also makes no sense then as the set color of the Theme would lead to the same blocking behaviour of manual color assignment.

The last remaining "if" ("widget.textColor is MaterialStateColor") will be unnecessary if the other "if" will be removed, as it will be resolved in the code right afterwards.

The three "if" also seems to block the usage of the custom text color or the color at all if the widget is in the "MaterialState.disabled" state.

* Adjusted recent modifications to SnackBarAction's text color resolution

* Now the "widget.textColor" is checked if it is set.
  * If it is a MaterialStateColor, it will be used
  * Otherwise continue with normal resolution (It will be used in the resolution anyways because it's set)

* Repeat same steps with "snackBarTheme.actionTextColor" if previous was not set

* Repeat same steps with "defaults.actionTextColor" if previous was not set

* Reverted the auto formatting changes

* Added two test cases to "snack_bar_test"

 * Test for setting a MaterialColor to a SnackBarAction' label (M3)
 * Test for setting a MaterialStateColor to a SnackBarAction' label (M3)

* Renamed test cases "Snackbar labels can be colored"
2023-02-08 18:01:11 +00:00
Hans Muller
75ca31b0e4
Correct Badge interpretation of its alignment parameter (#119853) 2023-02-08 08:52:41 -08:00
Qun Cheng
3f98c0f8f9
Add trackOutlineColor for Switch and SwitchListTile (#120140)
* Add trackOutlineColor for Switch and SwitchListTile

* Update tests

* Update test

* Clean up unnecessary StatefulBUilder in tests

* Fix failed test

---------

Co-authored-by: Qun Cheng <quncheng@google.com>
2023-02-08 07:55:24 +00:00
xubaolin
6e7f580370
fix a TextFormField bug (#120182)
* fix a TextFormField bug

* review feedback
2023-02-08 04:37:24 +00:00
Renzo Olivares
99b6bd8c05
Add support for extending selection to paragraph on ctrl + shift + arrow up/down on Non-Apple platforms (#120151)
* Add support for extending selection to paragraph on ctrl + shift + arrow up/down for common keyboard actions

* Add ctrl + shift + arrow up/down common text editing shortcuts/actions

* fix analyzer

---------

Co-authored-by: Renzo Olivares <roliv@google.com>
2023-02-08 02:55:26 +00:00
Greg Price
cd125e1f71
Add test for RenderProxyBoxMixin; clarify doc, resolve TODO (#117664)
* Add test for RenderProxyBoxMixin; clarify doc, resolve TODO

The TODO comment suggested this mixin would no longer be needed once
a Dart issue on inherited constructors was fixed:
  https://github.com/dart-lang/sdk/issues/31543
That issue is now long since fixed, so I went to go carry out the TODO.

But in doing so, I realized that the mixin's documentation was more
right than the TODO comment: even with that issue fixed, there is a
legitimate use case for this mixin, namely to reuse the implementation
of RenderProxyBox in a class that also inherits from some other base
class.  Moreover, searching GitHub I found an example of a library
that makes real use of that capability.

So I think the right resolution is to accept that this separation
is useful and delete the TODO.

Then, add a test with an extremely simplified sketch of that
real-world example.  In case someone in the future attempts to
simplify this mixin away, the test will point us at the use case
that would be broken by such a change.

Also remove the only in-tree use of the mixin, which was redundant;
and expand the mixin's documentation to advise about that case.

* Tweak formatting

Co-authored-by: Michael Goderbauer <goderbauer@google.com>

* Cut comments

---------

Co-authored-by: Michael Goderbauer <goderbauer@google.com>
2023-02-08 01:17:23 +00:00
Justin McCandless
0b0450fbff
Web tab selection (#119583)
Correct selection behavior when tabbing into a field on the web.
2023-02-07 11:52:51 -08:00
Qun Cheng
1c225675c5
Update to v0.158 of the token database. (#120149)
* Update to v0.158 of the token database.

* Update checkbox template

* Fix DatePickerTheme test

---------

Co-authored-by: Qun Cheng <quncheng@google.com>
2023-02-07 19:16:24 +00:00
Taha Tesser
e8eac0d047
Update ExpansionTile to support Material 3 & add an example (#119712) 2023-02-07 08:21:18 -08:00
Konstantin Sokolovskyi
a6ea64457a
Fix cut button creation in 'buttonItemsForToolbarOptions' (#119822)
* Fix cut button creation in buttonItemsForToolbarOptions

* Remove extra spaces in tests

* Replace fails with expects, Add periods in the comments
2023-02-07 08:45:50 -05:00
Eilidh Southren
7a6f1d81d6
M3 segmented buttons token fixes (#120095)
* add icon button property override

* Revert "add icon button property override"

This reverts commit 6c7f4d30671f417d0f4a311bdb186bd4ebc456c8.

* segmented button updates

* button changes

* fix

* put that thing back where it came from

* template updates

* analyzer fixes

* rename parameter

* analyzer fixes

* string interpolation fix

* template updates

* test updates
2023-02-07 10:53:36 +00:00
xubaolin
1d0cbbb244
fix a [SelectableRegion] crash bug (#120076)
* fix a crash bug

* review feedback
2023-02-07 06:10:06 +00:00
Renzo Olivares
cf3fc01774
remove deprecated accentTextTheme and accentIconTheme from ThemeData (#119360)
Co-authored-by: Renzo Olivares <roliv@google.com>
2023-02-07 05:40:18 +00:00
Justin McCandless
575ced6c5a
Fix context menu web examples (#120104)
The context menu examples on the docs site now work on the web.
2023-02-06 15:51:11 -08:00
Haroon Awan
40b5e4cb5e
Added "insertAll" and "removeAll" methods to AnimatedList (#115545)
* Added "insertAll" and "removeAll" method to AnimatedList

* Fixed doc

* Changes in documentation asked by reviewwer

* Removed unnecessary asserts.

* Doc changes asked by reviewer.

* Doc changes.

---------

Co-authored-by: Rashid Khabeer <rkhabeer84@gmail.com>
2023-02-06 16:45:39 +00:00
Eilidh Southren
3c3c9a1bd9
[M3] Add ListTile's iconColor property support for icon buttons (#120075)
* add icon button property override

* list tile changes

* add imports

* add newlines

* whitespace
2023-02-06 14:39:14 +00:00
Taha Tesser
bbca7ff693
Add Material 3 SwitchListTile example and update existing examples (#119714)
* Add Material 3 `SwitchListTile` example and update existing examples

* Update examples with `useMaterial3: true` and update example descriptions.

* add a `ColorScheme` colour
2023-02-06 09:02:37 +00:00
Callum Moffat
3f02d4b4c3
Tweak to floating-cursor-end behaviour (#119893)
* Tweak to floating-cursor-end behaviour

* Simplify
2023-02-03 22:29:00 +00:00
Justin McCandless
00b0d550c6
Fix iOS context menu position when flipped below (#119565)
* Fix anchorBelow calculation, and share toolbar padding constant

* Fix constant references in test

* Test below position when padding is not offset by content distance
2023-02-03 18:14:59 +00:00
Taha Tesser
7177c413a9
Add Material 3 RadioListTile example and update existing examples (#119716)
* Add Material 3 `RadioListTile` example and update existing examples

* Update examples with `useMaterial3: true` and update example descriptions.

* add a `ColorScheme` colour
2023-02-03 16:27:43 +00:00
Eilidh Southren
c5e8757fcb
Add M3 support for iconbuttons in error state in TextFields (#119925)
* add m3 iconbutton override

* changes

* spring cleaning

* whitespace fix

* sneaky whitespaces
2023-02-03 14:35:12 +00:00
Polina Cherkasova
e0b2138ba7
Dispose OverlayEntry in TooltipState. (#117291) 2023-02-03 06:31:47 -08:00
Jonah Williams
69421c1682
[framework] use shader tiling instead of repeated calls to drawImage (#119495)
* [framework] use shader tiling instead of repeated calls to drawImage

* ++

* ++

* review and test updates

* ++

* Update decoration_image.dart

* Update decoration_image.dart

* ++

* ++

* ++

* ++

* ++

* Update painting.dart

* Update decoration_test.dart
2023-02-03 07:28:57 +00:00
Kate Lovett
3570cce58e
Remove deprecated kind in GestureRecognizer et al (#119572)
* Remove deprecated kind in GestureRecognizer et al

* Fix null case
2023-02-03 01:34:17 +00:00
Greg Spencer
c6264605d9
Make _focusDebug not interpolate in debug mode (#119680)
* Make _focusDebug not interpolate in debug mode

* Add test

* Revert undesired change

* Fix test to fail before too

* Remove accidental skips

* Switch to using a generating closure for arguments.

* Remove a word
2023-02-03 01:27:20 +00:00
Christopher Fujino
d820aec786
Manual pub roll with dwds fix (#119575)
* roll packages

* fix dwds

* empty

---------

Co-authored-by: fluttergithubbot <fluttergithubbot@gmail.com>
2023-02-02 21:38:08 +00:00
Michael Goderbauer
b0f1714b7b
Make Flex,Row,Column const for real (#119673)
* Make Flex,Row,Column const for real

* dart fix --apply

* fix snippets

* fix integration test

* add comment
2023-02-02 19:33:57 +00:00
Pierre-Louis
07b51a0dbb
Add missing variants and *new* indicators to useMaterial3 docs (#119799)
* Add missing variants and *new* indicators to useMaterial3 docs

* add missing *new*
2023-02-02 18:27:33 +01:00
Eilidh Southren
1ee87990dc
Revert "[Re-land] Exposed tooltip longPress (#118796)" (#119832)
This reverts commit d27880801435109432dcada4a2245193af4ae1f2.
2023-02-02 17:11:19 +00:00