Log in

View Full Version : Disable onclick for list items?

April 28th, 2010, 01:39 AM
Hello again. I use a list to do alot of menus (since it can retain a highlighted item when not in focus, useful for many purposes). However, these seems to require an onclick handler in each item in the static content, or it won't show any content at all. However, I don't use them for clicking, so I disable them by installing a null Python handler:

<item id="400">
<onclick lang="python"><![CDATA[]]></onclick>
<item id="401">
<onclick lang="python"><![CDATA[]]></onclick>
If I just use a hyphen it seems to default to showing some sort of playback menu/dialog. Is there some explicit action to tell it to do nothing short of the above Python hack? Perhaps I should do away with the list control alltogether for these purposes?

April 28th, 2010, 06:57 AM
What are you using this list for?

May 2nd, 2010, 10:36 PM
Toggle buttons can have alternate focus states, as well as alternate labels, onclick. No need to use a list.