Opened 14 years ago
Closed 10 years ago
#4714 closed feature (wontfix)
Themeswitcher: onSelect behavior
Reported by: | pwnedd | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.10.0 |
Component: | [meta] ui.themeroller | Version: | 1.7.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Would it be possible to:
- Have onSelect provide the name of the theme that was selected? It is not hard to find (e.g. $(".jquery-ui-themeswitcher-trigger > .jquery-ui-themeswitcher-title").text()), but it would be useful to simply pass to the event-handler.
- Prevent onSelect from firing during initialization?
Thanks, Keith
Change History (5)
comment:1 Changed 13 years ago by
Milestone: | TBD → 1.next |
---|
comment:2 Changed 12 years ago by
comment:3 Changed 11 years ago by
Type: | enhancement → feature |
---|
comment:4 Changed 10 years ago by
Milestone: | 1.next → 1.10.0 |
---|
comment:5 Changed 10 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
We're no longer supporting ThemeSwitcher. Please use Dave Hoff's Super Theme Switcher.
Note: See
TracTickets for help on using
tickets.
Not sure about point 1, but if I understand correctly point 2 it's an issue I've been thinking about lately. When setting the "onSelect" callback in the widget options, I noticed that it was getting triggered on every page load after having selected a theme. I believe that the expected behaviour is to trigger only after the actual select from the widget, and not on every successive theme load (such as on page load).
I found the cause, it was because when the theme is loaded either from the cookie or from the "loadTheme" option, a click is triggered on the widget, causing the onselect event to trigger also. So I deleted the click trigger and modified it so as not to trigger the onselect event. Here is my test case on jsbin:
http://jsbin.com/ehoja3/9 ( = original themeswitcher widget code)
versus
http://jsbin.com/ehoja3/8 (my code)
Is the themeswitcher widget to be found on the repository on GitHub? If so I can push a fix, but after looking over the repository I could not find the themeswitcher widget code.