From: Fabian Stemmler Date: Sat, 12 Oct 2019 11:16:30 +0000 (+0200) Subject: Fixed an IndexOutOfBoundsException X-Git-Url: https://mograsim.net/gitweb/?p=Mograsim.git;a=commitdiff_plain;h=7d64b694e4d70335e957f80c3b46c5b1c3a9c30a Fixed an IndexOutOfBoundsException --- diff --git a/plugins/net.mograsim.plugin.core/src/net/mograsim/plugin/tables/mi/RowHighlighter.java b/plugins/net.mograsim.plugin.core/src/net/mograsim/plugin/tables/mi/RowHighlighter.java index e7435a20..3b1aa038 100644 --- a/plugins/net.mograsim.plugin.core/src/net/mograsim/plugin/tables/mi/RowHighlighter.java +++ b/plugins/net.mograsim.plugin.core/src/net/mograsim/plugin/tables/mi/RowHighlighter.java @@ -35,7 +35,7 @@ public class RowHighlighter cProv.highlight(row); if (row != -1) { - table.showItem(table.getItem(Math.min(table.getItemCount(), row + 2))); + table.showItem(table.getItem(Math.min(table.getItemCount() - 1, row + 2))); table.showItem(table.getItem(row)); Optional.ofNullable(table.getItem(row).getData()).ifPresent(d -> viewer.update(d, null)); }