broulik created this revision.
broulik added reviewers: Plasma, fvogt.
Herald added a project: Plasma.
Herald added a subscriber: plasma-devel.
broulik requested review of this revision.

REVISION SUMMARY
  According to spec [1] it is allowed to change properties within the 
`MediaMetadata` rather than assigning a new instance.
  Using a `Proxy` object lets us detect property assignments within the object. 
Conveniently, it still reports `instanceof` as being the original object.
  
  [1] https://www.w3.org/TR/mediasession/#the-mediametadata-interface (last 
sentence)

TEST PLAN
  This fixes VKontakte player not updating metadata when changing tracks. 
Thanks @IlyaBizyaev for investigating.
  
  YouTube, vimeo, media session example (who all set new metadata instance when 
they change) still get their metadata propagated correctly

REPOSITORY
  R856 Plasma Browser Integration

REVISION DETAIL
  https://phabricator.kde.org/D28936

AFFECTED FILES
  extension/content-script.js

To: broulik, #plasma, fvogt
Cc: 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

Reply via email to