1. 16 Oct, 2018 1 commit
  2. 14 Sep, 2018 1 commit
  3. 12 Sep, 2018 1 commit
  4. 15 Aug, 2018 1 commit
  5. 31 Jul, 2018 1 commit
  6. 13 Jun, 2018 1 commit
    • Chris Bracken's avatar
      Revert elimination of Dart 1 (#18460) · 2ae48845
      Chris Bracken authored
      fuchsia_tester.dart still assumes Dart 1. Previously, it ran tests directly
      from source, flutter_platform.dart automatically runs a kernel compile when
      operating in Dart 2 mode, but this assumes a functional Dart SDK is available
      in the artifacts directly, and fuchsia_tester.dart mocks out the artifacts
      directory with an empty temp dir.
      
      Remaining work is:
      1. Get the frontend server building as a dependency on Fuchsia.
      2. Patch fuchsia_tester.dart to use a valid Dart SDK and frontend server.
      
      This also reverts migration to Dart 2 typedef syntax.
      
      This reverts commit 6c56bb24. (#18362)
      This reverts commit 3daebd05. (#18316)
      2ae48845
  7. 11 Jun, 2018 1 commit
    • Greg Spencer's avatar
      Update typedef syntax to use Function notation and turn on lint for old notation. (#18362) · 6c56bb24
      Greg Spencer authored
      Now that Dart 1 is turned off, reapplying my change to turn on the prefer_generic_function_type_aliases analysis option, and fix all the typedefs to Dart 2 preferred syntax.
      
      Also eliminated the unused analysis_options_repo.yaml file and turned on public_member_api_docs in analysys_options.yaml.
      
      No logic changes, just changing the typedef syntax for all typedefs, and updating analysis options.
      6c56bb24
  8. 05 Jun, 2018 1 commit
  9. 30 May, 2018 2 commits
  10. 24 Jan, 2018 1 commit
  11. 10 Jan, 2018 1 commit
    • Ian Hickson's avatar
      Make DecoratedBox repaint after being reparented (#13927) · 316d8e1c
      Ian Hickson authored
      Fixes https://github.com/flutter/flutter/issues/12553
      
      The root cause of https://github.com/flutter/flutter/issues/12553 was that when the refresh indicator went away, which happened after the avatars had started their image loads but before the avatars had loaded, the DecoratedBoxes, along with the rest of the list, got GlobalKey-reparented, which caused the RenderDecoratedBox objects to unregister from the DecorationImagePainters, but they never re-registered since the whole subtree was in a RepaintBoundary and was therefore not explicitly repainted when the tree got reattached.
      
      This fixes the bug by explicitly requiring any RenderDecoratedBox to repaint when it's reattached. This is probably a little more aggressive than required; we could probably expose a flag on Decoration that says whether or not the onChanged handler will ever be invoked, and only call markNeedsPaint if that's true, but we'll do that if it turns out that there's a performance issue here.
      
      (This patch also introduces a bunch of improved debugging information that I used to track down the bug.)
      316d8e1c
  12. 07 Dec, 2017 1 commit
    • Ian Hickson's avatar
      Move image logic from services/ to painting/. (#13409) · 44e228eb
      Ian Hickson authored
      This allows the scheduler library to depend on the services library
      and the painting library to depend on the scheduler library without
      the services library having to depend on the scheduler library.
      
      While I was at it I also cleaned up some of the binding logic: the
      licenses logic can now be overridden (and the test library does so),
      and the image cache can now be overridden as well.
      44e228eb
  13. 22 Nov, 2017 1 commit
    • amirh's avatar
      Cancel the animated image stream timer if all listeners were removed. (#13158) · 78e044f5
      amirh authored
      This is a bug in my previous CL: instead of cancelling the timer if
      there are no more listeners, I canceled it if there were listeners (I
      can claim I just missed a not :) ).
      
      Not cancelling the timer when removing the last listener was not that bad, as
      the timer callback is guarded by a check to see if there are listeners.
      So the animation will not continue.
      
      But in the case there were multiple listeners on the same stream, and
      one of them is removed, this bug will stop the animation for all other
      listeners.
      I added a test case for this scenario.
      78e044f5
  14. 17 Nov, 2017 2 commits
  15. 16 Nov, 2017 2 commits
  16. 10 Nov, 2017 1 commit
  17. 28 Sep, 2017 1 commit
  18. 12 Sep, 2017 1 commit
  19. 03 Aug, 2017 1 commit
  20. 28 Jul, 2017 1 commit
  21. 23 Jun, 2017 1 commit
  22. 06 Jun, 2017 1 commit
  23. 05 Jun, 2017 1 commit
  24. 10 May, 2017 1 commit
  25. 06 May, 2017 1 commit
  26. 05 May, 2017 1 commit
  27. 19 Apr, 2017 1 commit
  28. 31 Mar, 2017 1 commit
  29. 04 Mar, 2017 1 commit
  30. 23 Jan, 2017 1 commit
  31. 19 Nov, 2016 1 commit
  32. 02 Aug, 2016 1 commit
  33. 28 Jul, 2016 1 commit
  34. 01 Jul, 2016 1 commit
    • Adam Barth's avatar
      Update use of `@protected` (#4805) · 8c535ad7
      Adam Barth authored
      Now that protected can be accessed from inside the same library, we can
      use protected in a number of new places and we can remove some
      trampolines we were using to work around its previous semantics.
      8c535ad7
  35. 16 Jun, 2016 1 commit
    • Ian Hickson's avatar
      Refactor everything to do with images (#4583) · 2dfdc840
      Ian Hickson authored
      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
      2dfdc840