Commit graph

1761 commits

Author SHA1 Message Date
xster 89a7fdfc56 Rename State.config to widget everywhere (#9273)
Rename State.config to State.widget
Rename State.didUpdateConfig to State.didUpdateWidget
Renamed all State subclasses' local variables named config to something else
2017-04-10 18:32:24 -07:00
xster 4f258357c9 Fix lints (#9307) 2017-04-10 02:09:51 -07:00
xster 7ce1cfd48d AppBar automatically show a close button for dialogs (#9268)
* Wiring fullscreen dialog

* Make fullscreen dialog use the new API. Add tests

* Review notes

* Move field back up

* final
2017-04-10 01:05:25 -07:00
Dariusz Baciński d25981cfb3 generate_from_arb has been moved to intl_translantion library (#9255)
* generate_from_arb has been moved to intl_translantion library

* fixed typo

* added missing intl dependency

* Regenerated language files with latest intl script

* Added version to intl_translations

* added isolate min version constraint
2017-04-08 00:25:01 -07:00
Ian Hickson 2a5810e36f Point from gallery's routing table to stocks'. (#9287)
The stocks routing table is a clearer example of how to do this.
People know to look at the gallery, but don't think to look at the
stocks version. This points them from the former to the latter.
2017-04-07 17:51:41 -07:00
Adam Barth f9ae22677a Improve cooperation between scale and drag gestures (#9298)
Now the scale gesture will accept if its focal point moves more than the pan
slop. This change lets it compete with a drag gesture (e.g., a containing scrol
view) in the same way that the pan gesture does.

Fixes #8735
2017-04-07 17:00:32 -07:00
Alexandre Ardhuin 8bcf302e23 use conditional assignment (#9252) 2017-04-07 21:41:17 +02:00
Ian Hickson 3eb87830e9 Constants! Constants everywhere! (#9286)
Aggressively apply the const lint.
2017-04-07 12:24:32 -07:00
Jason Simmons bb0adcb873 Update version strings in Gallery (#9263)
Fixes https://github.com/flutter/flutter/issues/9259
2017-04-06 13:11:20 -07:00
Ian Hickson a52c7b470d Update the examples/ README and associated fixes. (#9090)
This yak shave went as follows:

Fix https://github.com/flutter/flutter/issues/8795 by adding stocks to
the examples README.

Notice the layers entry in that README isn't quite right either.
Update that.

Check the layers/README file is worth pointing at.

Update the layers/README.

Let's run some of the layer tests to see if they still work.

Oops, need to update them to gradle.

Ok let's try running them again.

Oops, sector is broken.

Add a test for sector.

Fix sector. Find you need to add an assert to a const constructor.

Notice we need to turn const asserts on for the analyzer.

Notice the analysis_options files are out of sync with each other and
with the full list of lints.

Turn on the lints that should be on.

Fix the bugs that finds.
2017-04-05 11:28:33 -07:00
Michael Thomsen c48f5f6d00 Remove title code as no title is shown (#9213) 2017-04-05 20:00:18 +02:00
Sarah Zakarias 4a4d100b91 Add battery charging status to Platform Channel example (#9147) 2017-04-05 09:40:35 +02:00
Hans Muller 20e214fa71 Document the buildTransitions() method (#9182) 2017-04-04 17:18:16 -07:00
Jason Simmons 3000c8bb59 Distinguish canceling a route pop from bubbling the pop up to the next level (#9165) 2017-04-04 16:42:31 -07:00
Alexandre Ardhuin 189028a958 Separate the 'if' expression from its statement (#9177) 2017-04-04 21:45:50 +02: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
Adam Barth 5d8bad74d2 Add more dartdocs (#9174) 2017-04-03 22:08:51 -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
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
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
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
Sarah Zakarias 3e6a2c7636 cleanup platform_channel (#9099) 2017-03-30 13:27:48 +02:00
Mikkel Nygaard Ravn 471c97df30 Platform channel API cleanup (#9048) 2017-03-30 08:27:13 +02: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
Alexandre Ardhuin 4c530d5e8c prefer_final_fields (#8967) 2017-03-29 21:21:46 +02:00
Phil Quitslund ab6df3af40 Bump to Dart SDK 1.23.0-dev.10 (#9051)
* Bump to Dart SDK 1.23.0-dev.10

* allows us to understand flutter usage via telemetry
* brings in `@immutable`

Fixes: #9042

* completer fix

* Update to platform 1.1.1.
2017-03-28 14:53:03 -07:00
Michael Goderbauer 506aea0316 enable windows tests with workaround (#9058) 2017-03-28 14:22:03 -07:00
Hans Muller 9192f67252 Shrine gallery demo: support for landscape layout (#9025) 2017-03-27 15:07:24 -07:00
Sarah Zakarias 657a4c3fc6 update platform_channel package name (#9021)
* update platform_channel package name

* lowercase name
2017-03-27 14:33:15 +02:00
Sarah Zakarias 67bd17b4f0 remove platform_channel/android/buildSrc (#9020) 2017-03-27 13:35:20 +02:00
Sarah Zakarias d274888be6 Rename platform_services to platform_channel (#9018)
* Rename platform_services to platform_channel

* rename in README

* renamed tests

* update modules.xml
2017-03-27 11:17:31 +02:00
Hans Muller 606f56221b Eliminated DrawerItem, use ListTile instead (#8992) 2017-03-24 15:34:43 -07:00
Hans Muller 49f5fbb809 Tweaked the appaearance of the cards demo (#8964) 2017-03-24 10:21:59 -07:00
Sarah Zakarias 3c99272ce2 Update the examples README file (#8994)
* Update the examples README file

* Addressed comment
2017-03-24 11:51:54 +01:00
Sarah Zakarias df3a3657cf Remove hello_services sample (#8995) 2017-03-24 11:50:13 +01:00
Michael Thomsen 2d29c62590 Update links to platform services -> channels (#8975) 2017-03-23 14:16:42 +01:00
Sarah Zakarias 18db5a2e68 Add start-up test for flutter_view sample (#8892)
* Add start-up test for flutter_view sample

* add reportMetrics flag to startup test

* rewording in manifest.yaml
2017-03-23 13:20:00 +01:00
Chris Bracken 0ee3f57a10 Build Flutter app as a framework on iOS (#8971)
**THIS IS A BREAKING CHANGE.** See below for migration steps for
existing projects.

Previously, Flutter app code was built as a raw dylib on iOS.  Dynamic
libraries outside of a framework bundle are not supported on iOS, except
for the system Swift libraries provided by Xcode.

See:
https://developer.apple.com/library/content/technotes/tn2435/_index.html#//apple_ref/doc/uid/DTS40017543-CH1-TROUBLESHOOTING_BUNDLE_ERRORS-EMBEDDED__DYLIB_FILES

* Migrates Xcode build from app.dylib to App.framework
* Migrates flutter create template
* Migrates example projects

Migration steps for existing projects
=====================================

The following steps should be taken from the root of your Flutter
project:

1. Edit `ios/.gitignore`: add `/Flutter/App.framework` on a new line.
2. In the Xcode project navigator, remove `app.dylib` from the Flutter
   folder. Delete this file from the `ios/Flutter` directory in your project.
3. Run a build to generate `ios/Flutter/App.framework`. From the command
   line, run `flutter build ios`. If you have not configured app signing
   in Xcode, an alternative method is to open the simulator, then run
   `flutter run -d iP`.
4. In the Xcode project navigator, select the `Runner` project. In the
   project settings that are displayed in the main view, ensure that the
   `Runner` target is selected. You can verify this by exposing the
   sidebar using the [| ] icon in the upper-left corner of the main
   view.
5. Select the *General* tab in the project settings. Under the
   *Embedded Binaries* section, click '+' to add `App.framework`. In the
   sheet that drops down, click the *Add Other...* button. Navigate to
   the `ios/Flutter` directory and select `App.framework`. Click *Open*.
   In the sheet that drops down, select *Create folder references*, then
   click *Finish*.
6. In the project settings, verify that `App.framework` has been added to the
   *Embedded Binaries* and *Linked Frameworks and Libraries* lists.
7. In the Xcode project navigator, drag `App.framework` under the
   Flutter folder.
8. In the Xcode project navigator, select `Flutter` then from the
   *File* menu, select *Add Files to "Runner"...*. Navigate to the
   `ios/Flutter` directory, select `AppFrameworkInfo.plist` and click
   the *Add* button.
9. From the command line, in your project directory, run
   `flutter build clean`, then `flutter run`.

At this point your project should be fully migrated.
2017-03-22 17:41:49 -07:00
Sarah Zakarias 972da54320 Refactor platform_services sample (#8949)
* Refactor platform_services sample

* removed exception
2017-03-22 13:18:38 +01:00
Sarah Zakarias 9adf1bf1b6 Open storyboard documents in Xcode 7 format (#8946) 2017-03-22 10:38:00 +01:00
Alexandre Ardhuin 578ca0a295 use color.shadeXxx instead of color[Xxx] (#8932)
* use color.shadeXxx instead of color[Xxx]

* remove calls to .shade500 on MaterialColor

* remove calls to .shade200 on MaterialAccentColor

* fix test
2017-03-21 23:14:55 +01:00
Adam Barth 269538df58 Add a constant for padding in a Material ListView (#8918)
Fixes #8235
2017-03-20 16:18:41 -07:00
Adam Barth 97816e1571 Rename Dismissable to Dismissible (#8919)
The latter is the proper spelling.

Fixes #8883
2017-03-20 16:17:08 -07:00
Sarah Zakarias d1f73fd0ad Add integration test for the Platform Services app (#8826) 2017-03-20 22:19:03 +01:00
Hans Muller 031e042eee Now each Colors.foo constant is-a Color and a color swatch (#8833) 2017-03-17 15:24:54 -07:00
Adam Barth 5cf04b6141 Rename ImageFit to BoxFit (#8871)
This machinery is useful for arbitrary boxes (e.g., with FittedBox).

Fixes #6463
2017-03-17 15:21:55 -07:00