Community
Participate
Working Groups
Build Identifier: M6 Build When you put an Area in a SashPart and try to Resize the Sahs we get the Exception below: org.eclipse.swt.widgets.Composite incompatible with org.eclipse.swt.graphics.Rectangle at org.eclipse.e4.ui.workbench.renderers.swt.SashLayout.getRectangle(SashLayout.java:207) at org.eclipse.e4.ui.workbench.renderers.swt.SashLayout.adjustWeights(SashLayout.java:167) at org.eclipse.e4.ui.workbench.renderers.swt.SashLayout$2.mouseMove(SashLayout.java:90) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:212) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053) Reproducible: Always Steps to Reproduce: 1. Open Example in IDE 2. Start Product 3. Resize the Parts - you'll get the exception
Created attachment 213558 [details] Example Project with Product
Created attachment 213607 [details] Proposed patch In SashLayout the private method getRectangle throws this CCE because it supposes that the method getWidget() of an instance of MGenericTile *always* returns an instance of Rectangle, which is not the case. Proposed some modifications which make it work properly.
Sopot, I've made the change you suggest (thanks a lot!). I haven't yet 'pushed' it because I'm working on some other defects related to DnD and sashes. I'll remember to update this defect when I do the push of my other changes... Tom can you verify that your code works correctly with the change suggested by Sopot ?
(In reply to comment #3) > Sopot, I've made the change you suggest (thanks a lot!). I haven't yet 'pushed' > it because I'm working on some other defects related to DnD and sashes. I'll > remember to update this defect when I do the push of my other changes... I've also another patch pending review relating to DnD and sashes here https://bugs.eclipse.org/bugs/show_bug.cgi?id=375194 if you have time to review it.
Is there any progress in this case ?
(In reply to comment #3) > Tom can you verify that your code works correctly with the change suggested by > Sopot ? awaiting your comment .... PW
I'm fairly sure that this has been fixed. At least the sample project no longer throws exceptions... Tom, try RC3 and if it's not fixed feel free to re-open this and we'll take another look.
Verified in I20120603-1910 using the provided project (thanks!)
Thanks !