补充: Firefox中一切正常. 就IE有问题.

解决方案 »

  1.   

    有几个问题
    1.为什么在mousemove的时候也要加上事件呢?这样pintar会不断被执行的
    2.你确定Firefox里没有问题吗?因为window.event在FF里似乎是无效的
    3.这个this到底到哪里好像有问题,建议加断点跟一下
      

  2.   

    应该是mousemove的问题,你把
    linhas[x].onmousemove = pintar; 
    去掉试试
      

  3.   

    部分代码请看下:(全部就太长了)function initMoveRows() {
    tabelaDrag = document.getElementById("tableIssues");
    linhas = tabelaDrag.getElementsByTagName("TR");
    celulas = tabelaDrag.getElementsByTagName("TD");  for (x=1; x<linhas.length;x++) {
    linhas[x].onmouseover = pintar;
    //linhas[x].onmousemove = pintar;
    // Modified by Muiz on 2008-12-21 13:25 Add (Task - B1) - Start
    linhas[x].onmouseout = pintar;
    // Modified by Muiz on 2008-12-21 13:25 Add (Task - B1) - Start
      }  .....
      }
    }
    .....
    function pintar(e) {
    if (!e) e=window.event
    ev = e.type if ((this.tagName == 'TR')) {
      linhaDrag = this.rowIndex   // Modified by Muiz on 2008-12-21 13:25 Add (Task - B1) - Start
      if (ev == "mouseout") {
       this.style.backgroundColor = "#dedede";
      } else if (ev == "mouseover") {
       this.style.backgroundColor = "#66FF00";
      }
      // Modified by Muiz on 2008-12-21 13:25 Add (Task - B1) - End
      if (ev == "mouseover" || ev == "mousemove") {
    if (drag) {
    if (linhaDrag != ultimaPosicao) {
    ultimaPosicao = linhaDrag;
    } var offsets = Position.cumulativeOffset(this);
    $('droper').setStyle({left: offsets[0]+'px', top: offsets[1] + 'px'}); Position.within(this, Event.pointerX(e), Event.pointerY(e)) var overlap = Position.overlap('vertical', this);

    direcao = 'cima';
    if (overlap <= 0.5) {
    $('droper').setStyle({top: (offsets[1]+this.clientHeight) + 'px'});
    direcao = 'baixo';
    } $('droper').show();
     }
      }
    }
    }如果这里没有问题, 那也许是其他地方影响了?