全文预览已结束
下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
Javascript写的div布局yhm.NsLayout = function(paras) this.paras = paras; this.events = new yhm.Delegate();yhm.NsLtotype.beginPos=-1;yhm.NsLtotype.render=function() var n = ; var m=; m.push(); m.push(); m.push(); m.push(); yhm.render(m.join(),this.paras.renderTo); this.afterRender();yhm.NsLtotype.afterRender=function() var n = ; var o1 = yhm.getObject(this.paras.north); var o2 = this.paras.south?yhm.getObject(this.paras.south):null; var o = yhm.g(n+_split) var me=this; yhm.attachEvent(o,mousedown,(function(obj) return function(e) emis_layout_down(obj,e); )(me); yhm.attachEvent(document,mousemove,(function(obj) return function(e) emis_layout_move(obj,e); )(me); yhm.attachEvent(document,mouseup, (function(obj) return function(e) emis_layout_up(obj,e); )(me); o = null; o1.paras.renderTo = n+_n; o1.render(); if (o2!=null) o2.paras.renderTo = n+_s; o2.render(); o1=null; o2=null;yhm.NsLtotype.resize=function() var s = yhm.getSize(this.paras); var w = s.width; var h = s.height; var n = ; if(!this.paras.northHeight) this.paras.northHeight = h-12-this.paras.southHeight; e(n+_n).setHeight(this.paras.northHeight) yhm.e.setWidth(w-10); h=h-14-this.paras.northHeight; e(n+_s).setHeight(h0?0:h); yhm.e.setWidth(w-10); e.ele = null; yhm.getObject(this.paras.north).resize(); if(this.paras.south) yhm.getObject(this.paras.south).resize(); if(this.paras.children) var c=this.paras.children;var i=c.length; while(i-) yhm.getObject(ci).resize(); c=null; ;yhm.NsLtotype.addChild=function(n) if(!this.paras.children) this.paras.children=; this.paras.childrenthis.paras.children.length=n;function emis_layout_down(obj,e) var n=; var o = yhm.g(emis_line) if (o = null) o = document.createElement(SPAN); o.id = emis_line; o.className = emis_grid_line; document.body.appendChild(o); obj.beginPos = yhm.clientY(e); o.style.top = obj.beginPos-2 + px; o.style.width = yhm.g(n+_split).clientWidth+px; o.style.height = 4px; o.style.left= (yhm.g(n+_split).getBoundingClientRect().left + document.documentElement.scrollLeft-2) + px; o.style.display = ; o = null; document.body.setCapture();function emis_layout_move(obj,e) if (obj.beginPos!=-1) var y=yhm.clientY(e); yhm.g(emis_line).style.top= (y-2)+ px; if(document.selection) document.selection.empty(); else window.getSelection().removeAllRanges(); function emis_layout_up(obj,e) if (obj.beginPos!=-1) document.body.releaseCapture(); obj.paras.northHeight =parseI
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 建筑物外立面雨水排水设计方案
- 施工现场施工机械安全管理
- 林下园林景观中的耐阴植物配置与应用分析
- 电力系统检修安全操作规范
- 凸轮轴、曲轴项目可行性分析报告范文(总投资5000万元)
- 乳化油项目可行性分析报告范文
- 化学品存储项目可行性分析报告范文(总投资14000万元)
- 科技创新大赛知识竞赛培训试题及答案
- 深化科技管理体制改革如何借助AI+数智应用实现科技管理系统的深层次价值创造
- 校园消防安全监控系统建设
- 高空曲臂车安全操作规程
- 2025年粉尘涉爆培训题库及答案
- 厨房消防安全培训课件
- 2025江苏吉安吉水县城控人力资源服务有限公司招聘水电工2人笔试考试参考试题附答案解析
- 丙型肝炎防治指南
- 2025中国农业科学院第三批统一招聘2人笔试考试备考题库及答案解析
- 2025年基层党支部书记述职报告
- 中国稀土镁合金治炼项目投资可行性研究报告
- GB/T 30340-2025机动车驾驶员培训机构业务条件
- 传统文化经典教案范例分享
- 2025艺术品买卖合同范本
评论
0/150
提交评论