diff --git a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCell.java b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCell.java index ad4144f63..3645149f8 100644 --- a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCell.java +++ b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCell.java @@ -101,8 +101,7 @@ public class ContributedLibraryTableCell extends JPanel { add(Box.createVerticalStrut(15)); } - void update(JTable parentTable, Object value, boolean isSelected, int row, - boolean hasBuiltInRelease) { + void update(JTable parentTable, Object value, boolean isSelected) { ContributedLibraryReleases releases = (ContributedLibraryReleases) value; JTextPane description = makeNewDescription(); diff --git a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellEditor.java b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellEditor.java index 08bfdb854..f825210b6 100644 --- a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellEditor.java +++ b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellEditor.java @@ -134,7 +134,7 @@ public class ContributedLibraryTableCellEditor extends InstallerTableCell { editorCell.versionToInstallChooser .setVisible(installed == null && uninstalledReleases.size() > 1); - editorCell.update(table, value, true, row, !installedBuiltIn.isEmpty()); + editorCell.update(table, value, true); editorCell.setBackground(new Color(218, 227, 227)); // #dae3e3 return editorCell; } diff --git a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellRenderer.java b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellRenderer.java index a472029a3..1613d7aaf 100644 --- a/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellRenderer.java +++ b/app/src/cc/arduino/contributions/libraries/ui/ContributedLibraryTableCellRenderer.java @@ -45,7 +45,7 @@ public class ContributedLibraryTableCellRenderer implements TableCellRenderer { ContributedLibraryTableCell cell = new ContributedLibraryTableCell(); cell.setButtonsVisible(false); - cell.update(table, value, isSelected, row, false); + cell.update(table, value, isSelected); if (row % 2 == 0) { cell.setBackground(new Color(236, 241, 241)); // #ecf1f1 diff --git a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCell.java b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCell.java index 34ac5ca0e..d0cdba0b9 100644 --- a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCell.java +++ b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCell.java @@ -145,7 +145,7 @@ public class ContributedPlatformTableCell extends JPanel { add(Box.createVerticalStrut(15)); } - void update(JTable parentTable, Object value, boolean isSelected, int row, + void update(JTable parentTable, Object value, boolean isSelected, boolean hasBuiltInRelease) { ContributionIndexTableModel.ContributedPlatformReleases releases = (ContributionIndexTableModel.ContributedPlatformReleases) value; diff --git a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellEditor.java b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellEditor.java index 20e8170b8..cee510826 100644 --- a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellEditor.java +++ b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellEditor.java @@ -131,7 +131,7 @@ public class ContributedPlatformTableCellEditor extends InstallerTableCell { editorCell.versionToInstallChooser .setVisible(installed == null && uninstalledReleases.size() > 1); - editorCell.update(table, value, true, row, !installedBuiltIn.isEmpty()); + editorCell.update(table, value, true, !installedBuiltIn.isEmpty()); editorCell.setBackground(new Color(218, 227, 227)); // #dae3e3 return editorCell; } diff --git a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellRenderer.java b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellRenderer.java index fa0230eb0..b3a45bc0b 100644 --- a/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellRenderer.java +++ b/app/src/cc/arduino/contributions/packages/ui/ContributedPlatformTableCellRenderer.java @@ -44,16 +44,15 @@ public class ContributedPlatformTableCellRenderer implements TableCellRenderer { int column) { ContributedPlatformTableCell cell = new ContributedPlatformTableCell(); cell.setButtonsVisible(false); - - cell.update(table, value, isSelected, row, false); + cell.update(table, value, isSelected, false); + if (row % 2 == 0) { cell.setBackground(new Color(236, 241, 241)); // #ecf1f1 } else { cell.setBackground(new Color(255, 255, 255)); } - int height = new Double(cell.getPreferredSize().getHeight()) - .intValue(); + int height = new Double(cell.getPreferredSize().getHeight()).intValue(); if (table.getRowHeight(row) < height) { table.setRowHeight(row, height); }