currentRow++;
if (currentCol == maxCols) { currentRow++; currentCol = 0; } else { currentCol++; } gbc.gridx = currentCol;
    public void update(SortedSet<Route> routes) {        int currentRow = 0;        int currentCol = 0;        gbc.gridx = currentCol;        gbc.gridy = currentRow;        for (Route route : routes) {            RouteWidget routeWidget = new RouteWidget(route, frame);            routesPanel.add(routeWidget);            layout.setConstraints(routeWidget, gbc);            currentRow++;            gbc.gridy = currentRow;        }    }