1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-24 03:42:55 +08:00
Commit Graph

114 Commits

Author SHA1 Message Date
Dean Herbert
303961d101
Add drawable implementations of team logo 2025-02-14 17:39:21 +09:00
Bartłomiej Dach
a068d88b84
Merge pull request #31823 from peppy/carousel-v2-optimisation-pass
Refactor grouping to be much more efficient
2025-02-07 10:44:53 +01:00
Bartłomiej Dach
ae179c8feb
Merge pull request #31824 from peppy/carousel-v2-group-click-transfer-keyboard
Always transfer keyboard selection on activation
2025-02-07 10:12:10 +01:00
Dean Herbert
cf4b501214
Merge pull request #31804 from bdach/bss/api-setup
Add API request & response structures for beatmap submission
2025-02-07 17:43:38 +09:00
Dean Herbert
29b0b62ffa
Rename variables to something more sane 2025-02-07 17:39:38 +09:00
Dean Herbert
3da615481e
Change switch to simple conditional for now 2025-02-07 17:38:24 +09:00
Dean Herbert
41c8f64806
Simplify naming of endpoints 2025-02-07 17:33:32 +09:00
Dean Herbert
c935c3154b
Always transfer keyboard selection on activation 2025-02-07 17:02:53 +09:00
Dean Herbert
9d979dc3f4
Refactor grouping to be much more efficient 2025-02-07 16:35:20 +09:00
Dean Herbert
50d880e2ae
Fix unnecessary BeatmapSet.Metadata lookups 2025-02-07 16:09:36 +09:00
Dean Herbert
d73f275143
Don't inflate set / group panels for simplicity 2025-02-07 15:15:59 +09:00
Dean Herbert
1cf375e329
Merge branch 'master' into carousel-v2-spacing 2025-02-07 14:34:59 +09:00
Bartłomiej Dach
91bc23e39e
Merge pull request #31801 from peppy/carousel-v2-artist-grouping
Add support for grouping by artist to beatmap carousel v2
2025-02-06 13:13:35 +01:00
Dean Herbert
cb42ef95c5
Add invalidation on draw size change in beatmap carousel v2
Matching old implementation.
2025-02-06 17:48:42 +09:00
Dean Herbert
33035f0206
Merge branch 'master' into carousel-v2-spacing 2025-02-06 17:30:49 +09:00
Dean Herbert
f4bb3bc422
Merge pull request #31802 from frenzibyte/carousel-v2-depth-ordering
Allow ordering certain carousel panels behind others
2025-02-06 17:29:56 +09:00
Dean Herbert
bff686f012
Avoid double iteration when updating group states 2025-02-06 17:22:50 +09:00
Dean Herbert
024fbde0fd
Refactor selection and activation handling
I had a bit of a struggle getting header traversal logic to work well.
The constraints I had in place were a bit weird:

- Group panels should toggle or potentially fall into the prev/next
  group
- Set panels should just traverse around them

The current method of using `CheckValidForGroupSelection` return type
for traversal did not mesh with the above two cases. Just trust me on
this one since it's quite hard to explain in words.

After some re-thinking, I've gone with a simpler approach with one
important change to UX: Now when group traversing with a beatmap set
header currently keyboard focused, the first operation will be to reset
keyboard selection to the selected beatmap, rather than traverse.

I find this non-offensive – at most it means a user will need to press
their group traversal key one extra time.

I've also changed group headers to always toggle expansion when doing
group traversal with them selected.

To make all this work, the meaning of `Activation` has changed somewhat.
It is now the primary path for carousel implementations to change
selection of an item. It is what the `Drawable` panels call when they
are clicked.

Selection changes are not performed implicitly by `Carousel` – an
implementation should decide when it actually wants to change the
selection, usually in `HandleItemActivated`.

Having less things mutating `CurrentSelection` is better in my eyes, as
we see this variable as only being mutated internally when utmost
required (ie the user has requested the change). With this change,
`CurrentSelection` can no longer become of a non-`T` type (in the
beatmap carousel implementation at least).

This might pave a path forward for making `CurrentSelection` typed, but
that comes with a few other concerns so I'll look at that as a
follow-up.
2025-02-06 17:02:44 +09:00
Bartłomiej Dach
5bcd79956b
Merge branch 'master' into bss/api-setup 2025-02-06 08:30:01 +01:00
Dean Herbert
342a66b9e2
Fix keyboard traversal on a collapsed group not working as intended 2025-02-06 14:49:58 +09:00
Dean Herbert
88ad87a78e
Expose set grouping state 2025-02-06 14:30:15 +09:00
Dean Herbert
9cc90a51df
Adjust xmldoc and avoid LINQ overheads 2025-02-06 13:32:11 +09:00
Bartłomiej Dach
7d299bb2ad
Expose EndpointConfiguration directly in IAPIAccess 2025-02-05 13:31:37 +01:00
Dean Herbert
11de429621
Add support for grouping by artist 2025-02-05 19:48:41 +09:00
Salman Alshamrani
c370c75fe2 Allow ordering certain carousel panels behind others 2025-02-05 05:47:55 -05:00
Salman Alshamrani
c389dbc711 Extend panel input area to cover gaps 2025-02-05 05:20:26 -05:00
Salman Alshamrani
fc5832ce67 Support variable spacing between carousel items 2025-02-05 05:20:26 -05:00
Bartłomiej Dach
e5943e460d
Unify ConfigureAwait() calls across method 2025-02-05 10:28:42 +01:00
Bartłomiej Dach
c5deb9f36b
Use alternative lockless solution for atomic cancellation token recreation 2025-02-05 10:28:25 +01:00
Dean Herbert
5c9e84caf0
Add lock object 2025-02-05 17:31:54 +09:00
Dean Herbert
14273824dc
Fix Carousel.FilterAsync not working when called from a non-update thread
I was trying to be smart about things and make use of our
`SynchronisationContext` setup, but it turns out to not work in all
cases due to the context being missing depending on where you are
calling the method from.

For now let's prefer the "works everywhere" method of scheduling the
final work back to update.
2025-02-05 16:40:11 +09:00
Dean Herbert
599b59cb14
Add expanded state to sample drawable representations 2025-02-04 18:06:16 +09:00
Dean Herbert
58560f8acf
Add tracking of expansion states for groups and sets 2025-02-04 17:51:51 +09:00
Bartłomiej Dach
6e59cab928
Merge pull request #31764 from peppy/beatmap-carousel-v2-grouping
Add group support to beatmap carousel v2
2025-02-04 08:13:54 +01:00
Dean Herbert
e454fa558c
Adjust group traversal logic to handle cases where keyboard selection redirects 2025-02-04 02:55:59 +09:00
Dean Herbert
b433eef138
Remove redundant conditional check 2025-02-04 02:41:39 +09:00
Dean Herbert
c7780c9fdc
Refactor how grouping is performed 2025-02-03 20:40:52 +09:00
Salman Alshamrani
c587958f38 Apply depth ordering relative to selected item 2025-02-03 02:34:29 -05:00
Dean Herbert
6a18d18feb
Fix null handling when no items are populated but a selection is made 2025-02-03 02:39:45 +09:00
Dean Herbert
9c34819ff4
Add test coverage for grouped selection 2025-02-03 02:39:45 +09:00
Dean Herbert
645c26ca19
Simplify keyboard traversal logic 2025-02-03 02:24:27 +09:00
Dean Herbert
d74939e6e9
Fix backwards traversal of groupings and allow toggling groups without updating selection 2025-02-03 02:24:27 +09:00
Dean Herbert
764f799dcb
Improve selection flow using early exit and invalidation 2025-02-03 02:24:27 +09:00
Dean Herbert
d5dc55149d
Add initial difficulty grouping support 2025-02-03 02:24:27 +09:00
Dean Herbert
3cde11ab77
Re-enable masking by default 2025-02-03 02:24:26 +09:00
Bartłomiej Dach
55ab3c72f6
Remove unused field 2025-01-24 15:15:50 +01:00
Dean Herbert
82c5f37c2c
Remove selection animation on set panel 2025-01-24 22:45:08 +09:00
Dean Herbert
175eb82ccf
Split out beatmaps and set panels into two separate classes 2025-01-24 20:10:41 +09:00
Dean Herbert
0164a2e4dc
Move pool item preparation / cleanup duties to Carousel 2025-01-24 20:10:41 +09:00
Dean Herbert
9366bfbf0d
Move activation drawable flow portion to ICarouselPanel 2025-01-24 18:40:48 +09:00