luke83
8 Nov 2006, 12:58 AM
ok in my page:
impellcment.net/chat
i have this function:
getRoom : function(id,rm){
if (getEl("room"+id)!=null){ // checking if just created the panel
// just created, let it show:
layout.getRegion('center').showPanel("room"+id)
}else{ // let create it and set the "activate" listner:
// creation code
[..]
// here an updater
[..]
rid=id; // this is a global var to set every time we are in a room :D
// so setting the activate function for the new panel
layout.getRegion('center').getPanel("room"+id).on("activate",App.setRoom(id),App,true);
}
}
the setRoom is simple function to set rid var:
setRoom : function(id){
rid=id;
alert(rid);
},
what is the problem?
when u click on the right link as "bar" or "piazza" it create the panel, insert it in the central region, change the rid and show u this rid.. so the set function is called.
But when u change panel and than return in the panel created nothing is show, rid is not setted and we have "s.fn has no proprieties" error :shock:
thx for time spent :roll:
impellcment.net/chat
i have this function:
getRoom : function(id,rm){
if (getEl("room"+id)!=null){ // checking if just created the panel
// just created, let it show:
layout.getRegion('center').showPanel("room"+id)
}else{ // let create it and set the "activate" listner:
// creation code
[..]
// here an updater
[..]
rid=id; // this is a global var to set every time we are in a room :D
// so setting the activate function for the new panel
layout.getRegion('center').getPanel("room"+id).on("activate",App.setRoom(id),App,true);
}
}
the setRoom is simple function to set rid var:
setRoom : function(id){
rid=id;
alert(rid);
},
what is the problem?
when u click on the right link as "bar" or "piazza" it create the panel, insert it in the central region, change the rid and show u this rid.. so the set function is called.
But when u change panel and than return in the panel created nothing is show, rid is not setted and we have "s.fn has no proprieties" error :shock:
thx for time spent :roll: