Commit graph

1587 commits

Author SHA1 Message Date
Seth Ladd 898b52f821 Remove whitelist of screensizes (#6066) 2016-09-26 10:28:04 -07:00
Seth Ladd 54e208e480 Allow a Nexus 6 and 6P to install Gallery (#6038)
Closes https://github.com/flutter/flutter/issues/6037
2016-09-24 18:18:39 -07:00
Seth Ladd 077cf74f84 For reals allow Gallery to be installed by Nexus 5, 5X (#6013)
* For reals allow Gallery to be installed by Nexus 5, 5X

* fix for long line
2016-09-23 14:57:38 -07:00
Dragoș Tiselice ef68f2f03b Added BottomNavigationBar demo. (#6003)
Added a demo of BottomNavigation to the Gallery.
2016-09-23 14:46:30 -07:00
Adam Barth c1a2967430 Use SDK sources to refer to our own packages (#6001)
Switch our pubspec.yamls to using SDK sources so that we can have consistent
source types when we depend on these packages from external packages using SDK
sources.
2016-09-22 20:39:35 -07:00
Seth Ladd 49df2354e6 Allow a Nexus 5 to install the gallery from the Play Store (#6002)
Cargo culted from http://stackoverflow.com/questions/24690739/nexus-5-galaxy-s5-and-some-other-devices-are-showing-not-compatible-in-google
2016-09-22 13:03:56 -07:00
Adam Barth d3efe7da5e Remove flutter_sprites (#5996)
This code is now in its own standalone library. The library is in a private git
repository in the flutter organization because the code is unmaintained. If
you're interested in using and maintaining this code, please contact
flutter-dev@googlegroups.com for more information.
2016-09-22 10:54:06 -07:00
James Robinson a95c9fdb58 Isolate imports of generated Dart code from generated path (#5960)
This rewrites imports of various mojom.dart files from the Flutter
engine repo to instead import normal-looking dart files from the
(new) flutter_services package. This package handles exporting the
correct symbols from generated code wherever that may live.

Includes an engine roll to 3551e7a48e2e336777b15c7637af92fd7605b6c5
which contains the new flutter_services package.
2016-09-21 14:00:29 -07:00
Matt Perry f0d2f5c58a Micro tweak to Pesto logo. Text fades out a bit sooner. (#5983) 2016-09-21 15:28:13 -04:00
Hans Muller fc83640c88 ClampOverscrolls clamps Scrollable, not its Viewport (#5909) 2016-09-21 11:32:19 -07:00
Dragoș Tiselice 7ad5ec40aa Changed Pesto logotype's position. (#5970)
* Changed Pesto logotype's position.

This commit changes Pesto's logotype position so that its curve
aligns with the curve of the image size.

* Added clamping to Pesto logo animation.
2016-09-21 10:58:49 -07:00
Hans Muller aa9aaf2eb7 Restore Flutter gallery license page scrolling (#5934) 2016-09-20 15:13:50 -07:00
Matt Perry 278711d5b1 Add an appbar shadow to Pesto's recipe page. (#5954)
Fixes https://github.com/flutter/flutter/issues/5711
2016-09-20 17:57:09 -04:00
Chinmay Garde 400585cb96 Update flutter/http.dart to use dart:io. (#5940) 2016-09-20 14:17:33 -07:00
Dragoș Tiselice f3813202a1 Removed Pesto logo's animation. (#5957)
Removed Pesto logo's triggered animation in order to remove the
observable 'hop' when scrolling. The whole curve is now entirely
scroll dependent. Fixes #5907.
2016-09-20 13:13:30 -07:00
Adam Barth 17ac73890e Add MediaQuery.textScaleFactor (#5936)
This feature is the implementation of an accessibility feature that changes the
size of text by a constant factor.

Fixes #5873
2016-09-20 09:14:48 -07:00
Dragoș Tiselice eafe1c7a4e Renamed Positioned constructor. (#5927)
Renames stretch constructor to fill for better consistency with
the rest of the framework.
2016-09-19 10:46:06 -07:00
Dragoș Tiselice 51cd8b6799 Added a stretch Positioned constructor. (#5894)
Fixes #5835.
2016-09-16 15:59:01 -07:00
Dragoș Tiselice 84a879e66d Renamed constant. (#5910)
Due to a synchronization issue, a PR was merged with a green build
that was supposed to be rebuilt and to fail. This commit fixes the
issue by renaming the usage of a constant.
2016-09-16 12:24:37 -07:00
Dragoș Tiselice b1a7720315 Fixed capitalization of toolbar. (#5895)
Fixes #4713.
2016-09-16 11:05:03 -07:00
Matt Perry f0f99a45d9 Pesto logo now smoothly animates between image and image+text states. (#5890)
Fixes https://github.com/flutter/flutter/issues/5684
2016-09-16 13:31:54 -04:00
Dragoș Tiselice 87fb075fa1 Renamed DropDown to Dropdown. (#5897)
Fixes #3208.
2016-09-15 17:38:41 -07:00
Dragoș Tiselice 8ac14f8698 Replaced FlexDirection with Axis. (#5896)
Fixes #4618.
2016-09-15 15:23:37 -07:00
Adam Barth 179ea4a0a6 Update framework to account from engine API changes (#5887)
The engine now reports coordinates in physical pixels.
2016-09-15 13:13:42 -07:00
Hans Muller f4904b1459 Refresh indicator overscroll (#5836)
* Added OverscrollIndicatorEdge et al

* RefreshIndicator only clamps its scrollable edge

* added a test

* Updated the test

* fixed lint-os

* fixed a typo

* Scrollable should restore its viewport dimensions when it reappears

* removed an accidental commit

* updated per review feedback
2016-09-14 10:44:51 -07:00
Adam Barth 157ffaac35 Update Dart package dependencies (#5832) 2016-09-12 16:00:12 -07:00
Matt Perry f5c98f6278 Use a light theme for Gallery so it displays a white background while loading. (#5823)
BUG=https://github.com/flutter/flutter/issues/5373
2016-09-12 14:51:04 -04:00
Dragoș Tiselice b298bdc8c4 Fixed expansion panels demo text in dark theme. (#5809)
Changed the text styling to make use of the current theme so that
it doesn't break when the user selects the dark theme.
2016-09-09 16:55:55 -07:00
Seth Ladd 85ac22e4e2 turn verbs into nouns for gallery homepage (#5801)
* turn verbs into nouns for gallery homepage

* shorter is better
2016-09-09 16:36:52 -07:00
Dragoș Tiselice cc3df14268 Removed Pesto's drawer. (#5722)
The drawer was confusing without adding much value. It was
especially confusing when wanting to go back to the Gallery on iOS.
Fixes #5713.
2016-09-09 13:19:03 -07:00
Matt Perry b71d7694ab Prevent Hero transition for AppBar on Pesto recipe page. (#5760)
BUG=https://github.com/flutter/flutter/issues/5351
2016-09-08 16:40:11 -04:00
Phil Quitslund d2fda677e1 Update to Dart 1.20.0-dev.1.0. (#5689)
* Udpate to Dart `1.20.0-dev.1.0`.

Udpate to Dart `1.20.0-dev.1.0` and corresponding `analyzer` package.

* Added `--no-packages-dir`.

* Revert extension to master.

* Added ignores.

* Review nits.

* More nits.
2016-09-08 13:14:08 -07:00
Hans Muller afc0550a67 Fix circle antialiasing in the animation demo (#5729) 2016-09-02 16:13:09 -07:00
Seth Ladd 9e808aad7e Change from plural to singular (#5705)
Closes #5702

Update transitions_perf_test.dart

Update simple_smoke_test.dart
2016-09-02 09:14:06 -07:00
Dragoș Tiselice 8a20b261d0 Changed Material ease animations to fastOutSlowIn. (#5643)
Fixes #5393.
2016-09-02 09:03:51 -07:00
Hans Muller d6a6053630 Contacts icon alignment (#5719) 2016-09-01 15:42:23 -07:00
Dragoș Tiselice 8fed9d9e16 Added expansion panels demo to gallery. (#5539) 2016-09-01 15:36:26 -07:00
Hans Muller f27fa0ece0 Gallery animation demo: lazily compute screen dimensions (#5715) 2016-09-01 14:07:22 -07:00
Dragoș Tiselice 50ead56e0e Made all drawer items actionable. (#5688)
One of the drawer items was dsiabled but still clickable which
led to inconsistent icon coloring. THis commit makes this item
actionable. Fixes #5683.
2016-08-31 15:46:39 -07:00
Dragoș Tiselice b4fb23ad10 Increased text margin in typography demo. (#5691)
Subheading title was too close to the actual example. This commit
increases the size of its box. Fixes #5682.
2016-08-31 15:15:13 -07:00
Dragoș Tiselice 3964aaad55 Added action to Pesto FAB. (#5687)
The floating action button inside of the Pesto demo now opens up
a snackbar. Fixes #5685.
2016-08-31 14:50:14 -07:00
Eddy Ernesto del Valle Pino ed6e7fa06f Ask if the app has location access before asking for location. (#5659) 2016-08-31 09:54:15 -07:00
Jason Simmons a4c9adfb5c Restrict Gallery to phone-sized screens (#5662)
See https://github.com/flutter/flutter/issues/5570
2016-08-30 13:53:57 -07:00
Hans Muller 119758b822 Make the suspended gallery task bar gray (#5651) 2016-08-29 14:59:10 -07:00
Adam Barth e0f6c0db84 Add labels to the slider demos (#5639)
Previously, it was unclear that the middle slider was disabled.

Fixes #5517
2016-08-29 12:17:34 -07:00
Chris Bracken 4bc70c9e91 Fix minor misspellings in comments. (#5641) 2016-08-29 10:05:22 -07:00
Hans Muller d0e72d616b Prevent looking up inherited widget values from initState() (#5609) 2016-08-26 15:19:46 -07:00
Hans Muller a651008acf Animate the "PREVIEW" banner into view (#5598) 2016-08-25 12:30:25 -07:00
Collin Jackson 91b6319a4f Allow disabling the performance overlay in main.dart, fixes #5580 (#5583) 2016-08-24 15:55:00 -07:00
Jason Simmons 95fbb71f0d Change the Gallery sample Android package to not conflict with the version published in Play (#5579) 2016-08-24 14:37:50 -07:00
Collin Jackson 701e0d054a Add update dialog to gallery (#5569)
Add update dialog to gallery, open source part of #4626
2016-08-24 13:32:27 -07:00
Hans Muller 3a6f6c8275 Gallery app preview banner (#5554) 2016-08-23 12:29:07 -07:00
Hans Muller cc600fc0a0 Add a gallery feedback link (#5511) 2016-08-22 09:57:25 -07:00
Hans Muller 03b117a5e5 Remove the "most valuable keys" Hero feature (#5500) 2016-08-19 09:59:39 -07:00
Seth Ladd f2afd05fe6 link to services doc from hello_services example
TBR
2016-08-19 08:03:08 -07:00
Hans Muller e683cb2157 Gallery home page header color should track the material theme (#5486) 2016-08-18 14:15:33 -07:00
Hans Muller 7b2f660417 Stablize gallery status bar height computation (#5485) 2016-08-18 12:41:51 -07:00
Seth Ladd f28cf64127 ios launcher icons with more padding, optimized (#5470) 2016-08-18 10:16:10 -07:00
Eric Seidel 2701c014de Add icons to pesto drawer (#5476)
Fixes https://github.com/flutter/flutter/issues/5462

@mpcomplete
2016-08-18 07:03:22 -07:00
Hans Muller a010d6eb08 Rearrange the Pesto internals (#5466) 2016-08-17 15:30:57 -07:00
Hans Muller 0892f6a503 Corrected the scrollable tab view key in the tabs demo (#5458) 2016-08-17 11:20:28 -07:00
Hans Muller 96ec30b8af Fix Pesto appbar heroics (#5447) 2016-08-17 10:38:38 -07:00
Seth Ladd 8fa6c4d2d7 Transparent icons gallery (#5438)
* new launcher icons for android

* two more sizes for android launcher icons
2016-08-16 14:55:17 -07:00
Hans Muller 082730e94b Tapping status bar scrolls to top on IOS (#5425) 2016-08-16 12:30:39 -07:00
Piyush K 3dda629089 Grammar check on Readme (#5413)
installed changed to installs:
The `flutter run --release` command both builds and installed the Flutter app.
changed to 
The `flutter run --release` command both builds and installs the Flutter app.
2016-08-15 16:29:58 -07:00
Ian Hickson 0d7363322f Fix the logo widget (#5414)
Some tweaks to the logo widget:

* remove bad assert
* allow text color to be configured
* make logo pretty in dark mode in gallery
* fix some docs
2016-08-15 16:02:53 -07:00
Hans Muller 6e62df42b6 Removed unnecessary Shrine hero logic (#5394)
* Removed unnecessary Shrine hero logic
2016-08-15 14:23:53 -07:00
Ian Hickson 955b3e21f7 A Flutter logo widget. (#5382)
Instead of a PNG, the Flutter gallery widget is now drawn in code.

There's now a FlutterLogoDecoration class that paints the flutter logo
anywhere you can use a Decoration (e.g. AnimatedContainer).

There's now a FlutterLogo class that honors the IconTheme.

The About dialog box API now takes a Widget for the applicationIcon,
instead of an ImageProvider. It uses IconTheme to make the icon the
right size instead of using an Image widget.

Add padding, duration, and curve properties to the DrawerHeader.
Make the child of a DrawerHeader optional.

Clean up UserAccuntsDrawerHeader a bit.

Add some useful properties and methods to EdgeInsets.

Add some debug logic to RenderDecoratedBox to catch unpaired
save/restore calls when possible.

Make GestureDetector fill its parent if it has no children. Fixes
https://github.com/flutter/flutter/issues/5380
2016-08-15 12:50:24 -07:00
Hans Muller 914f3adc6e Update gallery application version and label 2016-08-12 11:19:44 -07:00
Ian Hickson 9c15407ba9 When a list is scrolling, children can't be tapped (#5222) (#5348) 2016-08-11 13:40:26 -07:00
Matt Perry 82b55c5ce4 Fix gallery clipping issues on ipod touch. (#5258)
* Shrine tile height now hardcoded to match actual card size.
* Animation demo now scales with screen size.

BUG=https://github.com/flutter/flutter/issues/5002
BUG=https://github.com/flutter/flutter/issues/5003
2016-08-08 11:52:35 -04:00
Chinmay Garde 21ee4b92f1 Specify the IPHONEOS_DEPLOYMENT_TARGET to 8.0. (#5268)
* Update examples to lower the deployment target on iOS.
2016-08-05 14:56:07 -07:00
Ian Hickson 84cbefe2d4 Revert "When a list is scrolling, children can't be tapped" (#5264) 2016-08-05 13:42:55 -07:00
Hans Muller eebe09d402 Set the ScrollConfiguration for dropdown menus (#5255) 2016-08-05 12:57:29 -07:00
Ian Hickson ea7d5bf291 When a list is scrolling, children can't be tapped (#5222) 2016-08-05 10:40:24 -07:00
Matt Perry 260cfcdb7b Pesto: Prevent overscrolling on recipe page. (#5237)
BUG=https://github.com/flutter/flutter/issues/5098
2016-08-05 13:37:27 -04:00
Hans Muller 4a8dbb0e13 Add a repaint boundary to the cards on the shrine order page (#5251) 2016-08-05 10:02:53 -07:00
Eric Seidel 5a0589c781 Remove stray PRODUCT_BUNDLE_IDENTIFIER (#5242)
* Remove stray PRODUCT_BUNDLE_IDENTIFIER

This was erroneously added and overrides
the bundle for the gallery causing signing
to fail in my setup.

@chinmaygarde

* Remove PRODUCT_BUNDLE_IDENTIFIER from all Runner pbxproj's
2016-08-05 10:00:50 -07:00
Eric Seidel ac9ab0c9d6 Update Gallery icons to have a white background. (#5252)
I took the logo_square from:
https://github.com/flutter/identity-assets/tree/master/assets/logo_square
Opened it in preview, gave it a white background
and then dropped it in the icon tool to create
these updated icons.

We may want to use offwhite like we did for Android
but this is sufficient for my demo today.

@hansmuller
2016-08-05 10:00:12 -07:00
Adam Barth d321ce352e Disable parallax in gallery home header (#5250)
We don't yet know how to do this without poping during hero animations.
2016-08-05 09:59:17 -07:00
Adam Barth 4cc094ac9f Remove pop in AppBar hero animations (#5243)
Now the flexible space bar computes its effect from its size rather than from
the Scaffold's animation.
2016-08-05 09:30:45 -07:00
Hans Muller 4fe80830ca Use updated appbar background assets (#5248) 2016-08-05 09:02:34 -07:00
Hans Muller 4770acebd1 updated Android launcher icons (#5238) 2016-08-04 15:35:26 -07:00
Adam Barth 628884a8a8 Make AppBar a Hero (#5214)
This patch improves the Post and Shrine transitions by making the AppBar
into a Hero and changing the default MaterialPageTransition. Now the
AppBar transitions smoothly between screens and the
MaterialPageTransition doesn't involve a fade effect.

Also, rejigger the bounds of the image header in Pesto to avoid the
"pop" at the end of the animation by laying out the image header at its
final visual size instead of relying on occlusion to size the image
header.

Fixes #5202
Fixes #5204
2016-08-04 13:05:18 -07:00
Hans Muller 3a7508d702 New gallery identity (#5210) 2016-08-04 11:07:59 -07:00
Adam Barth 22210c8baf Dispose AnimationController in examples (#5207)
These examples should show the best practices for working with
AnimationControllers.

Fixes #5206
2016-08-04 08:55:59 -07:00
Jason Simmons 5c2623d977 Fix overflow of text on Pesto recipe cards (#5192) 2016-08-02 16:31:46 -07:00
Adam Barth 4086e7a3c3 Improve performance of Pesto hero animation (#5182)
Previously we were resizing a paragraph of text during the animation. Now we
animate the text and the image separately. Also, add a default hero tag for
FloatingActionButton so that it animates as part of the hero transition as
well.
2016-08-02 11:35:15 -07:00
Hans Muller 56a2d2262c Pesto home stack (#5168) 2016-08-01 15:09:50 -07:00
Dragoș Tiselice f3444fcf28 Added BorderRadius. (#5072)
* Added custom radii to RRect.

This is the first commit towads an implementation of
MergeableMaterial. It adds custom radii to RRect.

* Renamed RRect constructors and added BorderRadius.

BorderRadius is a class similar to EdgeInsets that lets you define
all rounded corners of a rounded rectangle easily.
2016-07-29 16:17:57 -07:00
Ian Hickson 51f8fb9979 Add a scrollbar to the license screen. (#5114)
And make Scrollbar work with LazyBlock.

And an about box to the Stocks sample app.
2016-07-29 15:44:12 -07:00
Adam Barth c674b4a803 Rename Image.fromNetwork and Image.fromAssetBundle (#5149)
These now have sorter names to make the callers less verbose.
2016-07-29 13:28:08 -07:00
Adam Barth 79364f0a06 Add Container.align and Container.position (#5128)
These let you add Align widget to the inside or outside of a container.
Several customers have asked for these properties.

Fixes #4950
2016-07-29 10:27:11 -07:00
Adam Barth 534097ffb6 Use named Image constructors (#5129)
Some folks didn't realize these existed and asked us to add them. By
using them in examples, hopefully folks will discover them more easily.
2016-07-29 08:27:28 -07:00
Hans Muller 3cebd04116 More gallery tweaks (#5125) 2016-07-28 16:23:17 -07:00
Hans Muller 578d98ea46 Gallery demo tweaks (#5116) 2016-07-28 12:35:26 -07:00
pq 13c3f9d946 Update Dart (1.19.0-dev.0.0) and analyzer (0.27.4-alpha.19). 2016-07-27 10:44:44 -07:00
Hans Muller 0265dd3c1a Hide the data table demo for now (#5060) 2016-07-27 09:07:29 -07:00
Hans Muller a555ee4771 TimePicker layout tweaks (#5047) 2016-07-26 12:50:40 -07:00
Hans Muller 76ea70a123 Change the Gallery AnimationDemo category (#5041) 2016-07-26 11:00:11 -07:00
Adam Barth e4bee6b29b Remove unused assets from flutter_gallery (#5033) 2016-07-25 17:05:50 -07:00
Hans Muller 69aef8f217 Fast scrolling in the gallery tabs demo (#5016) 2016-07-22 16:00:46 -07:00
Adam Barth 39e759212f Improve compositing strategy for Shrine (#5014)
This patch includes a number of improvements:

 * Material page routes now put a repaint boundary inside their transition so
   they don't repaint during the transition.
 * Heroes that are on a quest now get a repaint boundary so we repaint them
   individually.
 * I've hoisted the transparent material for the product items up in the widget
   tree, which doesn't affect performance but makes the ink splashes reach the
   edge of the product cards.
 * I've changed the repaint rainbow visualization to make it easier to see
   what's going on.
2016-07-22 14:09:48 -07:00
Jason Simmons 3fe3e9a14f Make PestoDemoState.scaffoldKey non-static so Favorites can instantiate a second PestoDemo (#5005)
Fixes https://github.com/flutter/flutter/issues/4996
2016-07-22 12:41:41 -07:00
Dragoș Tiselice 6f0635d6e8 Merge pull request #4953 from flutter/drawer-header-update
Updated DrawerHeader to new spec.
2016-07-21 11:17:18 -07:00
Hans Muller 36eb4a066f Support for Material arc point and rect transitions (#4938) 2016-07-21 10:48:41 -07:00
Seth Ladd 4abaf64ccb clarify command in README (#4983) 2016-07-21 09:29:52 -07:00
Dragos Tiselice 65e77142e9 Updated DrawerHeader and added UserAccountDrawer.
Removed old Stack layout and added a simple-to-extend interface for the
new drawer header. Also added a specialized UserAccountsDrawerHeader
consistent with Material Design guidelines.
2016-07-20 16:16:08 -07:00
Seth Ladd 5352e89b65 instructions for building the gallery (#4979)
* instructions for building the gallery

* tweaks from review

* tweaks from review
2016-07-20 14:07:19 -07:00
Devon Carew 57b76a050f Hello services run (#4969)
* making flutter run work with gradle

* locate android studio

* add test for settings

* review comments
2016-07-19 20:00:02 -07:00
Matt Perry 0dacc5e150 Use a Scaffold for the Pesto recipe page for better appbar behavior. (#4951)
The appbar now scrolls off screen when you scroll the page far enough.

BUG=https://github.com/flutter/flutter/issues/4410
2016-07-19 15:36:24 -04:00
Hans Muller 67626a29c4 IOS flutter_gallery => Flutter Gallery (#4947) 2016-07-18 12:20:39 -07:00
Hans Muller 7a3c0a2eba Draw a smoother overscroll indicator on Android (#4945) 2016-07-18 12:20:00 -07:00
Hans Muller 05e200f12a Fixed some typos (#4929) 2016-07-15 13:53:51 -07:00
Hans Muller 012d9381a8 RefreshIndicator backgroundColor (#4924) 2016-07-14 17:24:36 -07:00
Jason Simmons e0174c9dad Update hello_services for an engine API change (#4919) 2016-07-14 11:46:26 -07:00
Hans Muller 12764a0066 RefreshIndicatorState.show() (#4877) 2016-07-11 10:11:34 -07:00
Hans Muller 445f250c91 Gallery UI tweaks (#4861) 2016-07-11 07:26:36 -07:00
Adam Barth fc711a10cd Custom switch images are nutty (#4852)
Rather than requiring the developer to specify a full Decoration, we now
just take an ImageProvider for the thumb image. Also, fix
ImageFit.scaleDown to actually work.

Fixes #4571
Fixes #4673
2016-07-08 09:51:51 -07:00
Hans Muller 0f15263cea RefreshIndicator dismiss transition, remain visible during refresh, etc (#4844) 2016-07-07 16:30:10 -07:00
Adam Barth a33fc49659 Remove dangling reference to ViewController (#4841)
We want to use the FlutterViewController in this new project template.

Fixes #4840
2016-07-07 10:45:58 -07:00
Adam Barth 151750baa8 Update the ios projects for examples to HelloServices model (#4822)
We now use a different approach for ios projects where the developer controls
the Xcode project file. This patch removes the old ".generated" approach in
favor of the new approach.
2016-07-06 14:13:21 -07:00
Adam Barth 8d56fae557 Finish integrating HelloServices model on iOS (#4820)
This patch changes the default `flutter create` command to generate a
HelloServices-style app on iOS. As a consequence, the Atom integration now
fully works with HelloServices.
2016-07-06 13:13:28 -07:00
Hans Muller d9b9983e1a Refresh indicator (#4788) 2016-06-30 10:07:28 -07:00
Hans Muller 77cd8ee40e Reproduce the Shrine home page portrait grid layout (#4779) 2016-06-28 11:05:18 -07:00
Adam Barth 2af668f832 Change how navigator prevents redundant operations (#4769)
* Change how navigator prevents redundant operations

Instead of requiring transactions, we now cancel all active pointers that are
interacting with the navigator and absorb future pointers until we get a chance
to build. This approach isn't perfect (e.g., events that trigger off the
cancelled pointers could still interact with the navigator), but it should be
better than the current transaction-based approach.

Fixes #4716

* Remove openTransaction

* test

* fixup
2016-06-27 13:07:47 -07:00
Hans Muller 08bf1b6bce Scrollable dropdown, dropdown underline cosmetics (#4766) 2016-06-27 10:28:20 -07:00
Adam Barth 2fa6a709c9 Improve documentation for framework.dart (#4758) 2016-06-25 12:22:14 -07:00
Hans Muller 0a4f96e2b6 Gallery about box: state Flutter's status and link to our website (#4746) 2016-06-24 17:54:21 -07:00
Hans Muller bb2e7b5250 Add AppBar iconTheme parameter (#4693) 2016-06-22 15:19:31 -07:00
Ian Hickson cd89e867ef About box API (#4677)
This API is the front-end part of the work on showing licenses.

Future patches will:

* Provide an API for registering what licenses should be shown here,
  which will be used by this feature to shown licenses but could also be
  used by custom code for showing licenses (e.g. for people not using
  the Material widgets).

* Actually populate this license API from all the licenses we currently
  use in the engine, in the framework, and from any pub packages that
  are used (directly or indirectly) by the application.
2016-06-22 10:42:02 -07:00
Hans Muller 7c3a943548 Remove the gallery Live Demo buttons, etc (#4678) 2016-06-21 17:28:41 -07:00
Adam Barth a8f6f44a55 Update engine to include new version of Mojo (#4668)
This required switching from the Future-based bindings to the callback-based
bindings.
2016-06-21 15:53:47 -07:00
Hans Muller 0e38cba95f Make the limit that defines Row/Column free space configurable (#4646) 2016-06-21 14:29:22 -07:00
Jason Simmons fad7cf59e3 Update hello_services for a change to the message listener API (#4670) 2016-06-21 14:26:30 -07:00
Ian Hickson e502e9c8f8 ImageIcon (#4649)
Anywhere that accepted IconData now accepts either an Icon or an
ImageIcon.

Places that used to take an IconData in an `icon` argument, notably
IconButton and DrawerItem, now take a Widget in that slot. You can wrap
the value that used to be passed in in an Icon constructor to get the
same result.

Icon itself now takes the icon as a positional argument, for brevity.

ThemeData now has an iconTheme as well as a primaryIconTheme, the same
way it has had a textTheme and primaryTextTheme for a while.

IconTheme.of() always returns a value now (though that value itself may
have nulls in it). It defaults to the ThemeData.iconTheme.

IconThemeData.fallback() is a new method that returns an icon theme data
structure with all fields filled in.

IconTheme.merge() is a new constructor that takes a context and creates
a widget that mixes in the new values with the inherited values.

Most places that introduced an IconTheme widget now use IconTheme.merge.

IconThemeData.merge and IconThemeData.copyWith act in a way analogous to
the similarly-named members of TextStyle.

ImageIcon is introduced. It acts like Icon but takes an ImageProvider
instead of an IconData.

Also: Fix the analyzer to actually check the stocks app.
2016-06-20 21:04:45 -07:00
Jason Simmons 3b9d8c5eb5 Call onPostResume to restart the animator in the example Android activity (#4634)
(onResume is now a no-op)

Fixes https://github.com/flutter/flutter/issues/4506
2016-06-20 13:06:10 -07:00
Hans Muller c707b53f01 AppBar bottom widget, not necessarily a TabBar (#4631) 2016-06-20 12:45:20 -07:00
Hans Muller 327d974dc5 Added shopping cart and sorting to Shrine (#4616) 2016-06-20 09:47:58 -07:00
Adam Barth ba4f1e02c2 Add an example of listening to app lifecycle events (#4623)
Fixes #4553
2016-06-18 10:43:38 -07:00
Hans Muller 2de2ce35bb It is not easy being green (#4606) 2016-06-16 17:33:12 -07:00
Hans Muller 69b4bcaff5 Use an ellipsis to clip wide cards_demo titles (#4604) 2016-06-16 17:20:54 -07:00
Hans Muller 46a660f0d0 Removed obsolete flutter gallery assets (#4605) 2016-06-16 16:56:11 -07:00
Matt Perry 02a4483914 Pesto: Fix app bar height when returning from recipe page. (#4579)
The problem was that the Scaffold was getting a new key each time we
navigated to the main page. The key influences where page state is
stored, including the scroll offset. So for a single frame, the Scaffold
incorrectly thinks the scroll offset is 0 and the app bar should be
expanded.

BUG=https://github.com/flutter/flutter/issues/4400
2016-06-16 17:24:06 -04:00
Ian Hickson 2dfdc840b1 Refactor everything to do with images (#4583)
Overview
========

This patch refactors images to achieve the following goals:

* it allows references to unresolved assets to be passed
  around (previously, almost every layer of the system had to know about
  whether an image came from an asset bundle or the network or
  elsewhere, and had to manually interact with the image cache).

* it allows decorations to use the same API for declaring images as the
  widget tree.

It requires some minor changes to call sites that use images, as
discussed below.

Widgets
-------

Change this:

```dart
      child: new AssetImage(
        name: 'my_asset.png',
        ...
      )
```

...to this:

```dart
      child: new Image(
        image: new AssetImage('my_asset.png'),
        ...
      )
```

Decorations
-----------

Change this:

```dart
      child: new DecoratedBox(
        decoration: new BoxDecoration(
          backgroundImage: new BackgroundImage(
            image: DefaultAssetBundle.of(context).loadImage('my_asset.png'),
            ...
          ),
          ...
        ),
        child: ...
      )
```

...to this:

```dart
      child: new DecoratedBox(
        decoration: new BoxDecoration(
          backgroundImage: new BackgroundImage(
            image: new AssetImage('my_asset.png'),
            ...
          ),
          ...
        ),
        child: ...
      )
```

DETAILED CHANGE LOG
===================

The following APIs have been replaced in this patch:

* The `AssetImage` and `NetworkImage` widgets have been split in two,
  with identically-named `ImageProvider` subclasses providing the
  image-loading logic, and a single `Image` widget providing all the
  widget tree logic.

* `ImageResource` is now `ImageStream`. Rather than configuring it with
  a `Future<ImageInfo>`, you complete it with an `ImageStreamCompleter`.

* `ImageCache.load` and `ImageCache.loadProvider` are replaced by
  `ImageCache.putIfAbsent`.

The following APIs have changed in this patch:

* `ImageCache` works in terms of arbitrary keys and caches
  `ImageStreamCompleter` objects using those keys. With the new model,
  you should never need to interact with the cache directly.

* `Decoration` can now be `const`. The state has moved to the
  `BoxPainter` class. Instead of a list of listeners, there's now just a
  single callback and a `dispose()` method on the painter. The callback
  is passed in to the `createBoxPainter()` method. When invoked, you
  should repaint the painter.

The following new APIs are introduced:

* `AssetBundle.loadStructuredData`.

* `SynchronousFuture`, a variant of `Future` that calls the `then`
  callback synchronously. This enables the asynchronous and
  synchronous (in-the-cache) code paths to look identical yet for the
  latter to avoid returning to the event loop mid-paint.

* `ExactAssetImage`, a variant of `AssetImage` that doesn't do anything clever.

* `ImageConfiguration`, a class that describes parameters that configure
  the `AssetImage` resolver.

The following APIs are entirely removed by this patch:

* `AssetBundle.loadImage` is gone. Use an `AssetImage` instead.

* `AssetVendor` is gone. `AssetImage` handles everything `AssetVendor`
  used to handle.

* `RawImageResource` and `AsyncImage` are gone.

The following code-level changes are performed:

* `Image`, which replaces `AsyncImage`, `NetworkImage`, `AssetImage`,
  and `RawResourceImage`, lives in `image.dart`.

* `DecoratedBox` and `Container` live in their own file now,
  `container.dart` (they reference `image.dart`).

DIRECTIONS FOR FUTURE RESEARCH
==============================

* The `ImageConfiguration` fields are mostly aspirational. Right now
  only `devicePixelRatio` and `bundle` are implemented. `locale` isn't
  even plumbed through, it will require work on the localisation logic.

* We should go through and make `BoxDecoration`, `AssetImage`, and
  `NetworkImage` objects `const` where possible.

* This patch makes supporting animated GIFs much easier.

* This patch makes it possible to create an abstract concept of an
  "Icon" that could be either an image or a font-based glyph (using
  `IconData` or similar). (see
  https://github.com/flutter/flutter/issues/4494)

RELATED ISSUES
==============

Fixes https://github.com/flutter/flutter/issues/4500
Fixes https://github.com/flutter/flutter/issues/4495
Obsoletes https://github.com/flutter/flutter/issues/4496
2016-06-16 09:49:48 -07:00
Hans Muller 5766cdacd3 Define LayoutWidgetBuilder in terms of BoxConstraints instead of Size (#4578) 2016-06-15 14:11:58 -07:00
Phil Quitslund 0f1132f93a Merge pull request #4559 from pq/missing_returns
Add missing returns.
2016-06-14 15:41:49 -07:00
pq d3b4186744 Review nits. 2016-06-14 15:32:42 -07:00
pq d81212a387 Cleanup. 2016-06-14 15:21:42 -07:00
pq f5a4e63237 Added asserts. 2016-06-14 15:19:14 -07:00