[Chromecast] Fix window ordering
The curent implementation tries to order one window in a list of potentially unordered windows. The window list is not always ordered since we never order hidden windows. Use stable_sort to order all windows by ID. Between windows with the same ID, promote the window currently becoming visible. BUG=NONE TEST=Verified on device and wrote unittests to cover window ordering. Change-Id: I52a760a6fbb84752a523c89ba39963f443ab4712 Reviewed-on: https://chromium-review.googlesource.com/1103296Reviewed-by:Luke Halliwell <halliwell@chromium.org> Commit-Queue: Daniel Nicoara <dnicoara@chromium.org> Cr-Commit-Position: refs/heads/master@{#567989}
Showing
Please register or sign in to comment