Refactor ordering of NavigationListModel items
Replace the logic in NavigationListModel.prototype.item and NavigationListModel.prototype.length_ to instead calculate the order and preserve it in an array in reorderNavigationItems_. This makes the ordering rules clearer and should also give faster performance for the more frequently accessed item function. Update tests to include recent. This change in done in advance of adding crostini Linux Files. Bug: 834103 Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation Change-Id: I08c3222b4317b0d38524c52e320545d6717ef9b0 Reviewed-on: https://chromium-review.googlesource.com/1039207 Commit-Queue: Joel Hockey <joelhockey@chromium.org> Reviewed-by:Sasha Morrissey <sashab@chromium.org> Cr-Commit-Position: refs/heads/master@{#555649}
Showing
Please register or sign in to comment