Community
Participate
Working Groups
In the method org.eclipse.gef.editpolicies.ResizableEditPolicy#getResizeCommand, I think that you forgot these lines after the request creation : req.setCenteredResize(request.isCenteredResize()); req.setConstrainedMove(request.isConstrainedMove()); req.setConstrainedResize(request.isConstrainedResize()); req.setSnapToEnabled(request.isSnapToEnabled()); You have the same problem in getResizeCommand. For my usecase, I'm working on resize and probably on move in the future. Please, could you add them in your code? Thank you. Regards, -- Vincent Lorenzo
These values are actually initialized within the related ResizeTracker#updateSourceRequest after the command has been returned by the policy. As such, we could add these lines but they won't have any direct effect. Did you notice some misbehavior that resulted from these missing lines?
(In reply to Alexander Nyssen from comment #1) > These values are actually initialized within the related > ResizeTracker#updateSourceRequest after the command has been returned by the > policy. As such, we could add these lines but they won't have any direct > effect. > > Did you notice some misbehavior that resulted from these missing lines? There is not misbehavior, I report this bug because I'm overriding XYLayoutEditPolicy and I would like to use the method isConstrainedResize(). Unfortunately, this boolean value has not been initialized during the copy of the request. Adding these lines in GEF will avoid us to do this minor change in all our subclasses of ResizableEditPolicy. Regards, -- Vincent Lorenzo
Applied the proposed changes. Pushed to origin/master. Will be available in 3.10.0 M5.
Lorenzo, could you please sign the CLA and confirm that your contribution complies to the http://www.eclipse.org/legal/CoO.php?
(In reply to Alexander Nyßen from comment #4) > Lorenzo, could you please sign the CLA and confirm that your contribution > complies to the http://www.eclipse.org/legal/CoO.php? Sorry, Vincent of course.
Hi Alexander, as you asked me by email. I signed the CLA and I confirm than I have the right to make contribution. I have authored 100% of the contribution. I have the necessary rights to submit this contribution, including any necessary permissions from my employer. I am providing this contribution under the license(s) associated with the Eclipse Foundation project I am contributing to. I understand and agree that Eclipse projects and my contributions are public, and that a record of the contribution (including all personal information I submit with it, including my sign-off) is maintained indefinitely and may be redistributed consistent with the license(s) involved.
Thanks very much!