View Full Version : [RESOLVED] List Class,how to give a Title?
grubby69
8 Sep 2011, 12:19 AM
Hi,
I am really new to Touch and I am try to test some example and do some training.
I have a problem that I cannot understand: How can I give a TITLE to my List object?
I have try but the title isn't rendered...
I haven't seen a title config property in the Api doc,so I have this question...
Could someone give me some idea?!?
Thanks a lot
8-|
grubby69
8 Sep 2011, 3:01 AM
Sorry....:">
I am really new at Touch and I have resolved my problem using a Panel and adding a 3 Dockitems ,one toolbar at top with TITLE and one at bottom with buttons,and the list in the middle so it can slide under the panel when pulled.
Solved.
mitchellsimoens
8 Sep 2011, 5:33 AM
That's the way to do it. Just one question, you say you added 3 dockedItems... did you mean you added 2 dockedItems (toolbars) and then the List as an item of the Panel?
grubby69
8 Sep 2011, 7:35 AM
Hi!!!:)
I have done in this way :
var panel = new Ext.Panel({
fullscreen: true,
dockedItems: [
{
dock : 'top',
xtype: 'toolbar',
title: 'ToDOList'
},
{
dock : 'left',
xtype: 'list',
id: 'listId',
/*listeners: {
el: {
//tap: myHandler2,
doubletap: myHandler1,
delegate: 'div'
}
},*/
itemTpl : mytemplate,
store: store
},
{
dock : 'bottom',
xtype: 'toolbar',
id: 'bottomtbId',
ui : 'light',
items: [
{
text: 'Nuovo'
},
{
text: 'Aggiungi',
id: 'addbtnId',
hidden: true
},
{
text: 'Modifica',
id: 'modbtnId',
hidden: true
},
{
text: 'Cancella',
id: 'canbtnId',
hidden: true
}
]
}
],
});
I think there are other ways but I am trying this for now...
Bye
mitchellsimoens
8 Sep 2011, 7:42 AM
I suggest this:
var panel = new Ext.Panel({
fullscreen : true,
layout : 'fit',
items : [
{
xtype : 'list',
itemTpl : mytemplate,
store : store
}
],
dockedItems : [
{
dock : 'top',
xtype : 'toolbar',
title : 'ToDOList'
},
{
dock : 'bottom',
xtype : 'toolbar',
ui : 'light',
items : [
{
text : 'Nuovo'
},
{
text : 'Aggiungi',
hidden : true
},
{
text : 'Modifica',
hidden : true
},
{
text : 'Cancella',
hidden : true
}
]
}
]
});
grubby69
9 Sep 2011, 1:35 AM
Yes!!!
this is the right way!!!=D>
Now the List appears on all the phone display and not only on a part!
thank you very much mitchellsimoens!!!B)
mitchellsimoens
9 Sep 2011, 4:43 AM
Yes!!!
this is the right way!!!=D>
Now the List appears on all the phone display and not only on a part!
thank you very much mitchellsimoens!!!B)
No problem :)
Powered by vBulletin® Version 4.1.5 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.