| [便民信息] 青山知可子-青山知可子网-青山知可子信息
|
| 发布时间:2007-7-23 15:34:00 信息已经过期
浏览/回复:47次/0次 |
|
|
|
| 1)
document.tagObj.tagObj.style.zIndex=document.tagObj.oldzIndex;
//释放鼠标的定位对象
document.tagObj.releaseCapture();
}
}
//接入事件处理,由运行时决定
_FF_drag.prototype= new dragDrag();
//firefox插件
function _FF_drag()
{
//分配事件,一次性分配
this._objMove=function(obj)
{
obj.addEventListener('mousedown',obj.ref.dragInit,true);
},
//有关闭功能的对象
this._objClose=function(obj)
{
obj.oldClassName=obj.className;
obj.addEventListener('click',obj.ref.closeInit,true);
obj.addEventListener('mouseover',obj.ref.closeUp,true);
obj.addEventListener('mouseout',obj.ref.closeOut,true);
},
//分配事件,一次性分配
this._objResize=function(obj)
{
obj.addEventListener('mousedown',obj.ref.reziseInit,true);
},
//鼠标按下去的时候
this.resizeDown=function()
{
document.addEventListener('mousemove',document.tagObj.ref.resizeMove,true);
document.addEventListener('mouseup',function()
{
document.tagObj.ref.resizeUp();
},false);
document.tagObj.hasup=false;
//设置半透明
document.tagObj.tagObj.style.opacity ='0.8';
},
//
this.resizeUp=function()
{
document.removeEventListener('mousemove',document.tagObj.ref.resizeMove,true);
document.removeEventListener('mouseup',function()
{
document.tagObj.ref.resizeUp();
},false);
//记录鼠标已经移开了
document.tagObj.hasup=true;
//取消半透明
document.tagObj.tagObj.style.opacity ='1';
},
//鼠标按下去的tine
this.dragDown=function()
{
//设置半透明,这个要导致cpu占用40%左右!
document.tagObj.tagObj.style.opacity ='0.8';
document.addEventListener('mousemove',document.tagObj.ref.dragMove,true);
//firefox要特别处理这个,因为他监控不了鼠标的状态
document.addEventListener('mouseup',function()
{
document.tagObj.ref.dragUp();
},false);
document.tagObj.hasup=false;
}
//当鼠标放开的时候
this.dragUp=function()
{
document.tagObj.hasup=true;
//取消透明
document.tagObj.tagObj.style.opacity ='1';
//取消事件的绑定
document.removeEventListener('mousemove',document.tagObj.ref.dragMove,false);
//firefox要特别处理这个,因为他监控不了鼠标的状态
document.removeEventListener('mouseup',function()
{
document.tagObj.ref.dragUp();
},false);
//还原相对立体位置
document.tagObj.tagObj.style.zIndex=document.tagObj.oldzIndex;
}
}
//带有子框架的拖动框
dragIframe.prototype= new dragDrag();
function dragIframe()
{
//框架公共处理事件接口
this._objIframe=function(dragIframe_objIframe)
{
//先把框架放大
dragIframe_objIframe.width=dragIframe_objIframe.parentNode.nextSibling.clientWidth;
dragIframe_objIframe.height=dragIframe_objIframe.clientHeight;
document.dragIframe_objIframe=dragIframe_objIframe;
//自动适应宽度和高度
dragIframe_objIframe.tagObj.ref._iframeonload(dragIframe_objIframe);
},
this.iframeonloadOkEnd=function(handObj,doc)
{
//
if(!(buttonObj=doc.getElementById('html-buttom')))
{
var buttonObj=doc.createElement("DIV");
buttonObj.id='html-buttom';
buttonObj.style.clear='both';
buttonObj.style.display='block';
doc.body.appendChild(buttonObj);
}
cy=handObj.tagObj.ref.point(buttonObj,'Top');
handObj.tagObj.ref.resizeY(cy);
//取消页面加载的提示
handObj.previousSibling.style.display='none';
if(!doc.noresize)
handObj.tagObj.ref.noresize();
}
//按钮放开的时候
this.closeInit=function(event)
{
try{
//得到当前的对象
Handobj=event.srcElement?event.srcElement:event.target;
Handobj.tagObj.style.display='none';
document.dragIframe_objIframe.src='about:blank';
}catch(e){}
},
//
this.resizeMove=function (event)
{
if(dragIframe.prototype.resizeMove(event))
{
document.dragIframe_objIframe.width=document.dragIframe_objIframe.parentNode.nextSibling.clientWidth;
document.dragIframe_objIframe.height=document.dragIframe_objIframe.parentNode.clientHeight-10;
}
},
//开始打开某个页面框架
this.openurl=function(url)
{
//显示页面加载的提示
document.dragIframe_objIframe.previousSibling.style.display='block';
document.dragIframe_objIframe.src='about:blank';
if(document.dragIframe_objIframe.tagObj.style.display=='none')
return null;
//保证不缓存数据
document.dragIframe_objIframe.src=url+'&time='+new Date().getTime();
},
//将窗口变化到制定的大小
this.resize=function(width,height)
{
//同时左右也拉宽
document.dragIframe_objIframe.vrstntNode.parentNode.style.width=width+'px';
document.dragIframe_objIframe.tagObj.style.width=width+'px';
document.dragIframe_objIframe.style.width=width+'px';
document.dragIframe_objIframe.height=height;
}
//只要改变高度
this.resizeY=function(height)
{
try{
document.dragIframe_objIframe.tagObj.style.height=height+30+'px';
document.dragIframe_objIframe.height=height;
}catch(e){}
}
//只要改变宽度
this.resizeX=function(width)
{
document.dragIframe_objIframe.tagObj.style.width=width+'px';
document.dragIframe_objIframe.style.width=width+'px';
}
//
this.new2=function()
{
this.allEvenetArray.push('_objIframe');
return document.all?new _IE_drag_iframe:new _FF_drag_iframe;
}
}
//重定向父类位置
_IE_drag.prototype = new dragIframe();
//IE(扩展)
_IE_drag_iframe.prototype= new _IE_drag();
function _IE_drag_iframe()
{
//绑定框架载入事件
this._iframeonload=function(iframeObj)
{
iframeObj.attachEvent('onload',iframeObj.tagObj.ref.iframeonloadOk);
}
//转载完毕,开始事件触发
this.iframeonloadOk=function(event)
{
try{
handObj=event.srcElement;
doc=document.frames(handObj.id).document;
handObj.tagObj.ref.iframeonloadOkEnd(handObj,doc);
}catch(e){}
}
}
//重定向父类位置
_FF_drag.prototype = new dragIframe();
//firefox(扩展)
_FF_drag_iframe.prototype= new _FF_drag();
function _FF_drag_iframe()
{
//绑定框架载入事件
this._iframeonload=function(iframeObj)
{
iframeObj.addEventListener('load',iframeObj.tagObj.ref.iframeonloadOk,true);
}
//转载完毕,开始事件触发
this.iframeonloadOk=function(event)
{
try{
//注意框架的绑定对象是不一样的
handObj=event.currentTarget;
doc=handObj.contentDocument;
handObj.tagObj.ref.iframeonloadOkEnd(handObj,doc);
}catch(e){}
}
}
//
function starstar()
{
this.set=function (divObj,number,newSrc,oldsrc)
{
//只需要绑定事件一次
if(divObj._set==null)
{
divObj._set=true;
divObj.number=number;
divObj.newSrc=newSrc;
divObj.oldsrc=oldsrc;
if(!divObj.ref)
divObj.ref=this;
try{
var icount=0;
var notes=divObj.childNodes;
for(i in notes)
if(notes[i].tagName=='IMG' && !notes[i]._loadevent)
{
notes[i].num=++icount;
//对单独的星星绑定事件
divObj.ref._loadevent(notes[i]);
//标志已经被绑定事件了
notes[i]._loadevent=true;
}
return true;
}catch(e){alert(e['message']); return false; }
}
return false;
}
//重新设置星星的个数
this.fix=function(divObj,num)
{
try{
var count=0;
for(i in divObj.childNodes)
if(divObj.childNodes[i].tagName=='IMG' && !divObj.childNodes[i]._loadevent)
{
count++;
if(count |
|
联系时说明在unu5.com看到的信息,将会获得更多的信任。 |
| (免责声明:站内会员言论仅代表个人观点,并不代表本站同意其说法或描述,本站不承担由此引起的法律责任。)
| |
| |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
| |
| 相关信息: |
- 青山知可子传
- 青山知可子小说学院
- 青山知可子下载
- 青山知可子集中营
- 青山知可子生活馆
- 青山知可子的电子商务
- 青山知可子花园
- 青山知可子的本土化
- 我要青山知可子
- 青山知可子优化日记
|
| |
|
|