1. 02 Aug, 2014 38 commits
  2. 01 Aug, 2014 2 commits
    • huangs@chromium.org's avatar
      Local NTP: prevent tiles from reloading on resize by moving them into single <div>. · 80cfc6cf
      huangs@chromium.org authored
      Tiles in chrome-search://local-ntp/local-ntp.html used to be arranged in
      2 rows, and get reshuffled when screen resize causes number of columns
      to change. However, detaching and reattaching elements with <iframe>s
      cause the <iframe>s to reload, resulting in flickering.
      
      This CL places all tiles in a single <div>, so no reshuffling is needed.
      Instead, if number of columns change we resize the container width (and
      also hide tiles beyond row 2), and let HTML layout place handle the
      proper wrapping.
      
      On blacklisting, we cannot compare identities between old tiles and new,
      so a reload is necessary, which leads to some flickering.
      
      Also tested for <body dir="RTL">
      
      Additional cleanups:
      - To show all tiles only after everything is loaded: using a Barrier
        counter instead of looping on every load, which was O(n^2).
      - Broke apart onMostVisitedChange() and added more comments.
      - Removed unused CSS for fakebox and tiles resizing (JS does resizing now).
      - Using CSS visibility instead of hidden to show #mv-tiles, so it take
        up space and prevent content beneath tiles from jumping up briefly.
      - Refactoring the logic to hide tiles during load and show all at once when
        everything loads (or timeout occurs). Using new class Barrier to do this.
      
      BUG=399388
      
      Review URL: https://codereview.chromium.org/412073002
      
      git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287120 0039d316-1c4b-4281-b951-d872f2087c98
      80cfc6cf
    • rlarocque@chromium.org's avatar
      Refactor build target for sync · a579f97a
      rlarocque@chromium.org authored
      Refactors the sync build target definition to fit the more common
      pattern.  The old target was defined differently in component and
      non-component mode.  This is brittle compared to the more standard
      pattern of setting the target type to '<(component)'.
      
      Introduces a shim target with type 'none'.  Any target that depends on
      this shim will link inherit its dependency on the two sync libraries.
      
      A note on the history of this, for those who are interested:
      
      This pattern was recommended during the original componentization of
      sync almost two years ago.  The pattern was, and still is, used by
      content.gyp to ensure that dependency restrictions are being respected.
      
      The difference with sync is that it doesn't actually make use of
      fine-grained dependencies.  It's not unusual to see a target depend on
      conent_renderer, content_browser, or some other static library
      sub-component of content.  With sync, on the other hand, we have the
      rule that other targets may depend only on the top level sync target.
      
      Since no one aside from sync depends on sync_internal_api, sync_core, or
      sync_api static library targets, and we have no intention of exposing
      these sub-components outside of sync, there's no point in maintaining
      them as separate targets.
      
      BUG=397574
      
      Review URL: https://codereview.chromium.org/425803013
      
      git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287119 0039d316-1c4b-4281-b951-d872f2087c98
      a579f97a