Skip to content

#2379 Fix player table selection refresh#2393

Merged
wsbrenk merged 32 commits intoho-dev:masterfrom
wsbrenk:#2379
Jan 27, 2026
Merged

#2379 Fix player table selection refresh#2393
wsbrenk merged 32 commits intoho-dev:masterfrom
wsbrenk:#2379

Conversation

@wsbrenk
Copy link
Collaborator

@wsbrenk wsbrenk commented Jan 17, 2026

  1. changes proposed in this pull request:

The error was caused by a series of selection listeners that triggered each other. By using the central PlayersTable, selection is now controlled in a single place. This also gives us overarching synchronization of player selection in the Training and Player Overview modules.

  1. src/main/resources/release_notes.md ...
  • has been updated
  • does not require update

@wsbrenk wsbrenk requested a review from sgcr January 17, 2026 11:11
@sgcr sgcr added the type: bug has to be fixed before next stable release label Jan 17, 2026
@wsbrenk wsbrenk requested a review from sgcr January 27, 2026 17:46
Copy link
Collaborator

@sgcr sgcr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment for IllegalArgumentException.

addTableSelectionListeners();
RefreshManager.instance().registerRefreshable(this);
this.playerOverviewTable.addListSelectionListener(e -> selectPlayer());
this.playerOverviewTable.setRowSelectionInterval(0, 0);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got a IllegalArgumentException triggered from here when starting the application:

java.lang.IllegalArgumentException: Row index out of range
	at java.desktop/javax.swing.JTable.boundRow(JTable.java:2207)
	at java.desktop/javax.swing.JTable.setRowSelectionInterval(JTable.java:2230)
	at core.gui.comp.table.FixedColumnsTable.setRowSelectionInterval(FixedColumnsTable.kt:218)
	at module.playeroverview.PlayerOverviewPanel.<init>(PlayerOverviewPanel.java:39)
	at module.playeroverview.PlayerOverviewModule.createTabPanel(PlayerOverviewModule.java:28)
	at core.gui.comp.tabbedPane.HOTabbedPane.showTab(HOTabbedPane.java:38)
	at core.gui.HOMainFrame.initComponents(HOMainFrame.java:331)
	at core.gui.HOMainFrame.<init>(HOMainFrame.java:110)
	at core.gui.HOMainFrame.instance(HOMainFrame.java:169)
	at core.HO.lambda$main$1(HO.java:232)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:771)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:722)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:716)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:741)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - Pushed a fix.

Copy link
Collaborator

@sgcr sgcr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't forget to squash it all together. :-)

@wsbrenk wsbrenk merged commit 786df4a into ho-dev:master Jan 27, 2026
1 check passed
@wsbrenk wsbrenk deleted the #2379 branch January 31, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module: Squad type: bug has to be fixed before next stable release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Player Details did not refresh every time if switched with arrow keys between two players

3 participants