athena: Maintain the list of windows in window-list provider.
commit5db51cce7b370e2e9d9f14cbd2cc9ea1e968948a
authorSadrul Habib Chowdhury <sadrul@chromium.org>
Thu, 18 Sep 2014 02:02:07 +0000 (17 22:02 -0400)
committerSadrul Habib Chowdhury <sadrul@chromium.org>
Thu, 18 Sep 2014 02:03:23 +0000 (18 02:03 +0000)
tree7c8170bf405d8b6c7fbf2cafb7d4d25304e2271c
parent578bfd32228aa9c3c797bc7114331785739266fb
athena: Maintain the list of windows in window-list provider.

We currently recreate the list of all windows for each call to the
WindowListProvider::GetWindowList(). This introduced unnecessary cost
since we get this list of windows pretty frequently at times (e.g. for
each scroll when in overview mode, several times when going into
overview mode, etc.) especially if there is a large number of windows.
So, instead of this, maintain a list of windows in the WindowListProvider
implementation, and update it when needed, as new windows are added or
windows are removed.

BUG=413928
R=oshima@chromium.org

Review URL: https://codereview.chromium.org/577533002

Cr-Commit-Position: refs/heads/master@{#295395}
12 files changed:
athena/content/app_activity_registry.cc
athena/resource_manager/resource_manager_impl.cc
athena/wm/public/window_list_provider.h
athena/wm/public/window_list_provider_observer.h
athena/wm/split_view_controller.cc
athena/wm/split_view_controller_unittest.cc
athena/wm/window_list_provider_impl.cc
athena/wm/window_list_provider_impl.h
athena/wm/window_list_provider_impl_unittest.cc
athena/wm/window_manager_impl.cc
athena/wm/window_overview_mode.cc
athena/wm/window_overview_mode.h