3931 Commits

Author SHA1 Message Date
Michael Goderbauer
bbcfb8d51a prepare alpha release (#11464) 2017-08-01 14:50:29 -07:00
perlatus
d1b222bef6 PopupMenuButton: create IconButton if child is Icon (#10230)
* PopupMenuButton: create IconButton if child is Icon

Otherwise the resulting button has an abnormally small and rectangular
area. With multiple PopupMenuButton(child: Icon) they get squished
together in the AppBar.

* Add separate icon argument to PopupMenuButton

* Fix style issues and tweak dartdocs

* Add tests for icon argument to PopupMenuButton

* Group icon tests and fix broken test, analyzer warnings

* Test that the correct custom icon is present

* Apply De Morgan's to work around dart analyzer bug

see: https://github.com/dart-lang/sdk/issues/30288
2017-08-01 12:32:49 -07:00
Ian Hickson
d4beaf54f0 Audit use of saveLayer (#11442)
It has recently come to light that we may have been ordering saveLayer
calls and clip calls incorrectly.
2017-07-31 12:21:42 -07:00
Devon Carew
561d17a876 add a profile() method (#11443)
* add a profile() method

* add todos
2017-07-30 16:29:28 -07:00
Ian Hickson
6655074b37 Fix documentation based on dartdoc's warnings (#11428) 2017-07-28 15:44:38 -07:00
Ian Hickson
58a28a2965 Improve some docs around WillPopScope. (#11429)
...and break the navigator<->routes circular dependency.

This is a step towards fixing https://github.com/flutter/flutter/issues/9577 but doesn't yet do so.
2017-07-28 15:10:11 -07:00
Devon Carew
ba5bb57a52 Revert "fire service protocol extension events for frames (#10966)" (#11430)
This reverts commit 4b4cabb761ec1cb7fb5f2e8ec6e850de29a03056.
2017-07-27 16:14:30 -07:00
Devon Carew
4b4cabb761 fire service protocol extension events for frames (#10966)
* fire service protocol extension events for frames

* start time in micros

* introduce a profile() function; only send frame events when in profile (or debug) modes

* moved the profile() function to foundation/profile.dart

* refactor to make the change more testable; test the change

* fire service protocol events by listening to onFrameInfo

* remove the frame event stream; add a devicelab test

* remove a todo

* final
2017-07-27 15:34:53 -07:00
Ian Hickson
87445e5913 Increase the touch slop. (#11419)
It was 8.0. It's now arbitrarily 18.0.

Changing this required adjusting some tests. Adjusting the tests
required debugging the tests. Debugging the tests required some tools
to help debugging gesture recognizers and gesture arenas, so I added
some. It also required updating some toString() methods which resulted
in some changes to the tree diagnostics logic.

Also I cleaned up some docs while I was at it.
2017-07-27 14:01:06 -07:00
Jason Simmons
838bd63182 Control raster cache flags in CustomPaint widgets (#11398) 2017-07-25 16:39:03 -07:00
Jacob Richman
9f510ebdc9 Refactor RenderObject.toStringDeep and Widget.toStringDeep code to use DiagnosticsNode (#11359)
Refactor RenderObject.toStringDeep and Widget.toStringDeep code to use DiagnosticsNode.
2017-07-25 09:25:13 -07:00
Ian Hickson
f0dec6e305 Add a debug feature to the gestures library to dump hit test results (#11346) 2017-07-24 10:10:19 -07:00
Mehmet Fidanboylu
94ed7dce41 Support automaticallyImplyLeading param in AppBar (#11264)
* Support automaticallyImplyLeading param in AppBar

* Review fixes

* fix review comments
2017-07-22 06:12:42 -07:00
Ian Hickson
dd40d0e29c Modal barrier shouldn't paint when the route is offstage. (#11347)
Fixes https://github.com/flutter/flutter/issues/11323
2017-07-21 16:39:11 -07:00
Ian Hickson
8f56f6fdd1 Add documentation and clean up code. (#11330)
Mainly, this adds documentation to members that were previously
lacking documentation.

It also adds a big block of documentation about improving performance
of widgets.

This also removes some references to package:collection and adds
global setEquals and listEquals methods in foundation that we can use.
(setEquals in particular should be much faster than the
package:collection equivalent, though both should be faster as they
avoid allocating new objects.) All remaining references now qualify
the import so we know what our remaining dependencies are.

Also lots of code reordering in Flutter driver to make the code
consistent and apply the style guide more thoroughly.
2017-07-21 16:39:04 -07:00
Collin Jackson
e0f3001fde Fix physics with NestedScrollView (#11326)
* Fix physics with NestedScrollView

* Review feedback
2017-07-21 18:42:12 -04:00
Ian Hickson
1f08bda304 AnimatedCrossFade layout customisation (#11343)
* Optimise AnimatedSize for the tight case.
* Remove `default` from a switch statement over enum (so that analyzer will complain if we add enum values).
* Adopt the Size since we use it after the child may have changed (which would throw normally).
* AnimatedCrossFade.layoutBuilder
2017-07-21 15:23:55 -07:00
gspencergoog
e4860ef0eb Fix Navigator.pop for named routes. (#11289)
* Prefix and Suffix support for TextFields

* Adding Tests

* Removing spurious newline.

* Fixing a small problem with the test

* Code review changes

* Code Review Changes

* Review Changes

* Export the new StrokeJoin enum

* Added example for line styles, and enabled line join styles.

* Reverting inadvertent change to main.dart.

* Updated due to code review of engine code

* Removed example.

* Added arguments to named routes, with test.

* Fixing some formatting

* Fixing Navigator.pop for named routes.

* Fixing comment.

* Simplifying test.

* Fixing new -> const for Text object.

* Tiny text change (also to kick a new Travis build)

* Added a more realistic test case.

* Reverting unintentional iml changes.

* Fixing trailing newline

* Removing some changes that snuck in.
2017-07-21 11:12:21 -07:00
xster
aa096b50af iOS text selection (#11224)
Extract common text selection overlay logic from Material to Widget and create a Cupertino version of the overlays
2017-07-21 11:33:17 -04:00
Jason Simmons
9d901327a4 Do not call saveLayer for physical model layers whose bounds are simple rectangles (#11324)
This is similar to an optimization done in PhysicalModelLayer::Paint in the engine
2017-07-20 17:06:57 -07:00
Michael Goderbauer
8e38848203 Fix sample code and update docs (#11257)
* fix sample code

* review comments

* review comments

* document other members for extra bonus points
2017-07-20 14:26:52 -07:00
Mary
bb15e346bb Add slider customizations (#11185)
* adds inactiveColor and showThumb to Slider

* add customizable color and showThumb tests

* remove showThumb, add negative tests
2017-07-20 11:15:22 -07:00
Ian Hickson
194bf41ee8 Don't relayout a Text if only its color changed. (#11313) 2017-07-19 17:53:32 -07:00
Jason Simmons
6dbf2269f0 Create one listener that merges the leading and trailing glow controllers and use it in each paint (#11311)
If a new listener is created for each paint, then the leading and trailing
controllers will accumulate and invoke a list of all those listeners
2017-07-19 17:32:39 -07:00
Ian Hickson
0b392665bf More debug help. (#11308) 2017-07-19 16:51:16 -07:00
Michael Goderbauer
b5c461a917 a11y: implement new SemanticsAction "showOnScreen" (v2) (#11156)
* a11y: implement new SemanticsAction "showOnScreen" (v2)

This action is triggered when the user swipes (in accessibility mode) to the last visible item of a scrollable list to bring that item fully on screen.

This requires engine rolled to flutter/engine#3856.

I am in the process of adding tests, but I'd like to get early feedback to see if this approach is OK.

* fix null check

* review comments

* review comments

* Add test

* fix analyzer warning
2017-07-19 16:40:24 -07:00
Hans Muller
d767ac0be5 Fixed a dartdoc sample code typo (#11306) 2017-07-19 16:33:55 -07:00
Yegor
669e13ebd4 AnimatedSize: state machine, tests, animate only when needed (#11305) 2017-07-19 15:53:28 -07:00
Yegor
02b65bc984 AnimatedCrossFade: shut off animations & semantics in faded out widgets (#11276)
* AnimatedCrossFade: shut off animations & semantics in faded out widgets

* address comments
2017-07-19 15:45:31 -07:00
Ian Hickson
77b0c1dab0 Don't pass "null" to debugPrint. (#11265)
debugDumpLayerTree in particular was passing null in profile mode since debugLayer isn't available in profile mode.
2017-07-19 12:57:13 -07:00
Michael Goderbauer
1744e8e0aa Expose the currently available semantic scroll actions (#11286)
* Expose the currently available semantic scroll actions

* review comments

* add test

* refactor to set
2017-07-19 12:21:36 -07:00
Hans Muller
daa7860ef0 Add a ScrollController parameter to NestedScrollView (#11242) 2017-07-18 18:24:38 -07:00
Michael Goderbauer
5f9e5605a6 Fix analyzer errors (#11284) 2017-07-18 17:24:56 -07:00
Jeff Brown
9480a3e591 Use Fuchsia system compositor for physical model layers. (#11164)
On Fuchsia, the system compositor is responsible for drawing shadows
for physical model layers with non-zero elevation.

Also fixed a bug where _needsCompositing was not being cleared prior
to updating it.
2017-07-18 15:30:08 -07:00
Jason Simmons
71c374af7c Add a flag that controls autocorrect on text fields (#11180)
See https://github.com/flutter/flutter/issues/11168
2017-07-17 17:49:03 -07:00
najeira
898c19d753 add physics to TabBarView (#11150) 2017-07-17 16:59:43 -07:00
Michael Goderbauer
744921fa02 Ensure that a frame is scheduled when a RenderObject calls markNeedsSemanticsUpdate (#11207)
* Ensure that a frame is allways scheduled when a RenderObject marks itself as needing a semantics update

Fixes issue 2 described in https://github.com/flutter/flutter/issues/10971

Previously, an object could call `markNeedsSemanticsUpdate` and its wish would never be granted because no frame was scheduled that would actually update the semantics. This caused an issue during scrolling on Android where at the end of the scroll the `RenderIgnorePointer` would stop blocking the semantics of the scrolled view, call `markNeedsSemanticsUpdate`, but then no frame was scheduled to actually put the semantics of the scrolled view back into the semantics tree. That made the scrolled view unusable for a11y users.

At first I was a bit wary to call `requestVisualUpdate` within `markNeedsSemanticsUpdate` because technically the visual is fine, we only need the frame it schedules to update the semantics. However, it seems like we are using `requestVisualUpdate` for exactly that purpose in other places already where we just need an update to the semantics (e.g. 76a50fe0ca/packages/flutter/lib/src/rendering/object.dart (L2408)).

* add tests
2017-07-17 16:49:05 -07:00
xster
5756d62931 Fix overscroll friction for small lists (#11243) 2017-07-14 18:33:20 -07:00
Michael Goderbauer
b619759133 Adds a RouteObserver (#11236)
* Adds a PageRouteObserver

Required for https://github.com/flutter/plugins/pull/174.
See also https://github.com/flutter/flutter/issues/11216.

* formatting fixes

* Make RouteObserver generic
2017-07-14 17:44:30 -07:00
Jason Simmons
e967b4b3c5 Improve the year selector UI in the date picker (#11214)
Fixes https://github.com/flutter/flutter/issues/10917
2017-07-14 15:08:10 -07:00
Todd Volkert
535a364c2a Add more docs to OrientationBuilder (#11233) 2017-07-14 11:54:20 -07:00
Todd Volkert
be9f99a8b7 Minor clarifications in docs (#11171) 2017-07-12 11:48:27 -07:00
Todd Volkert
77da737847 Bump intl to 0.15.1 (#11162)
* requires bumping `process` to a version that has
  relaxed version restrictions on `intl`

https://github.com/flutter/flutter/issues/10650
2017-07-11 21:11:26 -07:00
Michael Goderbauer
7b90bdc908 Make DropDown accessible (#11149) 2017-07-11 15:23:21 -07:00
Michael Goderbauer
ee632c3919 Exclude modal barrier from semantics on Android (#11024)
* Exclude modal barrier from semantics on Android

* Add tests
2017-07-06 10:15:03 -07:00
xster
47c4d64f01 Match non-linear overscroll spring to iOS (#11065)
* Make the drag resistance non-linear

* Let the easing of overscroll have a spring effect too

* Add tests and prevent possible drift by having a slightly smaller resistance when easing the overscroll

* lint
2017-07-05 18:39:22 -07:00
Collin Jackson
1b20dbc6dd Improve ExpansionTile docs (#11034) 2017-07-04 18:37:14 -07:00
Ian Hickson
7ba1879bfc Automatic silver keep alive (#11067)
* AutomaticKeepAlive

A Widget that listens for notifications from widgets that don't want to die.

* Automatically wrap SliverList and SliverGrid children in AutomaticKeepAlive widgets

* Fixes for review comments
2017-07-01 14:16:36 -07:00
Jason Simmons
eb668c3f64 Keep text selection ranges within the length of the text (#11055)
Fixes https://github.com/flutter/flutter/issues/11041
2017-06-30 14:50:11 -07:00
Ian Hickson
2c4ec1c9c2 Avoid self-referential imports. (#11045)
And add a test to verify we don't do this again.
2017-06-30 14:42:22 -07:00