<table><tr><td style="">broulik created this revision.<br />broulik added reviewers: Plasma, fvogt.<br />Herald added a project: Plasma.<br />Herald added a subscriber: plasma-devel.<br />broulik requested review of this revision.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D28936">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>According to spec [1] it is allowed to change properties within the <tt style="background: #ebebeb; font-size: 13px;">MediaMetadata</tt> rather than assigning a new instance.<br />
Using a <tt style="background: #ebebeb; font-size: 13px;">Proxy</tt> object lets us detect property assignments within the object. Conveniently, it still reports <tt style="background: #ebebeb; font-size: 13px;">instanceof</tt> as being the original object.</p>
<p>[1] <a href="https://www.w3.org/TR/mediasession/#the-mediametadata-interface" class="remarkup-link" target="_blank" rel="noreferrer">https://www.w3.org/TR/mediasession/#the-mediametadata-interface</a> (last sentence)</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>This fixes VKontakte player not updating metadata when changing tracks. Thanks <a href="https://phabricator.kde.org/p/IlyaBizyaev/" style="
border-color: #f1f7ff;
color: #19558d;
background-color: #f1f7ff;
border: 1px solid transparent;
border-radius: 3px;
font-weight: bold;
padding: 0 4px;">@IlyaBizyaev</a> for investigating.</p>
<p>YouTube, vimeo, media session example (who all set new metadata instance when they change) still get their metadata propagated correctly</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R856 Plasma Browser Integration</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D28936">https://phabricator.kde.org/D28936</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>extension/content-script.js</div></div></div><br /><div><strong>To: </strong>broulik, Plasma, fvogt<br /><strong>Cc: </strong>IlyaBizyaev, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev, cblack, jraleigh, zachus, fbampaloukas, ragreen, ZrenBot, ngraham, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, ahiemstra, mart<br /></div>