D28936: Use a Proxy object to detect changes within the MediaMetadata
Fabian Vogt
noreply at phabricator.kde.org
Fri Apr 24 14:43:34 BST 2020
fvogt added a comment.
AFAICT (take with a grain of salt, I'm a JS n00b) this doesn't catch something like this:
let a = {};
navigator.mediaSession.metadata = a;
a["foo"] = "bar";
And behaves weirdly if you do:
let a = navigator.mediaSession.metadata;
navigator.mediaSession.metadata = null;
a["foo"] = "bar";
INLINE COMMENTS
> content-script.js:716
> + if (this.metadata) {
> + // MediaMetadata is not a regular Object so we cannot just JSON.stringify it
> + keys = Object.getOwnPropertyNames(Object.getPrototypeOf(this.metadata));
That appears to work fine here
REPOSITORY
R856 Plasma Browser Integration
REVISION DETAIL
https://phabricator.kde.org/D28936
To: broulik, #plasma, fvogt, ognarb, cblack
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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20200424/bd51cd56/attachment-0001.html>
More information about the Plasma-devel
mailing list