|
|
@ -46,7 +46,7 @@ function roundcube_browser()
|
|
|
|
this.dom = document.getElementById ? true : false;
|
|
|
|
this.dom = document.getElementById ? true : false;
|
|
|
|
this.dom2 = (document.addEventListener && document.removeEventListener);
|
|
|
|
this.dom2 = (document.addEventListener && document.removeEventListener);
|
|
|
|
|
|
|
|
|
|
|
|
this.ie = (document.all && !window.opery);
|
|
|
|
this.ie = (document.all && !window.opera);
|
|
|
|
this.ie4 = (this.ie && !this.dom);
|
|
|
|
this.ie4 = (this.ie && !this.dom);
|
|
|
|
this.ie5 = (this.dom && this.appver.indexOf('MSIE 5')>0);
|
|
|
|
this.ie5 = (this.dom && this.appver.indexOf('MSIE 5')>0);
|
|
|
|
this.ie8 = (this.dom && this.appver.indexOf('MSIE 8')>0);
|
|
|
|
this.ie8 = (this.dom && this.appver.indexOf('MSIE 8')>0);
|
|
|
@ -192,8 +192,8 @@ get_modifier: function(e)
|
|
|
|
get_mouse_pos: function(e)
|
|
|
|
get_mouse_pos: function(e)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (!e) e = window.event;
|
|
|
|
if (!e) e = window.event;
|
|
|
|
var mX = (e.pageX) ? e.pageX : e.clientX;
|
|
|
|
var mX = (e.pageX) ? e.pageX : e.clientX,
|
|
|
|
var mY = (e.pageY) ? e.pageY : e.clientY;
|
|
|
|
mY = (e.pageY) ? e.pageY : e.clientY;
|
|
|
|
|
|
|
|
|
|
|
|
if (document.body && document.all) {
|
|
|
|
if (document.body && document.all) {
|
|
|
|
mX += document.body.scrollLeft;
|
|
|
|
mX += document.body.scrollLeft;
|
|
|
@ -369,20 +369,18 @@ function rcube_layer(id, attributes)
|
|
|
|
// create a new layer in the current document
|
|
|
|
// create a new layer in the current document
|
|
|
|
this.create = function(arg)
|
|
|
|
this.create = function(arg)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
var l = (arg.x) ? arg.x : 0;
|
|
|
|
var l = (arg.x) ? arg.x : 0,
|
|
|
|
var t = (arg.y) ? arg.y : 0;
|
|
|
|
t = (arg.y) ? arg.y : 0,
|
|
|
|
var w = arg.width;
|
|
|
|
w = arg.width,
|
|
|
|
var h = arg.height;
|
|
|
|
h = arg.height,
|
|
|
|
var z = arg.zindex;
|
|
|
|
z = arg.zindex,
|
|
|
|
var vis = arg.vis;
|
|
|
|
vis = arg.vis,
|
|
|
|
var parent = arg.parent;
|
|
|
|
parent = arg.parent,
|
|
|
|
var obj;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
obj = document.createElement('DIV');
|
|
|
|
obj = document.createElement('DIV');
|
|
|
|
|
|
|
|
|
|
|
|
with(obj) {
|
|
|
|
with (obj) {
|
|
|
|
id = this.name;
|
|
|
|
id = this.name;
|
|
|
|
with(style) {
|
|
|
|
with (style) {
|
|
|
|
position = 'absolute';
|
|
|
|
position = 'absolute';
|
|
|
|
visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden';
|
|
|
|
visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden';
|
|
|
|
left = l+'px';
|
|
|
|
left = l+'px';
|
|
|
@ -391,7 +389,8 @@ function rcube_layer(id, attributes)
|
|
|
|
width = w.toString().match(/\%$/) ? w : w+'px';
|
|
|
|
width = w.toString().match(/\%$/) ? w : w+'px';
|
|
|
|
if (h)
|
|
|
|
if (h)
|
|
|
|
height = h.toString().match(/\%$/) ? h : h+'px';
|
|
|
|
height = h.toString().match(/\%$/) ? h : h+'px';
|
|
|
|
if(z) zIndex = z;
|
|
|
|
if (z)
|
|
|
|
|
|
|
|
zIndex = z;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -404,14 +403,14 @@ function rcube_layer(id, attributes)
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
// create new layer
|
|
|
|
// create new layer
|
|
|
|
if(attributes != null) {
|
|
|
|
if (attributes != null) {
|
|
|
|
this.create(attributes);
|
|
|
|
this.create(attributes);
|
|
|
|
this.name = this.elm.id;
|
|
|
|
this.name = this.elm.id;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else // just refer to the object
|
|
|
|
else // just refer to the object
|
|
|
|
this.elm = document.getElementById(id);
|
|
|
|
this.elm = document.getElementById(id);
|
|
|
|
|
|
|
|
|
|
|
|
if(!this.elm)
|
|
|
|
if (!this.elm)
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -654,4 +653,4 @@ if (bw.ie)
|
|
|
|
|
|
|
|
|
|
|
|
return obj;
|
|
|
|
return obj;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
}
|
|
|
|