1. 25 Sep, 2015 1 commit
    • Hixie's avatar
      fn3: Port Card Collection demo · a765507c
      Hixie authored
      Also:
      
      - Make Dismissable report when it starts squashing, since otherwise we
        don't invalidate the list early enough and it gets mad that it wasn't
        told one of its children had changed size.
      
      - Have Dismissable check that it gets removed after it's dismissed, to
        avoid having lots of redundant widgets around.
      
      - Start tracking the height of each child of a MixedViewport, so that we
        don't accumulate floating point errors when a child jiggles up and down.
      
      - Have _childOffsets reuse its storage space rather than newing up a new
        copy each time we reset the cache.
      
      - Avoid double-updating child sizes when handling mixed viewport invalidations.
      a765507c
  2. 24 Sep, 2015 2 commits
  3. 18 Sep, 2015 1 commit
  4. 16 Sep, 2015 2 commits
    • Adam Barth's avatar
      Move Drawer to GestureDetector · 74f7d9ef
      Adam Barth authored
      This fixes an issue in the stocks app in horizontal mode where you could both
      scroll and drag the drawer at the same time.
      74f7d9ef
    • Hixie's avatar
      Be more explicit about what's state in dismissable · adf7c48d
      Hixie authored
      Move _activeCardDragEndPoint near build() so it's more obvious that it
      is part of the build state.
      
      Make a couple of functions use setState() since they modify variables
      that are used by build().
      
      Add a more detailed comment to the empty setState() call, since those
      are dubious in general and need explaining when they occur, lest people
      start using them as magic incantations to Make Things Work.
      adf7c48d
  5. 11 Sep, 2015 1 commit
  6. 10 Sep, 2015 1 commit
    • Adam Barth's avatar
      Fold fling gesture into onDragEnd · 63101e49
      Adam Barth authored
      That way the fling engages in the same direction as the scroll. For example, if
      you have a horizontal scroll nested inside a vertical scroll, the fling will
      take place in the same direction as the scroll.
      63101e49
  7. 08 Sep, 2015 1 commit
    • Adam Barth's avatar
      Introduce package:sky/animation.dart · b356d146
      Adam Barth authored
      Move the animation libraries into src/animation and change importers to use
      package:sky/animation.dart. Also, move scheduler.dart into the animation
      library so that the animation library can be self-contained.
      b356d146
  8. 04 Sep, 2015 2 commits
    • Hans Muller's avatar
    • Hans Muller's avatar
      Add Dismissable support for DismissDirection · 4e01c054
      Hans Muller authored
      ```
      enum DismissDirection {
        vertical,
        horizontal,
        left,
        right,
        up,
        down
      }
      ```
      
      To only enable dismissing to the right create the `Dismissable` with `direction: DismissDirection.right`. By default direction is `DismissDirection.horizontal` (left or right).
      
      Updated the card_collection "Swipe Away" demo with a drawer that can be used to select one of the three X axis dismiss directions. Currently the MixedViewport class doesn't support horizontal scrolling, so the demo doesn't support the X axis dismiss directions.
      4e01c054
  9. 03 Sep, 2015 1 commit
    • Hans Muller's avatar
      Fix minor problems in _ScrollGestureRecognizer, Dismissable · 952e7358
      Hans Muller authored
      Alternating scroll gestures would sometimes be ignored because _ScrollGestureRecognizer didn't always reset its _state when the pointer[s] went up.
      
      A Dismissable dismiss triggered by a drag and then a fling could cause the next attempt to drag-dimiss to fail.
      
      Fixed the definition of lerpColor().
      952e7358
  10. 02 Sep, 2015 1 commit
    • Adam Barth's avatar
      Move widgets and rendering inside src · 693ddcd8
      Adam Barth authored
      Code outside of package:sky should import this code using
      
      package:sky/rendering.dart
      package:sky/widgets.dart
      
      Moving this code into the "src" directory is a convention that signifies that
      and it cleans up the generated dartdoc because the libraries in the src
      directory aren't included in the generated documentation. Instead, the classes
      are documented in the widgets.dart and rendering.dart libraries.
      693ddcd8
  11. 31 Aug, 2015 1 commit
    • Hans Muller's avatar
      Convert Dismissable to use gestures · 7a42fe34
      Hans Muller authored
      Convert Dismissable to use the ScrollStart, ScrollUpdate, and ScrollEnd gestures. Support for fling gestures is TBD.
      
      Included a basic unit test that checks that one item can be dismissed with a press-drag-release gesture.
      
      Fixed the scroll gesture recognizer: if the last pointer goes up and candidate recognizers still exist, then reject the gesture.
      7a42fe34
  12. 22 Aug, 2015 1 commit
  13. 19 Aug, 2015 1 commit
  14. 14 Aug, 2015 1 commit
  15. 10 Aug, 2015 1 commit
  16. 05 Aug, 2015 1 commit
  17. 04 Aug, 2015 2 commits
    • Adam Barth's avatar
      Rename widgets/widget.dart to widgets/framework.dart · 054ebbf3
      Adam Barth authored
      It was confusing to have both widget.dart and widgets.dart
      054ebbf3
    • James Robinson's avatar
      Teach event system about disposition and make 'consumed' disposition terminal · 53163f8b
      James Robinson authored
      This introduces the notion of event disposition and allows event
      targets (widgets and render objects) to consume events that should not
      be processed further. This is needed by the Switch component in the
      Drawer in the stocks example. The Switch is embedded in a DrawerItem.
      The Switch handles the gesture tap event to toggle its state and should
      handle pointer events to allow swiping and draw its own radial
      reaction. The DrawerItem also handles gesture taps to allow toggling
      the switch value when tapping anywhere on the drawer and to draw its
      own ink splash. When tapping on the switch, both the switch's render
      object and the DrawerItem's listener are in the event dispatch path.
      The Switch needs to signal in some fashion that it consumed the event
      so the DrawerItem does not also try to toggle the switch's state.
      53163f8b
  18. 03 Aug, 2015 4 commits
  19. 30 Jul, 2015 1 commit
  20. 28 Jul, 2015 2 commits
  21. 24 Jul, 2015 1 commit
  22. 23 Jul, 2015 1 commit
  23. 22 Jul, 2015 2 commits
    • Hans Muller's avatar
    • Hixie's avatar
      Introduce an explicit Key type. · 74575775
      Hixie authored
      This fixes some theoretical bugs whereby we were using hashCode to try
      to get unique keys for objects, but really we wanted object identity.
      It also lays the groundwork for a new GlobalKey concept.
      
      I tried to keep the impact on the code minimal, which is why the "Key"
      constructor is actually a factory that returns a StringKey. The code
      has this class hierarchy:
      
      ```
         KeyBase
          |
         Key--------------+---------------+
          |               |               |
         StringKey    ObjectKey       UniqueKey
      ```
      
      ...where the constructors are Key and Key.stringify (StringKey),
      Key.fromObjectIdentity (ObjectKey), and Key.unique (UniqueKey).
      
      We could instead of factory methods use regular constructors with the
      following hierarchy:
      
      ```
         KeyBase
          |
         LocalKey---------+---------------+
          |               |               |
         Key      ObjectIdentityKey   UniqueKey
      ```
      
      ...with constructors Key, Key.stringify, ObjectIdentityKey, and
      UniqueKey, but I felt that that was maybe a more confusing hierarchy.
      I don't have a strong opinion on this.
      74575775
  24. 21 Jul, 2015 2 commits
  25. 16 Jul, 2015 2 commits