private void removeAllRowsInGrids() { int rowCount = propertyGrid.getRowCount(); // Loop from i=1 because we don't remove the grid label for (int i = rowCount - 1; i > 0; i--) { propertyGrid.removeRow(i); } rowCount = resourceGrid.getRowCount(); // Loop from i=1 because we don't remove the grid label for (int i = rowCount - 1; i > 0; i--) { resourceGrid.removeRow(i); } }
private void addToChildrenResourceGrid(ExplorerGrid grid, Item item) { Object[] cols = new Object[2]; cols[0] = item.getName(); cols[1] = item.getType(); grid.addRow(grid.getRowCount(), cols); }
private void addToPropertyGrid(ExplorerGrid grid, Item item) { Object[] cols = new Object[4]; cols[0] = item.getName(); cols[1] = item.getType(); cols[2] = item.getValue(); cols[3] = item.isMutli().toString(); grid.addRow(grid.getRowCount(), cols); }