1. 25 May, 2016 1 commit
  2. 24 May, 2016 1 commit
  3. 23 May, 2016 1 commit
  4. 18 May, 2016 1 commit
  5. 17 May, 2016 1 commit
  6. 03 May, 2016 3 commits
  7. 02 May, 2016 1 commit
  8. 29 Apr, 2016 1 commit
    • Ian Hickson's avatar
      Refactor the test framework (#3622) · 91dd9699
      Ian Hickson authored
      * Refactor widget test framework
      
      Instead of:
      
      ```dart
        test("Card Collection smoke test", () {
          testWidgets((WidgetTester tester) {
      ```
      
      ...you now say:
      
      ```dart
        testWidgets("Card Collection smoke test", (WidgetTester tester) {
      ```
      
      Instead of:
      
      ```dart
        expect(tester, hasWidget(find.text('hello')));
      ```
      
      ...you now say:
      
      ```dart
        expect(find.text('hello'), findsOneWidget);
      ```
      
      Instead of the previous API (exists, widgets, widget, stateOf,
      elementOf, etc), you now have the following comprehensive API. All these
      are functions that take a Finder, except the all* properties.
      
      * `any()` - true if anything matches, c.f. `Iterable.any`
      * `allWidgets` - all the widgets in the tree
      * `widget()` - the one and only widget that matches the finder
      * `firstWidget()` - the first widget that matches the finder
      * `allElements` - all the elements in the tree
      * `element()` - the one and only element that matches the finder
      * `firstElement()` - the first element that matches the finder
      * `allStates` - all the `State`s in the tree
      * `state()` - the one and only state that matches the finder
      * `firstState()` - the first state that matches the finder
      * `allRenderObjects` - all the render objects in the tree
      * `renderObject()` - the one and only render object that matches the finder
      * `firstRenderObject()` - the first render object that matches the finder
      
      There's also `layers' which returns the list of current layers.
      
      `tap`, `fling`, getCenter, getSize, etc, take Finders, like the APIs
      above, and expect there to only be one matching widget.
      
      The finders are:
      
       * `find.text(String text)`
       * `find.widgetWithText(Type widgetType, String text)`
       * `find.byKey(Key key)`
       * `find.byType(Type type)`
       * `find.byElementType(Type type)`
       * `find.byConfig(Widget config)`
       * `find.byWidgetPredicate(WidgetPredicate predicate)`
       * `find.byElementPredicate(ElementPredicate predicate)`
      
      The matchers (for `expect`) are:
      
       * `findsNothing`
       * `findsWidgets`
       * `findsOneWidget`
       * `findsNWidgets(n)`
       * `isOnStage`
       * `isOffStage`
       * `isInCard`
       * `isNotInCard`
      
      Benchmarks now use benchmarkWidgets instead of testWidgets.
      
      Also, for those of you using mockers, `serviceMocker` now automatically
      handles the binding initialization.
      
      This patch also:
      
      * changes how tests are run so that we can more easily swap the logic
        out for a "real" mode instead of FakeAsync.
      
      * introduces CachingIterable.
      
      * changes how flutter_driver interacts with the widget tree to use the
        aforementioned new API rather than ElementTreeTester, which is gone.
      
      * removes ElementTreeTester.
      
      * changes the semantics of a test for scrollables because we couldn't
        convince ourselves that the old semantics made sense; it only worked
        before because flushing the microtasks after every event was broken.
      
      * fixes the flushing of microtasks after every event.
      
      * Reindent the tests
      
      * Fix review comments
      91dd9699
  9. 27 Apr, 2016 1 commit
    • Adam Barth's avatar
      Expose dispatchDependencyChanged in InheritedWidget (#3580) · d8f2d018
      Adam Barth authored
      Some inherited widgets want to call this function direction, for example to
      notify children when a mutable model object changes. Exposing this function to
      subclasses of InheritedWidget is clear then forcing them to compute
      updateShouldNotify for mutable model objects.
      d8f2d018
  10. 25 Apr, 2016 1 commit
    • Adam Barth's avatar
      Block should work inside LazyBlock (#3546) · cc9d602b
      Adam Barth authored
      Previously we were locking down the state even when calling layout in
      LazyBlock. Now we lock only when building children. Making this work well
      involved moving the catch out of lockState and into the few callers who
      actually wanted it.
      
      Fixes #3534
      cc9d602b
  11. 22 Apr, 2016 1 commit
    • Ian Hickson's avatar
      Clean up our timeline events. (#3504) · b5a827bf
      Ian Hickson authored
      This adds in particular the ability to track the time at which the
      framework boots up, and the time at which we are confident we have
      completed the first useful frame.
      b5a827bf
  12. 19 Apr, 2016 1 commit
    • Ian Hickson's avatar
      Refactor service extensions (#3397) · 261923e5
      Ian Hickson authored
      Bindings now have a debugRegisterServiceExtensions() method that is
      invoked in debug mode (only). (Once we have a profile mode, there'll be
      a registerProfileServiceExtensions() method that gets called in that
      mode only to register extensions that apply then.)
      
      The BindingBase class provides convenience methods for registering
      service extensions that do the equivalent of:
      
      ```dart
      void extension() { ... }
      bool extension([bool enabled]) { ... }
      double extension([double extension])  { ... }
      Map<String, String> extension([Map<String, String> parameters]) { ... }
      ```
      
      The BindingBase class also itself registers ext.flutter.reassemble,
      which it has call a function on the binding called
      reassembleApplication().
      
      The Scheduler binding now exposes the preexisting
      ext.flutter.timeDilation.
      
      The Renderer binding now exposes the preexisting ext.flutter.debugPaint.
      
      The Renderer binding hooks reassembleApplication to trigger the
      rendering tree to be reprocessed (in particular, to fix up the
      optimisation closures).
      
      All the logic from rendering/debug.dart about service extensions is
      replaced by the above.
      
      I moved basic_types to foundation.
      
      The FlutterWidgets binding hooks reassembleApplication to trigger the
      widget tree to be entirely rebuilt.
      
      Flutter Driver now uses ext.flutter.driver instead of
      ext.flutter_driver, and is hooked using the same binding mechanism.
      Eventually we'll probably move the logic into the Flutter library so
      that you just get it without having to invoke a special method first.
      261923e5
  13. 15 Apr, 2016 2 commits
    • Ian Hickson's avatar
      Material Data Tables (#3337) · a91bc0ba
      Ian Hickson authored
      + Add new demo to gallery to show data tables. (This currently doesn't
      use a Card; I'll create a Card version in a subsequent patch.)
      
      + Fix checkbox alignment. It now centers in its box regardless.
      
      + Add Colors.black54.
      
      + Some minor fixes to dartdocs.
      
      + DataTable, DataColumn, DataRow, DataCell
      
      + RowInkWell
      
      + Augment dartdocs of materia/debug.dart.
      
      + DropDownButtonHideUnderline to hide the underline in a drop-down when
        used in a DataTable.
      
      + Add new capabilities to InkResponse to support RowInkWell.
      
      + Augment dartdocs of materia/material.dart.
      
      + Add an assert to catch nested Blocks.
      
      + Fix a crash in RenderBox when you remove an object and an ancestor
        used its baseline. (https://github.com/flutter/flutter/issues/2874)
      
      + Fix (and redocument) RenderBaseline/Baseline.
      
      + Add flex support to IntrinsicColumnWidth.
      
      + Document more stuff on the RenderTable side.
      
      + Fix a bug with parentData handling on RenderTable children.
      
      + Completely rewrite the column width computations. The old logic made
        no sense at all.
      
      + Add dartdocs to widgets/debug.dart.
      
      + Add a toString for TableRow.
      a91bc0ba
    • Ian Hickson's avatar
      Split services/ into services/ and foundation/ (#3350) · e41c1c0b
      Ian Hickson authored
      We're getting back to the point where we have a bunch of foundation APIs
      and it's getting confusing having them mixed with services/.
      e41c1c0b
  14. 14 Apr, 2016 1 commit
    • pq's avatar
      Adding `@optionalTypeArgs`. · de25ea22
      pq authored
      With the new dev build we've got the updated linter and so can use the `@optionalTypeArgs` annotation (in `meta 0.12.0`).
      
      Bonus: this lets us clean up one more Regexp in the `analyze` command! :)
      de25ea22
  15. 07 Apr, 2016 1 commit
    • Adam Barth's avatar
      TabView should keep state · 76f66605
      Adam Barth authored
      Previously, we lost sync with the tab view contents when switching tabs. Now we
      key the subtrees to make sure they keep their state across tab animations.
      
      Fixes #3147
      76f66605
  16. 06 Apr, 2016 1 commit
    • Adam Barth's avatar
      Remove MixedViewport · 2d49e807
      Adam Barth authored
      Also, port the MixedViewport tests to LazyBlockViewport. Fix bugs found by the tests.
      2d49e807
  17. 05 Apr, 2016 1 commit
    • Adam Barth's avatar
      Adds a first draft of LazyBlock · 618e7e49
      Adam Barth authored
      LazyBlock is intended as a replacement for MixedViewport. Rather than
      
      maintaining a table of all the observed child sizes (like
      
      MixedViewport), LazyBlock works by dead reckoning the location of the
      
      children based on the existing viewport. This approach makes it easier
      
      to resize children because LazyBlock doesn't cache any additional
      
      information that would need to be invalidated.
      
      
      
      This patch contains a first draft of LazyBlock that works in a simple
      
      usage scenario. Subsequent patches will replace
      
      ScrollableMixedWidgetList with LazyBlock and port the existing
      
      ScrollableMixedWidgetList tests over to LazyBlock.
      
      
      
      Related to #3075
      618e7e49
  18. 02 Apr, 2016 1 commit
    • Ian Hickson's avatar
      Rationalise all our exception handling. · ee703da9
      Ian Hickson authored
      - Create a FlutterErrorDetails struct-like class that describes an
      
        exception along with more details that aren't in the exception, like
      
        where it was caught and what was going on when it was caught.
      
      
      
      - Provide a FlutterError static API for handling these objects:
      
      
      
        - FlutterError.onError which is called whenever Flutter catches an
      
          error.
      
      
      
        - FlutterError.reportError() which handles an error.
      
      
      
        - FlutterError.dumpErrorToConsole() which is the default behavior
      
          for onError.
      
      
      
      - Removes all the existing exception handler callbacks.
      
      
      
      - Replaces all the existing places that described exceptions using
      
        debugPrint with calls to FlutterError.reportError().
      
      
      
      - Extend lockState() to also catch exceptions, so that we catch
      
        exceptions that happen during finalizers.
      
      
      
      - Make the test framework catch errors and treat them as failures.
      
      
      
      - Provide a mechanism to override this behavior in the test framework.
      
      
      
      - Make the tests that used to depend on the exception handler
      
        callbacks use this new mechanism.
      
      
      
      - Make pump() also support the phase argument.
      
      
      
      - Improve some tests using these new features.
      
      
      
      Fixes #2356, #2988, #2985, #2220.
      ee703da9
  19. 01 Apr, 2016 1 commit
    • Adam Barth's avatar
      Capture closures around megamorphic dispatches · 622bec43
      Adam Barth authored
      The performLayout and build callsite are highly megamorphic because they
      dispatch into a large number of clients. However, for a given caller, the
      callee is always of the same type, which means the megamorphic lookup exactly
      factors by the caller. We can speed up the dispatch by capturing a closure at
      initialization and then monomorphically dispatching through the closure.
      622bec43
  20. 31 Mar, 2016 3 commits
  21. 29 Mar, 2016 2 commits
    • Adam Barth's avatar
      Reactivating a StatefulElement should imply a build · b841e868
      Adam Barth authored
      Fixes #2901
      b841e868
    • Hixie's avatar
      Table widget · baf06515
      Hixie authored
      - Add x and y to the parent data, in case it's useful. In point of fact,
        I ended up not needing it.
      
      - Make columnWidths settable rather than having a setter so that the
        code in the widgets layer is more idiomatic.
      
      - Teach setFlatChildren about avoiding unnecessary drop/adopt loops.
      
      - Assert that the child list length is correct more aggressively so that
        we catch the dumb bug I had more quickly next time.
      
      - Improve the toString() to handle empty tables better.
      
      - Resort the imports in framework.dart.
      
      - Introduce a LocalKey for cases where you don't want to allow use of
        GlobalKey.
      
      - Make inflateWidget and deactivateChild public for subclass use.
      
      - Table widget.
      
      - Cell widget.
      
      - TableRow fake widget.
      baf06515
  22. 28 Mar, 2016 1 commit
  23. 27 Mar, 2016 1 commit
  24. 24 Mar, 2016 1 commit
    • Adam Barth's avatar
      Inherited widgets should work across reactivations · e361c0b0
      Adam Barth authored
      Previously we updated only the reactivated element's inherited widgets. Now we
      update all the inherited widgets for the whole subtree that's being
      reactivated. We need to visit the whole subtree anyway, so there isn't much of
      a loss.
      
      Fixes #2733
      Fixes #2438
      Fixes #1701
      e361c0b0
  25. 23 Mar, 2016 1 commit
  26. 22 Mar, 2016 1 commit
  27. 18 Mar, 2016 2 commits
  28. 17 Mar, 2016 1 commit
  29. 15 Mar, 2016 1 commit
  30. 14 Mar, 2016 3 commits
  31. 12 Mar, 2016 1 commit