Bug 574456 - SWT "no more handles" when using the color palette too much
Summary: SWT "no more handles" when using the color palette too much
Status: CLOSED FIXED
Alias: None
Product: Sirius
Classification: Modeling
Component: Diagram (show other bugs)
Version: 6.4.2   Edit
Hardware: PC Windows 10
: P3 normal (vote)
Target Milestone: 6.6.0   Edit
Assignee: Laurent Redor CLA
QA Contact: Glenn Plouhinec CLA
URL:
Whiteboard:
Keywords: triaged
Depends on: 573497 574457
Blocks:
  Show dependency tree
 
Reported: 2021-06-25 04:30 EDT by Laurent Redor CLA
Modified: 2021-12-10 04:07 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Laurent Redor CLA 2021-06-25 04:30:28 EDT
+++ This bug was initially created as a clone of Bug #573497 +++

Steps to reproduce:
* install the starter example
* select any element
* in the appearance tab, click on the "paint bucket" icon. Like, many many times, for 10s or more
* eclipse shuts down, the error log shows:

org.eclipse.swt.SWTError: No more handles
	at org.eclipse.swt.SWT.error(SWT.java:4749)
	at org.eclipse.swt.SWT.error(SWT.java:4638)
	at org.eclipse.swt.SWT.error(SWT.java:4609)
	at org.eclipse.swt.widgets.Display.error(Display.java:1240)
	at org.eclipse.swt.widgets.Display.internal_new_GC(Display.java:2650)
	at org.eclipse.swt.graphics.Image.getImageDataAtCurrentZoom(Image.java:1547)
	at org.eclipse.swt.graphics.Image.getImageData(Image.java:1370)
	at org.eclipse.swt.internal.ImageList.set(ImageList.java:365)
	at org.eclipse.swt.internal.ImageList.add(ImageList.java:52)
	at org.eclipse.swt.widgets.Button._setImage(Button.java:131)
	at org.eclipse.swt.widgets.Button.setImage(Button.java:891)
	at org.eclipse.sirius.diagram.ui.tools.internal.dialogs.ColorPalettePopup.<init>(ColorPalettePopup.java:185)
	at org.eclipse.sirius.diagram.ui.tools.internal.properties.DiagramShapeColorAndFontPropertySection.changeColor(DiagramShapeColorAndFontPropertySection.java:136)
	at org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.ColorsAndFontsPropertySection.changeColor(ColorsAndFontsPropertySection.java:372)
	at org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.ShapeColorsAndFontsPropertySection.changeFillColor(ShapeColorsAndFontsPropertySection.java:85)
	at org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.ShapeColorsAndFontsPropertySection$1.widgetSelected(ShapeColorsAndFontsPropertySection.java:42)

Obviously the use case I mention does not happen regularly, but if an user uses the palette regularly for several hours he will encounter it (that's how the bug was found).
Comment 1 Eclipse Genie CLA 2021-06-25 04:36:17 EDT
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/182433
Comment 2 Eclipse Genie CLA 2021-06-25 04:36:19 EDT
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/182434
Comment 5 Laurent Redor CLA 2021-06-25 09:40:27 EDT
To validate, see bug 573497 comment 6.
Comment 6 Glenn Plouhinec CLA 2021-10-19 09:49:21 EDT
Validated with OD 11.6.0 IT1
Comment 7 Pierre-Charles David CLA 2021-12-10 04:07:04 EST
Available in Sirius 6.6.0: https://projects.eclipse.org/projects/modeling.sirius/releases/6.6.0