<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>EdwardH &#187; selectmenu</title>
	<atom:link href="http://edwardh.se/tag/selectmenu/feed/" rel="self" type="application/rss+xml" />
	<link>http://edwardh.se</link>
	<description>Reviews and such</description>
	<lastBuildDate>Tue, 19 Oct 2010 16:53:21 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Controlling jQuery UI Selectmenu</title>
		<link>http://edwardh.se/2010/02/09/controlling-jquery-ui-selectmenu/</link>
		<comments>http://edwardh.se/2010/02/09/controlling-jquery-ui-selectmenu/#comments</comments>
		<pubDate>Tue, 09 Feb 2010 01:30:33 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[jqueryui]]></category>
		<category><![CDATA[selectmenu]]></category>

		<guid isPermaLink="false">http://edwardh.se/?p=70</guid>
		<description><![CDATA[I&#8217;m just started using selectmenu and wanted to share how to control it. It&#8217;s not completely obvious to inexperienced jquery UI folks like myself&#8230; Specifying a trigger function First, we create the selectmenu UI widget from an existing &#60;select&#62; control, with the id=&#8221;selectmenu&#8221;. $("#selectmenu").selectmenu({ &#160;&#160;change: selectmenuChange }); And selectmenuChange&#8230; function selectmenuChange(event, value) { &#160;&#160;switch(value.value) &#160;&#160;{ [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m just started using <a href="http://www.filamentgroup.com/lab/jquery_ui_selectmenu_an_aria_accessible_plugin_for_styling_a_html_select/">selectmenu</a> and wanted to share how to control it. It&#8217;s not completely obvious to inexperienced jquery UI folks like myself&#8230;</p>
<h2>Specifying a trigger function</h2>
<p>First, we create the selectmenu UI widget from an existing &lt;select&gt; control, with the id=&#8221;selectmenu&#8221;.</p>
<p><code>$("#selectmenu").selectmenu({<br />
&nbsp;&nbsp;change: selectmenuChange<br />
});</code></p>
<p>And selectmenuChange&#8230;<br />
<code>function selectmenuChange(event, value)<br />
{<br />
&nbsp;&nbsp;switch(value.value)<br />
&nbsp;&nbsp;{<br />
&nbsp;&nbsp;&nbsp;&nbsp;case 0:<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;alert('Hello!');<br />
&nbsp;&nbsp;&nbsp;&nbsp;break;<br />
&nbsp;&nbsp;}<br />
&nbsp;&nbsp;$("#selectmenu").selectmenu("value", "ignore");	// Put it back on the first option.<br />
}</code></p>
<p>The last line should give you a clue as to what comes next.</p>
<p>Controlling the selectmenu after creation</p>
<p><code>$("#selectmenu").selectmenu("value", "ignore");	// Put it back on the  first option.<br />
$("#selectmenu").selectmenu("open"); // Open the selectmenu<br />
$("#selectmenu").selectmenu("focus");	// Give it focus</code></p>
]]></content:encoded>
			<wfw:commentRss>http://edwardh.se/2010/02/09/controlling-jquery-ui-selectmenu/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

