Menubar breaks cross platform menubar behavior conventions

Aperta
#1,372 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
1-2 giorni
Idoneità per principianti
22/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp
Ambito
desktop

Direzione di ricerca

The issue names no files or tests. Start by running the WinUI 3 Gallery app and reproducing the press-hold-drag-release on a menu bar or flyout, then find the menu bar sample in the gallery's C# and XAML code. The cause may sit in the WinUI framework rather than the gallery, which the issue does not identify. Done means a press, drag and release over a menu item activates it, and the maintainers have agreed where the fix belongs.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug
Which version of the app?

WinUI 3 Gallery

Description

Across different platforms you can operate menubars and dropdowns using a "drag-click" that is initiated by pressing down the primary mouse key over the button, keeping the primary mouse key pressed while going through the menus and releasing over the currently hovered/drag-clicked/selected action to activate it.[^1]

To boil it down, the steps below doesn't work anymore. This used to work with win32 top level menu items, but the behavior has regressed.

Steps to Reproduce

  1. Press down on your mouse on a top level menu item (File, Edit, View, Help)
  2. Keep holding down the mouse button
  3. The top level menu opens
  4. You move the cursor over the menu item you want to activate
  5. You release the mouse button

Examples of dropdowns and menubars supporting drag clicking:
Win32 menubars: http://sx.permik.xyz/macup/2023-10-07/04-26-55.mp4 (For some reason the Power Toys Mouse Highlighter gets hidden by the dialogs at ~27 secs)
macOS top level menubar
Android appbar actions, try to swipe downwards on the three vertical dots located on an app bar and keep your finger pressed, release to finish the action.
Web browsers using the <select> element (Safari, Firefox, regressed in Chromium since ???)

Yes, this regression also applies to the ComboBox element also, but I'll wait for feedback on this before making an another issue about that.

[^1]: Aside: This behavior works across OS's and is a delightful behavior that feels really good when it's implemented. Something about not needing to click a second time to act on a dropdown that I personally find really satisfying. This also gives the powerusers the ability to "flick" really fast through visual menus because of reducing the need to stop to click something.

Screenshots

No response

Windows version

Insider Build (xxxxx)

Additional context

Version 23H2 OS Build (25967.1000)
WinUI3 Gallery Version: 2.2.0.0

Lingua principale
C#
Stelle
3.7k
Fork
766
Merge medio
3g 10h
PR unite (30g)
7

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di microsoft/WinUI-Gallery

Tutte le issue di microsoft/WinUI-Gallery

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.