MD Extensions: add ViewManager to handle view transitions

Desktop / Chromium - Scott Chen [chromium.org] - 9 August 2017 02:07 EDT

The transition between views (or "pages") is currently done in neon-animated-pages, but neon-animated-pages is now deprecated, and also comes with a lot of other utilities that we don't use. This CL creates a ViewManager that replaces neon-animated-pages in handling transition animations.

Only fade-in/out animation will be supported right away (UX approved). But adding other animations will be easy by adding to the viewAnimations map.

Bug: 751865 Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation Change-Id: I7edd37c441ad9d7de86458a48397a6f8699c7b0c Reviewed-on: https://chromium-review.googlesource.com/600835

52d7ff2 MD Extensions: add ViewManager to handle view transitions.
chrome/browser/browser_resources.grd | 4 +-
.../resources/md_extensions/animation_helper.html | 9 --
.../resources/md_extensions/animation_helper.js | 96 -----------------
.../md_extensions/compiled_resources2.gyp | 27 ++---
.../resources/md_extensions/detail_view.html | 2 -
.../browser/resources/md_extensions/detail_view.js | 8 +-
.../resources/md_extensions/error_page.html | 2 -
.../browser/resources/md_extensions/error_page.js | 10 --
.../browser/resources/md_extensions/item_list.html | 2 -
.../browser/resources/md_extensions/item_list.js | 23 ++---
.../md_extensions/keyboard_shortcuts.html | 2 -
.../resources/md_extensions/keyboard_shortcuts.js | 10 --
.../browser/resources/md_extensions/manager.html | 37 ++-----
chrome/browser/resources/md_extensions/manager.js | 47 +++------
.../browser/resources/md_extensions/toolbar.html | 1 +
.../resources/md_extensions/view_manager.html | 26 +++++
.../resources/md_extensions/view_manager.js | 113 +++++++++++++++++++++
.../browser/ui/webui/extensions/extensions_ui.cc | 7 +-
.../webui/extensions/cr_extensions_browsertest.js | 25 +++++
.../webui/extensions/extension_manager_test.js | 19 ++--
.../extensions/extension_view_manager_test.js | 107 +++++++++++++++++++
21 files changed, 331 insertions(+), 246 deletions(-)

Upstream: git.chromium.org


  • Share