-<!DOCTYPE html><html><head><title>Sencha Documentation Project</title><link rel="stylesheet" href="../reset.css" type="text/css"><link rel="stylesheet" href="../prettify.css" type="text/css"><link rel="stylesheet" href="../prettify_sa.css" type="text/css"><script type="text/javascript" src="../prettify.js"></script></head><body onload="prettyPrint()"><pre class="prettyprint"><pre><span id='Ext-form.field.Picker-method-constructor'><span id='Ext-form.field.Picker'>/**
+<!DOCTYPE html>
+<html>
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>The source code</title>
+ <link href="../prettify/prettify.css" type="text/css" rel="stylesheet" />
+ <script type="text/javascript" src="../prettify/prettify.js"></script>
+ <style type="text/css">
+ .highlight { display: block; background-color: #ddd; }
+ </style>
+ <script type="text/javascript">
+ function highlight() {
+ document.getElementById(location.hash.replace(/#/, "")).className = "highlight";
+ }
+ </script>
+</head>
+<body onload="prettyPrint(); highlight();">
+ <pre class="prettyprint lang-js"><span id='Ext-form-field-Picker-method-constructor'><span id='Ext-form-field-Picker'>/**
</span></span> * @class Ext.form.field.Picker
* @extends Ext.form.field.Trigger
* <p>An abstract class for fields that have a single trigger which opens a "picker" popup below
alternateClassName: 'Ext.form.Picker',
requires: ['Ext.util.KeyNav'],
-<span id='Ext-form.field.Picker-cfg-matchFieldWidth'> /**
+<span id='Ext-form-field-Picker-cfg-matchFieldWidth'> /**
</span> * @cfg {Boolean} matchFieldWidth
* Whether the picker dropdown's width should be explicitly set to match the width of the field.
* Defaults to <tt>true</tt>.
*/
matchFieldWidth: true,
-<span id='Ext-form.field.Picker-cfg-pickerAlign'> /**
+<span id='Ext-form-field-Picker-cfg-pickerAlign'> /**
</span> * @cfg {String} pickerAlign
* The {@link Ext.core.Element#alignTo alignment position} with which to align the picker. Defaults
* to <tt>"tl-bl?"</tt>
*/
pickerAlign: 'tl-bl?',
-<span id='Ext-form.field.Picker-cfg-pickerOffset'> /**
+<span id='Ext-form-field-Picker-cfg-pickerOffset'> /**
</span> * @cfg {Array} pickerOffset
* An offset [x,y] to use in addition to the {@link #pickerAlign} when positioning the picker.
* Defaults to undefined.
*/
-<span id='Ext-form.field.Picker-cfg-openCls'> /**
+<span id='Ext-form-field-Picker-cfg-openCls'> /**
</span> * @cfg {String} openCls
* A class to be added to the field's {@link #bodyEl} element when the picker is opened. Defaults
* to 'x-pickerfield-open'.
*/
openCls: Ext.baseCSSPrefix + 'pickerfield-open',
-<span id='Ext-form.field.Picker-property-isExpanded'> /**
+<span id='Ext-form-field-Picker-property-isExpanded'> /**
</span> * @property isExpanded
* @type Boolean
* True if the picker is currently expanded, false if not.
*/
-<span id='Ext-form.field.Picker-cfg-editable'> /**
+<span id='Ext-form-field-Picker-cfg-editable'> /**
</span> * @cfg {Boolean} editable <tt>false</tt> to prevent the user from typing text directly into the field;
* the field can only have its value set via selecting a value from the picker. In this state, the picker
* can also be opened by clicking directly on the input field itself.
// Custom events
this.addEvents(
-<span id='Ext-form.field.Picker-event-expand'> /**
+<span id='Ext-form-field-Picker-event-expand'> /**
</span> * @event expand
* Fires when the field's picker is expanded.
* @param {Ext.form.field.Picker} field This field instance
*/
'expand',
-<span id='Ext-form.field.Picker-event-collapse'> /**
+<span id='Ext-form-field-Picker-event-collapse'> /**
</span> * @event collapse
* Fires when the field's picker is collapsed.
* @param {Ext.form.field.Picker} field This field instance
*/
'collapse',
-<span id='Ext-form.field.Picker-event-select'> /**
+<span id='Ext-form-field-Picker-event-select'> /**
</span> * @event select
* Fires when a value is selected via the picker.
* @param {Ext.form.field.Picker} field This field instance
},
-<span id='Ext-form.field.Picker-method-expand'> /**
+<span id='Ext-form-field-Picker-method-expand'> /**
</span> * Expand this field's picker dropdown.
*/
expand: function() {
mousedown: collapseIf,
scope: me
});
-
+ Ext.EventManager.onWindowResize(me.alignPicker, me);
me.fireEvent('expand', me);
me.onExpand();
}
onExpand: Ext.emptyFn,
-<span id='Ext-form.field.Picker-method-alignPicker'> /**
+<span id='Ext-form-field-Picker-method-alignPicker'> /**
</span> * @protected
* Aligns the picker to the
*/
}
},
-<span id='Ext-form.field.Picker-method-collapse'> /**
+<span id='Ext-form-field-Picker-method-collapse'> /**
</span> * Collapse this field's picker dropdown.
*/
collapse: function() {
// remove event listeners
doc.un('mousewheel', collapseIf, me);
doc.un('mousedown', collapseIf, me);
-
+ Ext.EventManager.removeResizeListener(me.alignPicker, me);
me.fireEvent('collapse', me);
me.onCollapse();
}
onCollapse: Ext.emptyFn,
-<span id='Ext-form.field.Picker-method-collapseIf'> /**
+<span id='Ext-form-field-Picker-method-collapseIf'> /**
</span> * @private
* Runs on mousewheel and mousedown of doc to check to see if we should collapse the picker
*/
}
},
-<span id='Ext-form.field.Picker-method-getPicker'> /**
+<span id='Ext-form-field-Picker-method-getPicker'> /**
</span> * Return a reference to the picker component for this field, creating it if necessary by
* calling {@link #createPicker}.
* @return {Ext.Component} The picker component
return me.picker || (me.picker = me.createPicker());
},
-<span id='Ext-form.field.Picker-property-createPicker'> /**
+<span id='Ext-form-field-Picker-property-createPicker'> /**
</span> * Create and return the component to be used as this field's picker. Must be implemented
* by subclasses of Picker.
* @return {Ext.Component} The picker component
*/
createPicker: Ext.emptyFn,
-<span id='Ext-form.field.Picker-method-onTriggerClick'> /**
+<span id='Ext-form-field-Picker-method-onTriggerClick'> /**
</span> * Handles the trigger click; by default toggles between expanding and collapsing the
* picker component.
*/
onDestroy : function(){
var me = this;
+ Ext.EventManager.removeResizeListener(me.alignPicker, me);
Ext.destroy(me.picker, me.keyNav);
me.callParent();
}
});
-</pre></pre></body></html>
\ No newline at end of file
+</pre>
+</body>
+</html>