Commit Graph

354 Commits

Author SHA1 Message Date
fc7fc3d673 Fix newly imported beatmaps not using correct comparer for sorting 2022-08-01 19:13:57 +03:00
438067a18b Convert realm data propagation to more correctly use Live<T>
wip
2022-07-27 19:35:09 +09:00
41393616d8 Replace BeatmapCollection with RealmBeatmapCollection 2022-07-27 19:35:09 +09:00
9c543fef48 Remove CollectionManager 2022-07-27 18:45:33 +09:00
8f7dff5c2c Merge pull request #19378 from peppy/beatmap-update-test
Add separate beatmap update flow to handle edge cases better
2022-07-26 18:49:20 +09:00
a4f6f2b9eb Make item ID comparer static 2022-07-26 09:55:37 +03:00
8370ca9765 Add ImportAsUpdate method to IModelImporter to avoid otehr changes 2022-07-26 15:49:04 +09:00
693ac8750c Remove remaining uses of "child" terminology in non-drawable components 2022-07-26 09:43:47 +03:00
d7ef4170be Maintain sort stability by using carousel item ID as fallback 2022-07-26 09:40:41 +03:00
b7f6413bce Fix old version of beatmap potentially not being deleted during update flow
This can happen if the online IDs are not present in the `.osu` files.
Previously this was only working due to the early logic in the import
process (that relies on matching all online IDs perfectly).
2022-07-25 19:51:19 +09:00
3cfe624af1 Fix one more missed method with incorrect terminology 2022-07-21 16:16:41 +09:00
a05d7f4d8c Change carousel terminology to not use Children / InternalChildren 2022-07-21 16:06:06 +09:00
2b399ec7ad Merge branch 'master' into date-submitted-ranked 2022-07-20 18:36:57 +09:00
de29078db2 Remove nullable disables 2022-07-20 15:16:40 +09:00
30daa0fd44 Add ranked and submitted date storage and filtering 2022-07-19 19:55:56 +09:00
17046b0553 Add basic handling of download failures 2022-07-19 19:01:23 +09:00
a16bf35581 Rename button class and add basic progress display 2022-07-19 18:29:36 +09:00
da360af15a Fix vertical centering of button 2022-07-19 18:29:36 +09:00
eaf4f6dbb7 Add beatmap update button 2022-07-19 18:29:36 +09:00
102d0415f1 Merge branch 'master' into drawable-playlist-item-collection 2022-07-14 00:10:49 +03:00
fc274629f8 Add "last played" sort mode to song select
Note that this will consider the most recent play of any beatmap in
beatmap set groups for now, similar to other sort methods.
2022-07-13 16:43:43 +09:00
a94fb62be3 Split collection toggle menu item to own class 2022-07-08 01:39:45 +03:00
31a447fda0 Update parameter discards 2022-06-24 21:26:19 +09:00
30eebf3511 Merge branch 'master' into c-sharp-10 2022-06-24 21:22:33 +09:00
f71f6302fd Remove unnecessary null casts 2022-06-24 14:50:11 +09:00
28837693e5 Nuke calculating everything
The whole component is pointless so I'm just going to nuke for now I
guess. Kind of makes the whole refactor effort pointless but oh well?

To expand on this, the implementation was actually incorrect as pointed
out at https://github.com/ppy/osu/pull/18819#pullrequestreview-1017886035.
2022-06-24 14:24:06 +09:00
01da6f20b3 Tidy up all remaining usages 2022-06-23 19:27:35 +09:00
7dec530ca5 Split out simple DifficultyIcon with no calculation overhead and update usages 2022-06-23 19:27:35 +09:00
f8830c6850 Automated #nullable processing 2022-06-17 16:37:17 +09:00
4a5e86e451 Rename Beatmaps to BeatmapHashes for clarity 2022-06-10 14:03:51 +09:00
42cd7d9e6e Change CollectionManager to only store MD5 hashes instead of full BeatmapInfo 2022-06-08 18:23:09 +09:00
4b54fedd88 Add back hide common string using new ToSentence() extension method 2022-06-03 20:09:20 -07:00
999b4505d1 Remove localisation of "hide" string to fix incorrect case 2022-04-24 16:37:11 +09:00
5e5c8e78a6 Use existing web localisation for most hardcoded strings 2022-04-20 16:31:11 -07:00
e315313266 Split out IDialogOverlay to allow for easier testing 2022-04-18 18:36:26 +09:00
520d2d6cfa Fix beatmap carousel panels accepting input while marked as not-visible
This is an issue as carousel panels manage their own animated state. If
they are marked as not-visible (done at a higher level, from filtering
or update pathways) but clicked while fading out, they will animate back
to a visible state but not be marked as visible.

No tests for this one as it's probably not worthwhile to test (and hard
to do so). Manual testing can be done with the following patch:

```diff
diff --git a/osu.Game/Screens/Select/BeatmapCarousel.cs
b/osu.Game/Screens/Select/BeatmapCarousel.cs
index c3d340ac61..3372242acc 100644
--- a/osu.Game/Screens/Select/BeatmapCarousel.cs
+++ b/osu.Game/Screens/Select/BeatmapCarousel.cs
@@ -255,7 +255,7 @@ private void
beatmapSetsChanged(IRealmCollection<BeatmapSetInfo> sender, ChangeS
             }

             foreach (int i in changes.NewModifiedIndices)
-                UpdateBeatmapSet(sender[i].Detach());
+                Scheduler.AddDelayed(() =>
                 UpdateBeatmapSet(sender[i].Detach()), 100, true);

             foreach (int i in changes.InsertedIndices)
                 UpdateBeatmapSet(sender[i].Detach());

```

- Enter gameplay and adjust beatmap offset then return to song select
  and click the flashing panel.
OR
- Enter editor and save then return to song select and click the
  flashing panel.

Closes https://github.com/ppy/osu/discussions/17171.
2022-03-09 16:08:52 +09:00
da29947ecd Disallow interaction with carousel set difficulty icons unless selected
I kinda liked this flow, but from multiple reports from users it
definitely seems in the way. We can revisit after the new design is
applied to song select.

Note that this means the tooltips also don't display. If it is preferred
that they should (arguable from a UX perspective, since I'd expect to be
able to click at that point) then the issue can be addressed using a
slightly different path (a few more lines - nothing too complex).
2022-03-07 11:34:08 +09:00
6f0e32826c Standardise ordering/grouping of IRulesetInfo/RulesetInfos 2022-02-11 04:27:11 +03:00
eb25730b61 Revert "Merge pull request #16716 from peppy/carousel-less-invalidations"
This reverts commit 8d13e0514b, reversing
changes made to 95582a9023.
2022-02-05 16:12:58 +09:00
6bc6675fa1 Adjust fade in times slightly 2022-01-31 14:46:20 +09:00
8917ab78f4 Reduce unnecessary container nesting and adjust empty state opacity slightly 2022-01-31 14:46:20 +09:00
2ee0db0ebf Move fade in function local 2022-01-31 14:46:20 +09:00
c3e3b2019d Reduce overhead of ApplyState by tracking previous values
Even with pooling applied, there are overheads involved with transforms
when quickly cycling through the carousel.

The main goal here is to reduce the transforms in cases the reuse is
still in the same state. Avoiding firing `FadeIn` and `FadeOut` are the
main areas of saving.
2022-01-31 14:46:20 +09:00
a06287e76a Remove DrawableCarouselItem.Update updating of height
Marginal from a performance aspect, but reads better.
2022-01-31 14:46:20 +09:00
7af23328a4 Merge branch 'master' into ruleset-ordering-fix 2022-01-27 21:46:03 +09:00
3ae5973ab7 Fix compilation error due to commit split 2022-01-27 17:08:31 +09:00
5637fd64d6 Perform ordering using IComparable instead 2022-01-27 15:59:20 +09:00
5288eedd31 Update all usages of RulesetID and Ruleset.ID to use Ruleset.OnlineID 2022-01-27 15:38:03 +09:00
f30d63107a Add SortID to RulesetInfo to allow stable ordering of rulesets for display 2022-01-27 15:35:16 +09:00
f70e10e8a4 Fix ruleset filter matching using OnlineID instead of ShortName 2022-01-27 01:25:57 +09:00