lloeki / matterfront

Mattermost frontend app for OS X, Windows and Linux
MIT License
152 stars 27 forks source link

Rewrite the badge notification without a timer #18

Closed daemongh closed 8 years ago

daemongh commented 8 years ago

To avoid using a timer, the preloaded JS will now be hooking into the DOMSubtreeModified event.

Also added some comments, cleaned up some of the code and made it so the notifications should only be sent if there is a change in the count.

lloeki commented 8 years ago

That sounds great, thanks! I'll review this ASAP.

daemongh commented 8 years ago

Okay, it's now using the MutationObserver.

lloeki commented 8 years ago

Awesome. Merging.