Loading ...
Sorry, an error occurred while loading the content.
 

Re: Doing my own autoscroll during drag...

Expand Messages
  • Todd
    Well, I ll leave this up here... I looked real closesly to the code and discovered that you can turn off location caching in the DragManager and the locations
    Message 1 of 5 , Oct 4, 2006
      Well, I'll leave this up here... I looked real closesly to the code
      and discovered that you can turn off location caching in the
      DragManager and the locations will update as expected.

      The line I used is

      YAHOO.util.DDM.useCache = false;

      Hope this helps someone else out there with the same problem!

      --- In ydn-javascript@yahoogroups.com, "Todd" <todd@...> wrote:
      >
      > Nige,
      >
      > How did you do the autoscroll? I'm having the same problem but with a
      > Vertical div and the scroll bar showing. I've tried your techniques
      > but they don't seem to help the situation, and I'm just wondering if
      > maybe it is how I'm scrolling the div that counts. I'm using the
      > YAHOO.util.Anim scroll method.
      >
      > Todd
      >
      > --- In ydn-javascript@yahoogroups.com, Nige White <nigelw@> wrote:
      > >
      > > Nige White wrote:
      > >
      > > > Nige White wrote:
      > > >
      > > > > I'm dragging an element across a div which is
      > "style:overflow:hidden",
      > > > > and has content wider than the visible area.
      > > >
      > > > Another problem is that even though I'm constraining movement in
      the Y
      > > > axis to zero - and the actual *movement* is constrained
      correctly, the
      > > > UI doesn't report the correct target to the onDragDrop() method
      > when my
      > > > mouse is moved out of the constrained area - ie move a column
      but move
      > > > the mouse DOWN and it doesn't work.
      > > >
      > > > It should work, movement is constrained, and the dragEl is in fact
      > over
      > > > a target.
      > > >
      > > > Look at the window status bar display when you drag left and right
      > - it
      > > > shows the dragEl and target element and their positions. Move the
      > mouse
      > > > down while dragging, and this display stops changing - the UI isn't
      > > > firing the onDrag() method even though it is moving the dragEl!
      > >
      > >
      > > Of course if you set
      > >
      > > YAHOO.util.DragDropMgr.mode = YAHOO.util.DragDropMgr.INTERSECT;
      > >
      > > Then it works because YAHOO.util.DragDropMgr.OverTarget() then
      uses the
      > > Region of its this.dragCurrent to test for being over a target,
      rather
      > > than the *mouse* event coordinates.
      > >
      > > I think there's a bug there. The *MOUSE* coordinates are not
      > necessarily
      > > correct if you're constraining one of the axes of movement. The
      > > constrained coordinates should be the ones passed into the
      OverTarget()
      > > method if you're using POINT mode.
      > >
      > > As to the previous problem, I just set
      > >
      > > YAHOO.util.DragDropMgr = false;
      > >
      > > And it now looks up the positions of targets dynamically. It wasn't
      > > totally clear from the docs that I should do this, but a look at the
      > > code gave it away!
      > >
      > > Nige
      > >
      > > _____________________________________________________________________
      > > This message has been checked for all known viruses. Virus scanning
      > > powered by Messagelabs http://www.messagelabs.com For more information
      > > e-mail : hostmaster@
      > >
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.