Will
Will

Reputation: 410

GWT Disable horizontal drag scrolling

I have a celltable inside a scroll panel. That way I can vertically scroll through all the items. I have been using the gquery plugin for drag and drop functionality. I am wanting to drag an item from one table to another. My problem is that when I try to drag and item from table 1 to table 2, the scroll panel is doing a horizontal autoscroll, so my item is never escaping the scroll panel. How do I drag and item outside the scroll panel?

Upvotes: 0

Views: 420

Answers (1)

Chris Lercher
Chris Lercher

Reputation: 37778

You will get horizontal overflow if and only if the widget within the scroll panel (i.e. the one you set using flowPanel.setWidget(widget)) is horizontally larger than the scroll panel.

The easiest way to avoid this is to use a standard FlowPanel for the widget, because by default, it is just as wide as its scroll panel.

Upvotes: 0

Related Questions