Skip to content

rust-explorer: hover no longer selects rows (#230), date sort mixes folders and files, name new folders at once, Show in folder scrolls to the file - #245

Closed
cute-johnny wants to merge 2 commits into
Lemxy:mainfrom
cute-johnny:rust-explorer-sort-rename-hover

Conversation

@cute-johnny

@cute-johnny cute-johnny commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

Four small rust-explorer changes. Fixes #230.

  • Resting the pointer on a row no longer selects it ([Feature Request] Separate hover highlight from selection #230). The hover preview asks for WM_MOUSEHOVER on the list and passed it on to the list view. Once the list has been clicked, the list view selects the row under the pointer on that message, so every row the pointer rested on became the selection, for files and folders alike. The message is the preview's own request, so preview.rs now stops it there. The preview itself works as before.
  • Sorted by Date modified, folders and files are listed together, newest first. A new Sort by → Folders first by date too item (%APPDATA%\rust-explorer\date-folders-first) brings back folders on top for that column. The existing Folders first switch is unchanged.
  • New folder / New text file (menu and Ctrl+N) selects the new entry and opens its name box, as Explorer does, instead of leaving "New folder" to be renamed by hand.
  • Show in folder in a big folder scrolls to the file. When rust-explorer is started with /select (no window open yet), select_row ran in WM_CREATE while the list was still 0×0, so LVM_ENSUREVISIBLE was lost and the file sat out of view. The row is now selected from a posted message, after the window is shown and sized. The path for an already open window (shell_select) is unchanged.

Testing

  • cargo build --release with no warnings; cargo test --release in plugins/rust-explorer: 39 passed. (Built locally with the x86_64-pc-windows-gnu toolchain; CI builds MSVC.)
  • [Feature Request] Separate hover highlight from selection #230, before and after, on a real desktop with a real click and the real pointer: click row 1, then rest the pointer on rows 3, 5, 7, 9. v0.6.0: the selection follows the pointer (3, 5, 7, 9). This branch: it stays on row 1.
  • The sort, new-folder and Show in folder changes are covered by the build and the existing tests only; they have not been checked by hand yet.

🤖 Generated with Claude Code

cute-johnny and others added 2 commits November 28, 2026 18:18
…t once, /select scrolls to the file

- Sorted by Date modified, folders and files are listed together, newest is
  newest; "Folders first by date too" in Sort by brings back folders on top.
- New folder / New text file (menu and Ctrl+N) selects the new entry and
  opens its name box, as Explorer does.
- Started with /select (Show in folder when no window is open), the file is
  selected after the window has its size: scrolling a 0x0 list was lost, so
  in a big folder the selected file stayed out of view.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…xy#230)

The hover preview asks for WM_MOUSEHOVER on the list and passed it on to
the list view, which selects the row under the pointer on that message once
the list has been clicked: after one click, every row the pointer rested on
became the selection. The message is the preview's own request, so it now
stops there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@cute-johnny

Copy link
Copy Markdown
Contributor Author

Split into one PR per change so each can be reviewed and merged on its own: #247 (hover no longer selects rows, fixes #230), #248 (date sort lists folders and files together), #249 (new folder opens its name box), #250 (Show in folder scrolls to the file). The code is the same as here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Separate hover highlight from selection

1 participant