5930 Commits

Author SHA1 Message Date
Shi-Hao Hong
c7d7ba1c2b
Update ExpansionPanelList Samples with Scaffold template (#30805) 2019-04-09 14:01:47 -07:00
Shi-Hao Hong
1835aac558
Update ListTile sample snippets to use Material Scaffold Template (#30800) 2019-04-09 13:46:31 -07:00
Shi-Hao Hong
9f9c5c29ec
Embedded images and variations to ListTile sample code (#30537)
Also includes counter-examples for list items that differ from ListTile.
2019-04-09 10:10:57 -07:00
Jonah Williams
03817a995a
fix cast NPE in invokeListMethod and invokeMapMathod (#30760) 2019-04-09 07:22:25 -07:00
Todd Volkert
0b8403b61c
Add const Border.uniform() (#30640)
`Border.all()` is a factory constructor and thus not const
constructible. This change adds a `const Border.uniform()`
constructor and makes `Border.all()` delegate to it. This allows
callers to more likely be able to make their widget tree const
constructible.
2019-04-07 21:29:32 -07:00
Todd Volkert
949023b276
Add Form.onSaved (#30643)
When submitting data to a server, callers need a callback that will
get invoked after all the individual form fields are saved. If they
have a button that submits the form, they could just do this logic
in the click handler for the button (save the form, then submit to
the server), but if they have more ways than one to submit the form
(i.e. hitting enter while in a text form field), then it becomes
more convoluted and calls for a unified callback that will get
notified when the form is submitted.
2019-04-07 21:02:09 -07:00
Todd Volkert
cb78274c3f
Make FormField._validate() return void (#30644)
None of its callers were using the return value, so no need to
invoke the `isValid` getter unnecessarily.
2019-04-07 21:01:33 -07:00
Todd Volkert
535523dbe0
Add docs to FormFieldValidator (#30645)
To describe what its return value represents
2019-04-07 21:00:53 -07:00
Dan Field
d42db56b52
Add sample for ValueListenableBuilder (#30626)
* Add sample for ValueListenableBuilder
2019-04-06 20:14:41 -07:00
Hans Muller
ab06d033ca
Fixed a typo in the Expanded API doc (#30563) 2019-04-05 17:40:38 -07:00
LongCatIsLooong
e153883d43
Provide a default IconTheme in CupertinoTheme (#30521)
-* Inserted an `IconTheme` widget under `CupertinoTheme` to provide a default icon color when using `CupertinoTheme`.
* Changed `CupertinoTheme` to a `StatelessWidget`, to match the implementation of `Theme`
* Changed the nesting order of `Theme`'s sub widgets, to let `Theme.iconTheme` take precedence, so that `Theme`'s behavior is kept as is.
2019-04-05 15:57:29 -07:00
Tim Sneath
529189791c
Replace flutter.io with flutter.dev (#30562) 2019-04-05 11:39:30 -07:00
chunhtai
2b7e98973a
Fix issue 21640: Assertion Error : '_listenerAttached': is not true (#30513) 2019-04-05 11:31:40 -07:00
Tong Mu
1ae32facfe
Correctly synthesise event buttons (#30535)
* Correctly synthesise buttons, and add tests
2019-04-05 09:53:40 -07:00
Justin McCandless
566ac3ce2f
Trackpad mode crash fix (#30475)
Fixes a crash that happened when attempting to select text in trackpad mode on iOS.
2019-04-05 09:35:26 -07:00
Hans Muller
73687a9771
Correct MaterialButton disabledColor (#30531) 2019-04-04 18:05:55 -07:00
Tong Mu
13101c1a86
Touching the screen adds 0x01 to buttons (#30457)
* Add constants `kPrimaryButton`, `kTouchContact` and `kStylusContact`
* PointerDownEvent and PointerMoveEvent will always set the 0x01 bit on buttons
2019-04-04 15:11:29 -07:00
Morgan
74ee010b7b Fix MaterialApp's _navigatorObserver when only builder used (#29413)
Fix MaterialApp's _navigatorObserver so it doesn't cause WidgetApp's assertion to fail when using custom navigator, fixes #18904
2019-04-04 15:02:11 -07:00
Kate Lovett
05d1a10592
Embedding the diagram for BottomNavigationBar. (#30468) 2019-04-04 14:17:14 -07:00
Tong Mu
423cf223d9
Fix edge cases of PointerEventConverter (#29998)
* Fix: ui.PointerChange.remove might contain position change, but we used to expand it into a Cancel and Remove, neither of which allows position change. A Hover event is added, and a test is updated accordingly.
* Fixed the issue where a PointerMoveEvent and a PointerCancelEvent do not receive the correct pressure.
* Refactor the calculation of delta into deltaTo.
2019-04-04 10:27:07 -07:00
Shi-Hao Hong
1e50518cdc
Add ExpansionPanelList and ExpansionPanelList.radio Examples (#30343) 2019-04-04 07:12:56 -07:00
Nikita
88d50f78f3 Implement compute for async function (#16265) (#30275) 2019-04-04 00:17:26 -07:00
Kate Lovett
0c01a557df Embedding new raised button diagram. (#30398) 2019-04-04 00:14:40 -07:00
Kate Lovett
31086faa28 Updating sample code for BottomNavigationBar class for diagram. (#30453) 2019-04-04 00:14:12 -07:00
Michael Goderbauer
77bbd28c62
Random trivial fixes in the animation packages (#30276) 2019-04-04 00:13:34 -07:00
Michael Goderbauer
3c8dabefe7
Be more explicit when ValueNotifier notifies (#30461) 2019-04-04 00:13:07 -07:00
liyuqian
16a16e6598
Revert "Error message for setting shaderWarmUp too late (#30145)" (#30463)
This reverts commit ffbb335e35ae7416be98b72779baae6c9bd25b3b.

Reason for revert: flutter driver tests may have bugs in getting
first frame. Revert this until we figure out what happened.
2019-04-03 15:38:31 -07:00
Michael Goderbauer
5493fe469e
Moar Videos (#30452) 2019-04-03 12:49:13 -07:00
Michael Goderbauer
516ffd0c09
Add 29 Widget of the Week videos (#30415) 2019-04-03 12:48:37 -07:00
Dan Field
069aabfe95
Draggable Scrollable sheet (#30058)
* Draggable Scrollable sheet
2019-04-02 18:07:30 -07:00
Amir Hardon
b6afc16a96
Make sure _handleAppFrame is only registered once per frame (#30346)
There were 2 possible scenarios in which _handleAppFrame is added more than once as a frame callback. When this happens it is possible that the second invocation will try to access _nextFrame.image when _nextFrame is null and crash. The 2 scenarios are:

Scenario 1

A GIF frame is decoded and a Flutter frame is executed before it's time to show the next GIF frame.
The timer that's waiting for enough time to elapse is invoked, and schedules a callback for the next Flutter frame(here).
Before the next Flutter frame is executed, MultiFrameImageStreamCompleter#removeListener is called followed by ``MultiFrameImageStreamCompleter#addListenerthat is invoking_decodeNextFrameAndSchedule` which is adding `_handleAppFrame` again as a next frame callback.
Scenario 2
removeListener and addListener are called multiple times in succession, every call to addListener can result in another registration of _handleAppFrame to the next Flutter frame callbacks list.

This patch fixes the issue by guarding against a second registration of _handleAppFrame.
2019-04-02 12:14:27 -07:00
Jon Tippens
f056ea4e70 Fix minor typo (#30353) 2019-04-02 09:45:04 -07:00
Kate Lovett
add5f2ea76
Updating sample code for raised button to match forthcoming diagram. (#30348) 2019-04-02 09:28:13 -07:00
Michael Goderbauer
7c76dee7a4
Make heroes fly on pushReplacement (#30228) 2019-04-01 18:14:20 -07:00
Shi-Hao Hong
d4c4f563c4
Added assert to prevent complete ListTile trailing/leading horizontal expansion (#30212) 2019-04-01 17:41:56 -07:00
Tong Mu
fbefd6b816
Simplify logic of TapGestureRecognizer (#30227)
Refactors the logic of TapGestureRecognizer, making the calling dependency unidirectional between resolve(accept) and checkUp.
2019-04-01 10:58:30 -07:00
Hans Muller
14aa57b18d
Fix OutlineInputBorder crash (#30123) 2019-04-01 09:28:18 -07:00
Shi-Hao Hong
4d958ea5b7
Added helpful Material assert message (#30219)
Clarified an assert for when a Material widget's backgroundColor is null when its type isn't MaterialType.transparency
2019-03-30 12:58:58 -07:00
xster
f2d671c15c
Cupertino localization step 3: in-place move some material tools around to make room for cupertino (#29644) 2019-03-29 15:57:09 -07:00
xster
d166a8d81e
Make sure everything in the Cupertino page transition can be linear when back swiping (#28629) 2019-03-29 15:56:18 -07:00
Darren Austin
3892a0d96c
Made the showMenu() position parameter required (#30206)
Made the showMenu() position parameter required as it doesn't make sense to show a menu without indicating where it should be shown. Also added a test to verify this.
2019-03-29 14:15:03 -07:00
Michael Goderbauer
a3cbe25353
Part 1: Improve Overlay API (#28747) 2019-03-29 14:09:30 -07:00
Shi-Hao Hong
0e2eeb5a48
Set Max Height for ListTile trailing and leading widgets (#29771) 2019-03-29 12:22:31 -07:00
liyuqian
ffbb335e35
Error message for setting shaderWarmUp too late (#30145)
Developers may get confused by setting PaintingBinding.shaderWarmUp in
the wrong place. The added assert and error message help avoid that.
2019-03-29 10:49:07 -07:00
Jonah Williams
1bfa2f2311
Intercept errors thrown by synchronous Completers in image resolution. (#30139) 2019-03-29 10:05:18 -07:00
Shi-Hao Hong
cbe4c9e1d7
Add link to hero animation page (#30059) 2019-03-28 18:14:55 -07:00
Darren Austin
19901f674b
Fix a misuse of matchesGoldenFile() in the physical_model_test. (#30141)
Fixed a misuse of matchesGoldenFile() in the physical_model_test so that it correctly reports a failed test on Linux (and skips the other platforms).
2019-03-28 18:08:29 -07:00
Jonah Williams
a813dc559a
Add more test coverage to image handling (#30078) 2019-03-28 10:37:49 -07:00
Francisco Magdaleno
b70d260b3c
Adds the keyboard mapping for Linux (#29993) 2019-03-28 10:04:23 -07:00
Jonah Williams
557c94ff77
Move binarySearch implementation in animated_list to foundation/collection.dart. (#29860) 2019-03-28 01:00:29 -07:00