Thanks for your quick reply. I actually meant to say "the scrolling
that happens when the object is moved beyond the original boundaries
(bottom and right) of the absolute panel". The current behaviour is
when a draggable widget is dragged beyond the right/bottom boundaries
my scroll bars extend and the widget moves but the positioner(the
dotted border that appears when you start moving) never moves beyond
the border. I found that if I change the onMove method in the
AbsolutePositionDropController, to not execute these two lines of code
draggable.desiredX = Math.max(0, Math.min(draggable.desiredX,
dropTargetClientWidth
- draggable.offsetWidth));
draggable.desiredY = Math.max(0, Math.min(draggable.desiredY,
dropTargetClientHeight
- draggable.offsetHeight));
I am able to move the positioner as well but there are other side-
effects, so just wanted to see if there was a cleaner way to do this.
On Jun 18, 1:14 pm, Fred Sauer <
fre...@google.com> wrote:
> 2009/6/18 SG <
cgswa...@gmail.com>
>
>
>
> > Hi,
>
> > I have been trying to make the dnd library work for our application
> > that has an absolute panel that has to scroll when an object is moved
> > beyond its original size and ahve not been sucessful so far. I have
> > the css set up to scroll the panel on overflow. I just downloaded the
> > latest version of the library dnd-2.6.4 and played with it. I can see
> > that the library now has scrollIntoView and that widget locations now
> > take the scroll into consideration but the move method in the
> > AbsolutePositionDropController still calculates the desiredX and Y
> > positions by taking the dropTargetWidth and heights that dont reflect
> > the scrolling that happens once the widget starts moving, so the
>
> I think you mean:
> the resizing that I want to happen once the widget starts moving, so the
> rather than:
> the scrolling that happens once the widget starts moving, so the
>
> I'd recommend using your own AbsolutePositionDropController (just copy/paste
> the code into your own class) and increase the size of the drop target as
> the desired position would cause the widget to overflow. You may need to
> look at the reset cache examplehttp://
allen-sauer.com/com.allen_sauer.gwt.dnd.demo.DragDropDemo/Drag...
> code.
>
> Hope that helps
> Fred
>
> > positioner never moves beyond the initial size of the absolute panel.
> > Is there a way to change this behaviour?
>
> > Thanks,
> > Swathy
>
> --
> Fred Sauer
> Developer Advocate
> Google Inc.1600 Amphitheatre Parkway