JS仿iGoogle自定义首页模块拖拽特效的方法(7)

if (movePos.y < tmpUp) {///从最上面插入虚线框
                                            dashedElement.style.width = Common.firstChild(dragTbl.rows[0].cells[j], "DIV").offsetWidth - 2 * parseInt(dashedElement.style.borderWidth) + "px";
                                            dragTbl.rows[0].cells[j].insertBefore(dashedElement, Common.firstChild(dragTbl.rows[0].cells[j], "DIV"));
                                        }
                                        else if (movePos.y > tmpDown) {///从最下面插入虚线框
                                            dashedElement.style.width = Common.lastChild(dragTbl.rows[0].cells[j], "DIV").offsetWidth - 2 * parseInt(dashedElement.style.borderWidth) + "px";
                                            dragTbl.rows[0].cells[j].appendChild(dashedElement);
                                        }

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/wgffxd.html