View Full Version : Ext.Picker does not fire "pick" on click

10 Mar 2011, 10:52 AM
If an item is selected by a mouse drag the pick-event is fired, if it is chosen by a click no event is fired.

I use the following code as a workaround:

Ext.override(Ext.Picker.Slot, {
setSelectedNode: function(selected, animate) {
// If it is a number, we assume we are dealing with an index
if (Ext.isNumber(selected)) {
selected = this.getNode(selected);
else if (selected.isModel) {
selected = this.getNode(this.store.indexOf(selected));

// If its not a model or a number, we assume its a node
if (selected) {
this.selectedNode = selected;
this.selectedIndex = this.indexOf(selected);
this.scrollToNode(selected, animate);
this.fireEvent('slotpick', this, this.getValue(), this.selectedNode);

(I just added the last line of the method)

20 Mar 2011, 11:05 AM
I'm having trouble getting the selected value when the user clicks the 'done' button, can anyone help me out?

28 Mar 2011, 2:32 AM
what kind of troubles ?
with what kind of picker ?

@NetNexus : thanks for the fix