diff options
author | Karsten Thoms | 2017-12-04 08:52:42 +0000 |
---|---|---|
committer | Alexander Kurtakov | 2018-01-26 21:00:30 +0000 |
commit | dbb1a0ec23e394a3235f67b08aa7202c42e9b16e (patch) | |
tree | 697f91fe6164a9a1fe0b3e8dc7e65fe80a49ec40 | |
parent | 0ab33c4cb003b97e487d7626cf9bd90e3b7aceb8 (diff) | |
download | eclipse.platform.swt-dbb1a0ec23e394a3235f67b08aa7202c42e9b16e.tar.gz eclipse.platform.swt-dbb1a0ec23e394a3235f67b08aa7202c42e9b16e.tar.xz eclipse.platform.swt-dbb1a0ec23e394a3235f67b08aa7202c42e9b16e.zip |
Bug 519753 - Added disposal checks
Change-Id: Ic34f2a6b6c3ebe63ba2c843d975a023f9b56003e
Signed-off-by: Karsten Thoms <karsten.thoms@itemis.de>
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Tree.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Tree.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Tree.java index 4011ba7a93..6509d9ca58 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Tree.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Tree.java @@ -2869,7 +2869,7 @@ void sendMeasureEvent (long /*int*/ cell, long /*int*/ width, long /*int*/ heigh long /*int*/ iter = OS.g_object_get_qdata (cell, Display.SWT_OBJECT_INDEX2); TreeItem item = null; if (iter != 0) item = _getItem (iter); - if (item != null) { + if (item != null && !item.isDisposed()) { int columnIndex = 0; if (columnCount > 0) { long /*int*/ columnHandle = OS.g_object_get_qdata (cell, Display.SWT_OBJECT_INDEX1); @@ -2888,7 +2888,7 @@ void sendMeasureEvent (long /*int*/ cell, long /*int*/ width, long /*int*/ heigh } Image image = item.getImage (columnIndex); int imageWidth = 0; - if (image != null) { + if (image != null && !image.isDisposed()) { Rectangle bounds = image.getBoundsInPixels (); imageWidth = bounds.width; } |