Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Unified Diff: chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js

Issue 2278723006: [Media Router WebUI] Use updated sink on click (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js
diff --git a/chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js b/chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js
index 0011fc3296b9839d0efc081ce123b5074123c2c1..0cdb780b04ea1530d6243d07b1c7041ce3fef336 100644
--- a/chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js
+++ b/chrome/browser/resources/media_router/elements/media_router_container/media_router_container.js
@@ -2010,8 +2010,10 @@ Polymer({
// Remove any sinks that are no longer discovered.
this.sinksToShow_.splice(i, 1);
} else {
- // If the sink exists, remove it from |updatedSinkList| as it is
- // already in |sinksToShow_|.
+ // If the sink exists, move it from |updatedSinkList| to
+ // |sinksToShow_| in the same position, as the cast modes or other
+ // fields may have been updated.
+ this.sinksToShow_[i] = updatedSinkList[index];
updatedSinkList.splice(index, 1);
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698