You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 8, 2017. It is now read-only.
Hi,
I'm using gwt-dnd in my application and I experienced an error in the method onMove implemented in AbstractInsertPanelDropController.
My drop controller is constituted by a VerticalPanel and it is implemented by means of a VerticalPanelDropController.
The vertical panel is added to an absolute panel A, whereas A is added to a content panel. The height of the content panel is smaller than the height of A, so a vertical scroll bar is added. When the content panel automatically scrolls during the drag operation, the onMove method in the AbstractInsertPanelDropController causes a RunTime error (Null Pointer exception). As a matter of fact, the attribute positioner of the class, that represents the widget that shows the preview of the drag operation, becomes null during the scroll and the call to the method dropTarget.insert(positioner, targetIndex) rises the above error.
Unfortunately, the attribute positioner is private and has no getter. So, in order to fix the bug, I should completely reimplement both AbstractInsertPanelDropController and VerticalPanelDropController, in order to fix the onMove behavior. In my actual implementation, when positioner becomes null, it is recomputed again using the method newPositioner. I don't know exactly if this method is the best one but actually it works.
I hope my submission can be helpful for the mainteinance of the library.
loresarti74
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi,
I'm using gwt-dnd in my application and I experienced an error in the method onMove implemented in AbstractInsertPanelDropController.
My drop controller is constituted by a VerticalPanel and it is implemented by means of a VerticalPanelDropController.
The vertical panel is added to an absolute panel A, whereas A is added to a content panel. The height of the content panel is smaller than the height of A, so a vertical scroll bar is added. When the content panel automatically scrolls during the drag operation, the onMove method in the AbstractInsertPanelDropController causes a RunTime error (Null Pointer exception). As a matter of fact, the attribute positioner of the class, that represents the widget that shows the preview of the drag operation, becomes null during the scroll and the call to the method dropTarget.insert(positioner, targetIndex) rises the above error.
Unfortunately, the attribute positioner is private and has no getter. So, in order to fix the bug, I should completely reimplement both AbstractInsertPanelDropController and VerticalPanelDropController, in order to fix the onMove behavior. In my actual implementation, when positioner becomes null, it is recomputed again using the method newPositioner. I don't know exactly if this method is the best one but actually it works.
I hope my submission can be helpful for the mainteinance of the library.
loresarti74
The text was updated successfully, but these errors were encountered: