WardCunningham/Smallest-Federated-Wiki — pull request #74 by asolove (2012-01-04 02:41:43+00:00)
Title: Bytebeat bugfix and cleanup

As a way of gently easing back into the project, I spent some time with the bytebeat plugin and really enjoyed playing with it. The two commits here fix two small problems I had:

1. I had a problem with both bytebeat and mathjax instances created by clicking on a link in the factory plugin. After creating them with initial content, the appropriate bytebeat or mathjax behavior was displayed, but when I double-clicked to edit them and then clicked away, they had turned into paragraphs. It turned out that some events on the factory element weren't being removed in some cases. I have manually unbound them. I suspect the syncEditAction function also ought to be called here to keep these cases parallel with drag-and-drop and other plugins, but had trouble making that work.

2. The bytebeat plugin was written so that only one audio clip can be playing at the same time. I've moved the code around a bit so that each instance of the plugin has its own audio tag and can play and pause independently. I had a bit of fun setting up small orchestras of different formulas and starting them at different times. I also moved some styling that was in the plugin code to instead be in the css.