Commit graph

7952 commits

Author SHA1 Message Date
Yegor 93126a85e1 warn about outdated Flutter installations (#9163) 2017-04-04 10:45:43 -07:00
Dwayne Slater eb9046b175 [Flutter Tool] Only uninstall Android app when the initial install fails (#8930)
Uninstalling the app removes the data and cache directories, so this
allows application data to persist across multiple flutter run
invocations.

This also handles the edge case where the app fails to install due to an
error in installation (e.g. debug keystore changes, switching from a
release keystore to a debug keystore, etc.).
2017-04-04 10:16:42 -07:00
Todd Volkert dbc447b19a Only complete the web socket future once (#9176) 2017-04-04 10:15:48 -07:00
Chris Bracken c6cd0bc344 Roll engine to 5d9a6422577d95c242f45f48c47b431f7cf3c548 (#9181) 2017-04-04 09:51:55 -07:00
Michael Thomsen 398ee35e03 Update IJ files to match latest flutter create template (#9103)
* Make IntelliJ metadata files consistent with the current flutter create template

* Add missing IJ files from current flutter create template

* Remove run config from layers as it requires running with -t

* Remove workspace.xml files per review feedback
2017-04-04 15:50:03 +02:00
Jakob Andersen 5541d71b11 Android: Set evaluationDependsOn for plugin subprojects. (#9179)
Gradle projects are evaluated in lexicographical order, and the plugin
projects are at the same level as the :app project, so if a plugin has
a name that comes before 'app' (like, for example, any name that starts
with a capital letter), the plugin project will be evaluated before
:app.

Since :app applies the Flutter Gradle plugin, which tries to
modify the dependencies of the plugin projects, we have a problem if the
plugin projects have already been evaluated. Adding
evaluationDependsOn(':app') to the plugin projects fixes this.

Updated example projects to the latest (plugin-enabled) Gradle build
files.

Also removed two unused imports in `pluginClass.java.tmpl`.
2017-04-04 13:03:06 +02:00
xster 4245bce545 Add full platform build speed instrumentations (#9162)
* Add new metric to size_tests instead

* Small lints
2017-04-04 01:05:53 -07:00
Adam Barth 0d402242c5 Test that MaterialApp can be inside a FocusScope (#9141)
The underlying issue was fixed by the new focus system.

Fixes #1523
2017-04-03 22:50:30 -07:00
Adam Barth 830d163c21 Add more dartdocs for slivers (#9164)
This patch adds docs for many of the sliver widgets.
2017-04-03 22:47:02 -07:00
Adam Barth 5d8bad74d2 Add more dartdocs (#9174) 2017-04-03 22:08:51 -07:00
Adam Barth b564b4ccac Remove GlobalKey removal listeners (#9143)
These where used only by the old focus system. Let's remove them before
they grow more clients.
2017-04-03 21:12:47 -07:00
Adam Barth d88ff90753 Defer to TextField in TextFormField docs (#9144)
TextFormField doesn't actually have many properties because it wraps a
TextField. Rather than trying to document all the arguments in the
constructor, we now refer to the docs for TextField, which explain the
parameters in a more readable way.

Fixes #7245
2017-04-03 20:58:32 -07:00
Adam Barth f00b3a4b06 Remove ScrollBehavior.getGlowColor (#9145)
This method seemed overly specific to the needs of one particular
subclass. This patch duplicates some code but makes the API conceptually
cleaner.

Fixes #8267
2017-04-03 20:58:17 -07:00
Adam Barth 20015400f9 TextField centering should work in loose constraints (#9153)
We should always use the maxWidth from the incomming constraints to size the
text inside the editable because the EditableText itself always expands to fill
its width.

Also, make sure InputDecoration always expands horizontially (even when there's
no icon) for consistency.

Fixes #9149
2017-04-03 20:48:54 -07:00
Chris Bracken a246811953 Roll engine to 878f0ff09dd1d03029c2deac1a5f44d95a83a465 (#9170) 2017-04-03 19:47:41 -07:00
Hans Muller bb5351b7c2 AppBar looks up its scaffold with nullOk: true (#9160) 2017-04-03 15:27:37 -07:00
xster 58ddde88f4 Make Cupertino page transitions match native behaviours (#9138)
* Moved stuff around yet

* Fix depedencies

* Add more dartdoc comments to packages

* Remove Cupertino dependency on material

* Removed mountain_view package and added page transition test

* Fix analyze warnings

* Remove commented code

* Partial solution. Still need to stop the animation on the previous page for modal

* Some review notes

* Move the cupertino back gesture controller’s lifecycle management back to its parent

* Reviews

* Add background color

* Directional curves, full screen transition

* Don’t perform the exit animation if the incoming page is a dialog

* It works!

* Test structures

* Add a bunch of more tests and fix the gallery

* One more comment

* Review notes

* final controller

* Use that sweet sweet `is!` keyword

* Play golf, because I’m bitter that there’s no nullable `as` or something in dart

* Remove a space

* Review notes

* Remove the last deprecated test
2017-04-03 12:44:43 -07:00
xster c7f98efb63 Extract cupertino page transition out of material (#9059)
* Moved stuff around yet

* Fix depedencies

* Add more dartdoc comments to packages

* Remove Cupertino dependency on material

* Removed mountain_view package and added page transition test

* Fix analyze warnings

* Remove commented code

* Some review notes

* Move the cupertino back gesture controller’s lifecycle management back to its parent

* Reviews

* Add background color

* final controller

* Review notes
2017-04-03 12:17:39 -07:00
Collin Jackson 9095d76299 remove support library dependency in plugin template (#9126) 2017-04-03 05:17:24 -07:00
Adam Barth 210774f392 Make cursor blinking more efficient (#9142)
Rather than rebuilding to blink the cursor, we now pass a
ValueNotifier<bool> to the RenderEditable so that it can simply repaint.

This patch also contains some refactoring towards being able to do the
same thing with the text being edited, but I didn't quite get it
working.
2017-04-01 23:47:17 -07:00
Adam Barth 0b31c69963 Make it possible to center the text in a TextField (#9140)
Also, fix an issue where hint text wasn't visible when the
InputDecoration was collapsed.

Fixes #8541
2017-04-01 23:11:18 -07:00
Adam Barth 9946355ece Remove old, draft dartdoc 2017-04-01 19:12:41 -07:00
Ian Hickson 9be0fc7422 Fill in the test for rounded rectangle splash and highlights (#9092)
Fixes https://github.com/flutter/flutter/issues/9031

Also some updates to mock_canvas that were needed to do this.
2017-04-01 17:47:18 -07:00
Ian Hickson 57b3422795 Bold each line individually (#9069)
This should make the message in Travis logs look better.
2017-04-01 17:47:09 -07:00
Adam Barth ae8994860e Rationalize text input widgets (#9119)
After this patch, there are three major text input widgets:

 * EditableText. This widget is a low-level editing control that
   interacts with the IME and displays a blinking cursor.

 * TextField. This widget is a Material Design text field, with all the
   bells and whistles. It is highly configurable and can be reduced down
   to a fairly simple control by setting its `decoration` property to
   null.

 * TextFormField. This widget is a FormField that wraps a TextField.

This patch also replaces the InputValue data model for these widgets
with a Listenable TextEditingController, which is much more flexible.

Fixes #7031
2017-04-01 17:30:21 -07:00
Jason Simmons 91dbb3c91e roll engine and update tools for the removal of dart:jni (#9137) 2017-03-31 16:20:14 -07:00
Chris Bracken a54979e1fe iOS: fail build wth error if Python six missing (#9135)
Xcode builds depend on the Python 'six' module. If not present, exit
immediately with a useful error message.

The six module is included in the system default Python installation. We
perform this check in case a custom Python install has higher priority
on $PATH; e.g., due to a Homebrew or MacPorts installation.

This extracts an existing doctor check to use it during the build step
as well.
2017-03-31 14:40:22 -07:00
Adam Barth 89aaaa9c32 Improve focus management (#9074)
We now have an explicit focus tree that we manage. Instead of using
GlobalKeys to manage focus, we use FocusNode and FocusScopeNode objects.
The FocusNode is Listenable and notifies when its focus state changes.

Focus notifications trigger by tree mutations are now delayed by one
frame, which is necessary to handle certain complex tree mutations. In
the common case of focus changes being triggered by user input, the
focus notificiation still arives in the same frame.
2017-03-31 13:10:37 -07:00
Collin Jackson 60e05e9a0e Remove Android support library in Flutter builds. Fixes #9120, #9102, #9121. (#9123)
This reverts commit 8f9d4a2260.
2017-03-31 09:35:25 -07:00
Alexandre Ardhuin 2de61a0853 add @required when there's an assert not null (#9124)
* add @required when there's an assert not null

* address review comments
2017-03-31 18:34:13 +02:00
xster 86e9fc1c68 Add FadeTransition to Android page transition (#9086)
* Add FadeTransition to Android page transition

* Also move starting point up

* Add test

* Use const fractional offset
2017-03-30 18:46:32 -07:00
xster 1a87e8182a Change foundation references in foundation to meta (#9107)
* Change foundation references to meta

* Remove specified shows
2017-03-30 18:19:00 -07:00
Devon Carew 01d48c9961 update the flutter create template for IntelliJ 2017.1 (#9106) 2017-03-30 13:53:22 -07:00
Jakob Andersen 104e7ba576 Update plugin template to new channel API. (#9105) 2017-03-30 21:25:31 +02:00
John McCutchan 0ee7fabe9a Improve verbose trace output (#9104)
Related #8876
2017-03-30 10:03:42 -07:00
Ian Hickson d709f18cd2 Do not swallow exceptions in guarded functions. (#9064) 2017-03-30 09:50:30 -07:00
Sarah Zakarias a94e995f3e Add swift version of Platform Channel example (#9098)
* wip

* wip

* delete main.m

* readd main.m

* update to use new channel api

* update android

* removed android/

* remove debug print

* remomved main.m

* Update year in copyright

* break long line and update name

* mit comments

* update examples/README

* break line

* update README

* update test
2017-03-30 15:11:19 +02:00
Sarah Zakarias 089194fc15 update iml and .idea (#9101) 2017-03-30 14:23:12 +02:00
Michael Thomsen cf98008475 Fix path in modules.xml to match new location of .iml (#9100) 2017-03-30 14:13:07 +02:00
Sarah Zakarias 3e6a2c7636 cleanup platform_channel (#9099) 2017-03-30 13:27:48 +02:00
Jakob Andersen f34f8a3197 Add template for plugin projects. (#9076)
Plugin projects are created by running `flutter create --plugin <name>`.

An example app is also created in the plugin project, using the normal 'create' template, which has been modified to allow for conditional plugin code.

Modified the android package name to match package naming conventions (all lower-case, and must match the directory name).
2017-03-30 12:39:21 +02:00
Mikkel Nygaard Ravn 471c97df30 Platform channel API cleanup (#9048) 2017-03-30 08:27:13 +02:00
Adam Barth 0e43e581d1 SliverChildDelegate should know which children are live (#9073)
This patch adds a notification to SliverChildDelegate that says which
children are alive after each layout. The delegate can use this
information to optimize it's underlying model of the children (e.g., by
discarding models for children that are far outside the live range).

Fixes #9045
2017-03-29 22:54:03 -07:00
Chris Bracken abfee824cd Re-enable iOS transitions test in devicelab (#9097)
This reverts commit 326355f0f9.
2017-03-29 19:19:57 -07:00
Chris Bracken bd8e431d79 Restrict timeline collection to a subset of demos (#9093)
Also refactors demos list into a class with `synchronized` and
`profiled` properties.

When run with --trace-startup, as we do in this test, the VM stores
trace events in an endless buffer instead of a ring buffer. To avoid
out-of-memory conditions, we restrict timeline collection to a subset.
2017-03-29 19:12:50 -07:00
Chris Bracken 2993ae8ddb Migrate flutter_view example to new plugin API (#9096)
Ref: flutter/engine#3539
2017-03-29 18:45:19 -07:00
Chris Bracken 002ba64bc1 Migrate platform_channel to updated API (#9094)
See flutter/engine#3539
2017-03-29 17:59:45 -07:00
Jason Simmons e7f1361681 Update artifact names and remove obsolete artifacts (#9091) 2017-03-29 16:30:41 -07:00
Yegor e067041279 increase vmservice timeout; log stderr in microbenchmarks (#9088) 2017-03-29 15:40:17 -07:00
Jason Simmons 72effdd27c Roll the engine and update for new binary names (#9089) 2017-03-29 15:31:36 -07:00