[PR #6854] [MERGED] Server list: Enter joins the selected server #7146

Closed
opened 2026-11-03 06:34:40 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/6854
Author: @MSedgeMC
Created: 11/2/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: fix/server-list-enter


📝 Commits (1)

  • f487821 Server list: Enter joins the selected server

📊 Changes

1 file changed (+47 additions, -1 deletions)

View changed files

📝 crates/horizon-client/src/multiplayer.rs (+47 -1)

📄 Description

Vanilla: in the multiplayer server list, ServerSelectionList.OnlineServerEntry.keyPressed joins the selected entry when the key is a selection key (Enter, keypad Enter, Space), the same path a click on the row's join half takes.

What Horizon got wrong: multiplayer::Screen::confirm only handled Direct (the typed address), so Enter on the server list returned Outcome::None and nothing happened. Screen::arrow already selected rows with the arrow keys and moved them with Shift, but the selected row could not be joined from the keyboard.

The fix routes a list's selected entry through the same entry_address lookup the row's join click uses, so a server and a LAN game both connect.

Proven: cargo test -q -p horizon-client-lib --lib multiplayer::tests::enter_joins_the_selected_server -> 1 passed; 0 failed; 1374 filtered out, covering no selection (nothing joins), the first row and the second row after Down. cargo clippy -q -p horizon-client-lib --lib -> clean. rustfmt --edition 2024 --check crates/horizon-client/src/multiplayer.rs -> clean.

Not proven: no in-game run. In-game check: open Multiplayer, arrow to a server, press Enter (and Space), and confirm it joins; also a LAN game row.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/6854 **Author:** [@MSedgeMC](https://github.com/MSedgeMC) **Created:** 11/2/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/server-list-enter` --- ### 📝 Commits (1) - [`f487821`](https://github.com/horizon-rust/horizon/commit/f487821effbec07c9c7c74b6225f55ec28f65b23) Server list: Enter joins the selected server ### 📊 Changes **1 file changed** (+47 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/multiplayer.rs` (+47 -1) </details> ### 📄 Description Vanilla: in the multiplayer server list, `ServerSelectionList.OnlineServerEntry.keyPressed` joins the selected entry when the key is a selection key (Enter, keypad Enter, Space), the same path a click on the row's join half takes. What Horizon got wrong: `multiplayer::Screen::confirm` only handled `Direct` (the typed address), so Enter on the server list returned `Outcome::None` and nothing happened. `Screen::arrow` already selected rows with the arrow keys and moved them with Shift, but the selected row could not be joined from the keyboard. The fix routes a list's selected entry through the same `entry_address` lookup the row's join click uses, so a server and a LAN game both connect. **Proven:** `cargo test -q -p horizon-client-lib --lib multiplayer::tests::enter_joins_the_selected_server` -> `1 passed; 0 failed; 1374 filtered out`, covering no selection (nothing joins), the first row and the second row after Down. `cargo clippy -q -p horizon-client-lib --lib` -> clean. `rustfmt --edition 2024 --check crates/horizon-client/src/multiplayer.rs` -> clean. **Not proven:** no in-game run. In-game check: open Multiplayer, arrow to a server, press Enter (and Space), and confirm it joins; also a LAN game row. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:34:40 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#7146
No description provided.