1. 28 Sep, 2015 2 commits
    • Hixie's avatar
      Make the checkbox in the stocks popup menu work. · 066768f0
      Hixie authored
      Tapping on the menu item didn't animate the checkbox because the menu
      takes 300ms to animate entirely away while the checkbox takes 200ms to
      animate checked, and since the item with the checkbox was at the bottom,
      we were only seeing about 60ms of the entire checkbox animation, which
      isn't enough to notice it. So I moved it to the top of the menu.
      
      Tapping on the checkbox didn't animate because nothing caused the menu
      to rebuild when the callback was invoked. To trigger a rebuild, I now
      call navigator.setState() explicitly, after changing out local state.
      
      To make tapping the checkbox remove the menu, I also explicitly call
      navigator.pop() in the code that handles the check. (I still explicitly
      change the checkbox to show that that's possible. In principle one could
      just treat the checkbox as an inert widget that happens to trigger pop,
      and do all the checking/unchecking in the switch statement.)
      
      I also made some minor style tweaks to files I was looking at while
      dealing with this issue.
      066768f0
    • Adam Barth's avatar
      Actually notify GlobalKey listeners in fn3 · 64dfb849
      Adam Barth authored
      This patch makes a number of changes:
      
      1) buildDirtyComponents now prevents all calls to setState, not just those
         higher in the tree. This change is necessary for consistency with
         MixedViewport and HomogeneousViewport because those widgets already build
         subwidgets with that restriction. If the "normal" build didn't enforce that
         rule, then some widgets would break when put inside a mixed or homogeneous
         viewport.
      
      2) We now notify global key listeners in a microtask after beginFrame. That
         means setState is legal in these callbacks and that we'll produce another
         frame if someone calls setState in such a callback.
      64dfb849
  2. 27 Sep, 2015 2 commits
  3. 26 Sep, 2015 9 commits
  4. 25 Sep, 2015 27 commits