[Dojo-interest] Processing events in a Dialog window
dele454
dele at killerinstinct.co.za
Sat Jul 18 13:30:15 EDT 2009
http://www.nabble.com/file/p24550071/1.gif
I have a two dialog windows that gets shown depending on the radio button
selected after the 'Choose' button is pressed.
Now i need to track/process events that occur WITHIN the Dialog window. What
i want to do is process the 'onclick' event on each of those image texture
thumbnails. I have given the anchors tags for those image thumbs sequential
IDs e.g
http://www.nabble.com/file/p24550071/2.gif
I want to switch the CSS class rule attached to the avatar in response to
the thumbnail clicked to reflect how the avatar will look with the border
texture. And after clicking the 'OK' Button the class rule name is saved to
the db and attached to the avatar for the member.
The problem is I can't trap the onlick event on those image thumbs. it just
reloads the page again. Any idea how i can achieve this. I have the 'ok'
button attached to a listener and it is responding just the thumbs.
help will be appreciated thanks :)
Some code on how the Dialog window is been rendered:
[code]
dojo.query("a[id=choose]") . connect('onclick',function(evt){
evt.preventDefault();
var solid = dojo.byId("solid").checked;
var texture = dojo.byId("texture").checked;
if(solid == "1" && texture == "0"){
secondDlg = new dijit.Dialog({
title: "Select a border color",
style: "width: 250px"
});
secondDlg.attr({href:"/member/colours"})
secondDlg.show();
}
if(solid == "0" && texture == "1"){
secondDlg = new dijit.Dialog({
title: "Select a border texture",
style: "width: 380px"
});
secondDlg.attr({href:"/member/textures"})
secondDlg.show();
}
});
[/code]
-----
dee
--
View this message in context: http://www.nabble.com/Processing-events-in-a-Dialog-window-tp24550071p24550071.html
Sent from the Dojo mailing list archive at Nabble.com.
More information about the Dojo-interest
mailing list