Update of /cvsroot/dynapi/dynapi/src/lib/dynapi/event
In directory usw-pr-cvs1:/tmp/cvs-serv30892

Modified Files:
        mouse.js 
Log Message:
coordinate fixes. ( IE & relative layers, god bless the day I introduced them :( )

Index: mouse.js
===================================================================
RCS file: /cvsroot/dynapi/dynapi/src/lib/dynapi/event/mouse.js,v
retrieving revision 1.25
retrieving revision 1.26
diff -C2 -r1.25 -r1.26
*** mouse.js    15 Jan 2002 12:30:37 -0000      1.25
--- mouse.js    26 Feb 2002 17:58:43 -0000      1.26
***************
*** 81,86 ****
        } else {
                // standard DynAPI coordinate calculation
!               evt.pageX=is.ie?e.x+document.body.scrollLeft:e.pageX;
!               evt.pageY=is.ie?e.y+document.body.scrollTop:e.pageY;
                evt.x=is.ie?evt.pageX-evt.src.getPageX():e.layerX
                evt.y=is.ie?evt.pageY-evt.src.getPageY():e.layerY
--- 81,86 ----
        } else {
                // standard DynAPI coordinate calculation
!               evt.pageX=is.ie?e.clientX+document.body.scrollLeft:e.pageX;
!               evt.pageY=is.ie?e.clientY+document.body.scrollTop:e.pageY;
                evt.x=is.ie?evt.pageX-evt.src.getPageX():e.layerX
                evt.y=is.ie?evt.pageY-evt.src.getPageY():e.layerY
***************
*** 94,99 ****
        };
        evt.button=b;
!       if (evt.button==2 && (type=='mousedown' || type=='mouseup' || 
type=='mouseclick')) type=evt.type='md'+type;
!       if (evt.button==3 && (type=='mousedown' || type=='mouseup' || 
type=='mouseclick')) type=evt.type='rt'+type;
  
        // Step four: modifiers
--- 94,99 ----
        };
        evt.button=b;
!       if (evt.button==2 && (type=='mousedown' || type=='mouseup' || type=='click')) 
type=evt.type='md'+type;
!       if (evt.button==3 && (type=='mousedown' || type=='mouseup' || type=='click')) 
type=evt.type='rt'+type;
  
        // Step four: modifiers


_______________________________________________
Dynapi-CVS mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dynapi-cvs

Reply via email to