for (int i=0; i<items.length; i++) { ToolItem item = items [i]; if (item != null && !item.isDisposed ()) { item.releaseImages (); item.releaseResources ();
if (items != null) { for (int i=0; i<items.length; i++) { ToolItem item = items [i]; if (item != null && !item.isDisposed ()) { item.releaseImages (); item.releaseResources (); }
void releaseWidget () {	for (int i=0; i<items.length; i++) {		ToolItem item = items [i];		if (item != null && !item.isDisposed ()) {			item.releaseImages ();			item.releaseResources ();		}	}	items = null;	if (imageList != null) {		OS.SendMessage (handle, OS.TB_SETIMAGELIST, 0, 0);		display.releaseToolImageList (imageList);	}	if (hotImageList != null) {		OS.SendMessage (handle, OS.TB_SETHOTIMAGELIST, 0, 0);		display.releaseToolHotImageList (hotImageList);	}	if (disabledImageList != null) {		OS.SendMessage (handle, OS.TB_SETDISABLEDIMAGELIST, 0, 0);		display.releaseToolDisabledImageList (disabledImageList);	}	imageList = hotImageList = disabledImageList = null;	super.releaseWidget ();}