This example demonstrates how to create a Menu Button whose menu displays a Calendar.
Begin by instantiating a Button of type "menu" and an Overlay instance that will house a Calendar instance.
Once the new Button is created, add a listener for its "click" event that will be used to render its Overlay instance as well as to create a new Calendar instance. (Defering the rendering of the Overlay until the firing of the "click" event improves the intial load time of the Button instance.)
Lastly, style the Button with a calendar icon.
Note: You are viewing this example in debug mode with logging enabled. This can significantly slow performance.
Copyright © 2007 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Copyright Policy - Job Openings