2 * Ext JS Library 2.2.1
\r
3 * Copyright(c) 2006-2009, Ext JS, LLC.
\r
4 * licensing@extjs.com
\r
6 * http://extjs.com/license
\r
10 * @class Ext.menu.ColorMenu
\r
11 * @extends Ext.menu.Menu
\r
12 * A menu containing a {@link Ext.menu.ColorItem} component (which provides a basic color picker).
\r
14 * Creates a new ColorMenu
\r
15 * @param {Object} config Configuration options
\r
17 Ext.menu.ColorMenu = function(config){
\r
18 Ext.menu.ColorMenu.superclass.constructor.call(this, config);
\r
20 var ci = new Ext.menu.ColorItem(config);
\r
23 * The {@link Ext.ColorPalette} instance for this ColorMenu
\r
24 * @type ColorPalette
\r
26 this.palette = ci.palette;
\r
29 * @param {ColorPalette} palette
\r
30 * @param {String} color
\r
32 this.relayEvents(ci, ["select"]);
\r
34 Ext.extend(Ext.menu.ColorMenu, Ext.menu.Menu, {
\r
36 beforeDestroy: function(){
\r
37 this.palette.destroy();
\r