PDA

View Full Version : [CLOSED]selectedClass in ListView stays active



af_cp
26 May 2010, 12:00 AM
Hi.
I defined a customized class to highlight selected items in a ListView (Ext.list.ListView) using the selectedClass property. That worked fine in Ext 3.0 but since we updated to Ext 3.2.1 the class gets activated (added) when an item gets selected but stays active when deselected.

Shouldn't it get removed when the item gets deselected ?

evant
26 May 2010, 12:24 AM
Works fine for me. Please post a test case.

af_cp
26 May 2010, 12:35 AM
Here are the pieces of codes I am using:

var statusStore = new Ext.data.ArrayStore({
fields: ['status', 'name'],
data: [["charged","Gebucht"],["declined","Abgelehnt"],["chargeback","Storno"],["refunded","R\u00fcckbuchung"]]
});

<...>

xtype: 'container',
layout: 'hbox',
fieldLabel: 'Status',
style: 'overflow: auto;',
items: [{
xtype: 'fieldset',
height: 80,
width: 210,
style: 'padding: 0;',
bodyStyle: 'overflow: auto;',
items: [{
xtype: 'listview',
hiddenName: 'find_status',
columns: [{
dataIndex: 'name',
header: ''
}],
hideHeaders: true,
width: 190,
cls: '',
selectedClass: 'x-list-selected bg-multiple-list-selected',
readOnly: false,
multiSelect: true,
simpleSelect: true,
store: statusStore
}]
}]

<...>


(used StyleSheet: )

.bg-multiple-list-selected dt em {
font-weight: bold;
}

evant
26 May 2010, 12:43 AM
It only expects a single class, not multiple space separated.

af_cp
26 May 2010, 12:43 AM
Thanks