for (int i=0; i<parent.items.length; i++) { TableItem item = parent.items [i]; if (item != null && item.cached) { width = Math.max (width, parent.calculateWidth (handle, item.handle)); } }
public void pack () {	checkWidget();	int width = 0;	if (buttonHandle != 0) {		GtkRequisition requisition = new GtkRequisition ();		OS.gtk_widget_size_request (buttonHandle, requisition);		width = requisition.width;	}	if ((parent.style & SWT.VIRTUAL) != 0) {		//NOT DONE	} else {		int /*long*/ iter = OS.g_malloc (OS.GtkTreeIter_sizeof ());		if (OS.gtk_tree_model_get_iter_first (parent.modelHandle, iter)) {			do {				width = Math.max (width, parent.calculateWidth (handle, iter));			} while (OS.gtk_tree_model_iter_next(parent.modelHandle, iter));		}		OS.g_free (iter);	}	setWidth(width);}