taitems/UX-Lab — pull request #1 by romanbsd (2012-11-16 22:04:36+00:00)
Title: Fix several bugs

1. Return the collection to make it possible to chain method calls
2. Remove the "selected" attribute on the other option
3. Trigger the "change" event on the original select

There's still one outstanding issue which I wasn't able to solve, and that's the "change" event when it's specified in the options for toggleSwitch(). In this case, the initial move of the toggle to the selected value also triggers this event, which is IMHO wrong. I just want to know when it's changed later on, not when it's getting to the initial state.