genius551v
3 May 2007, 2:28 PM
Hi guys,
I liked very much the MSG of the examples, and i wanted to have something like MSN-MESENGER or YAHOO-MESENGER, i talk about something like that: (attachment1)
ok, i have this but dont work full, in FF the pos (x,y) is diferent in IE:
Ext.message = function(){
var msgCt;
function createBox(t, s){
return ['<div class="msg">',
'<div class="x-box-tl"><div class="x-box-tr"><div class="x-box-tc"></div></div></div>',
'<div class="x-box-ml"><div class="x-box-mr"><div class="x-box-mc"><h3>', t, '</h3>', s, '</div></div></div>',
'<div class="x-box-bl"><div class="x-box-br"><div class="x-box-bc"></div></div></div>',
'</div>'].join('');
}
return {
msg : function(title, format){
if(!msgCt){
msgCt = Ext.DomHelper.insertFirst(document.body, {id:'msg-div'}, true);
}
msgCt.alignTo(document, 'br-br', [-7,-67]); /*<-- pos in bottom-right corner*/
var s = String.format.apply(String, Array.prototype.slice.call(arguments, 1));
var m = Ext.DomHelper.append(msgCt, {html:createBox(title, s)}, true);
m.slideIn('b').pause(1).ghost("b", {remove:true}); /*<--move from bottom*/
}
}
}();
ok, see like that: (attachments2,3)
any suggest? any idea about style to look like msn-mesenger??
Tnks
I liked very much the MSG of the examples, and i wanted to have something like MSN-MESENGER or YAHOO-MESENGER, i talk about something like that: (attachment1)
ok, i have this but dont work full, in FF the pos (x,y) is diferent in IE:
Ext.message = function(){
var msgCt;
function createBox(t, s){
return ['<div class="msg">',
'<div class="x-box-tl"><div class="x-box-tr"><div class="x-box-tc"></div></div></div>',
'<div class="x-box-ml"><div class="x-box-mr"><div class="x-box-mc"><h3>', t, '</h3>', s, '</div></div></div>',
'<div class="x-box-bl"><div class="x-box-br"><div class="x-box-bc"></div></div></div>',
'</div>'].join('');
}
return {
msg : function(title, format){
if(!msgCt){
msgCt = Ext.DomHelper.insertFirst(document.body, {id:'msg-div'}, true);
}
msgCt.alignTo(document, 'br-br', [-7,-67]); /*<-- pos in bottom-right corner*/
var s = String.format.apply(String, Array.prototype.slice.call(arguments, 1));
var m = Ext.DomHelper.append(msgCt, {html:createBox(title, s)}, true);
m.slideIn('b').pause(1).ghost("b", {remove:true}); /*<--move from bottom*/
}
}
}();
ok, see like that: (attachments2,3)
any suggest? any idea about style to look like msn-mesenger??
Tnks