Commit Graph

2557 Commits

Author SHA1 Message Date
6eb2c28e41 Rename RealmContextFactory to RealmAccess 2022-01-24 20:38:07 +09:00
c3758047fd Don't include nested hit objects' DifficultyControLPoints in legacy encoder logic
The editor doesn't currently propagate velocity to nested objects. We're
not yet sure whether it should or not. For now, let's just ignore nested
objects' `DifficultyControlPoints` for simplicity.

Note that this only affects osu! ruleset due to the pre-check on
`isOsuRuleset`.
2022-01-24 19:54:08 +09:00
d7db6fa918 Merge branch 'master' into custom-meter 2022-01-24 15:46:44 +09:00
838a9f69ed Fix saved beatmap filename depending on ToString() implementation 2022-01-23 20:28:30 +01:00
4e5a1f27a8 Initialise Simple{Triple,Quadruple} only once ever rather than create every time 2022-01-23 15:21:25 +01:00
735414bc49 Replace TimeSignatures enum with struct for storage of arbitrary meter 2022-01-22 20:50:31 +01:00
495636538f Add forced refresh on GetAllUsableBeatmapSets()
This is commonly used in tests in a way where it's not feasible to
guarantee correct results unless a refresh is called. This method
shouldn't really be used outside of tests anyway, but that's for a
folow-up effort.
2022-01-21 17:33:29 +09:00
114c9e8c1f Update all usages of CreateContext to use either Run or Write 2022-01-21 17:27:08 +09:00
a5d2047f05 Fix various cases of creating realm contexts from update thread when not necessary 2022-01-21 01:44:56 +09:00
6c10531df2 Avoid constructor overhead for realm BeatmapMetadata parameterless constructor 2022-01-20 17:14:51 +09:00
deb108816c Fix some regressions in json output (we need to make all these explicit instead) 2022-01-20 17:09:31 +09:00
ccddf9b47d Avoid constructor overhead for realm BeatmapSetInfo parameterless constructor 2022-01-20 17:03:44 +09:00
3faf980fed Avoid constructor overhead for realm BeatmapInfo parameterless constructor 2022-01-20 16:47:27 +09:00
247c557eaf Fix expanded content scrollbar inadvertently hiding expanded content 2022-01-19 22:30:49 +01:00
77748a5f93 Show scrollbar on expanded card content where applicable 2022-01-19 22:21:08 +01:00
3e5d29ed00 Merge pull request #16505 from peppy/remove-base-difficulty-usage
Remove all usage of `BaseDifficulty` (and access `Difficulty` instead)
2022-01-19 13:53:55 +09:00
2556f1cb87 Merge branch 'master' into optimise-set-detach-part-2 2022-01-19 13:20:38 +09:00
2363130f8b Add back BaseDifficulty with obsoletion counter to account for custom rulesets 2022-01-19 12:33:56 +09:00
60b80c88b6 Avoid file retrieval overhead when detaching BeatmapSetInfo
It seems that no usages of `BeatmapSetInfo` detaches require files - a
`WorkingBeatmap` is always obtained before doing further lookups.

Therefore we can omit this include unless the detaching object is a
`BeatmapInfo`. A refetch is performed when retrieving a
`WorkingBeatmap` to complete the equation.
2022-01-19 00:49:18 +09:00
67bf95bc91 Remove all usage of AuthorString 2022-01-18 23:30:40 +09:00
3596c6ed5d Add some missing IgnoredAttributes to reduce automapper overhead 2022-01-18 23:25:30 +09:00
7f65f3a47f Remove all usage of BaseDifficulty (and access Difficulty instead) 2022-01-18 22:57:39 +09:00
9a43ed742b Update automapper spec in line with v11
See https://docs.automapper.org/en/latest/11.0-Upgrade-Guide.html for
 more details.
2022-01-18 15:23:28 +09:00
381174e482 Give the placeholder ruleset better defaults to allow tests to work again 2022-01-17 14:40:00 +09:00
744084b418 Initialise all parameters is paramaterless constructor for now for added safety 2022-01-17 13:51:30 +09:00
e75d21507c Fix GetDisplayTitleRomanisable() relying on ToString() implementation 2022-01-15 15:26:41 +01:00
dea2e1fac0 Return immediately on failed web request in synchronous BeatmapOnlineLookupQueue flow 2022-01-14 13:20:51 +09:00
8424d86e9a Remove unused cancellationToken parameter in synchronous BeatmapOnlineLookupQueue flow 2022-01-14 13:19:00 +09:00
9b33fbbee5 Ensure detached when performing model Clone operations on BeatmapInfo/ScoreInfo 2022-01-14 13:08:20 +09:00
b610d2db12 Add EF to realm beatmap migration 2022-01-13 18:23:18 +09:00
069d6d2954 Remove pointless compatibility parameter BeatmapSetInfoID 2022-01-13 18:02:10 +09:00
93c78253d6 Add synchronous fetch flow to BeatmapOnlineLookupQueue
The async flow doesn't work great with the realm import process. We
might be able to improve on this going forward, but for the time being
adding a synchronous path seems safest.

After all, we are already an an asynchronous (dedicated) thread pool at
this point.
2022-01-13 16:36:54 +09:00
b77cb344d5 Use ctor rather than MemberwiseClone to guarantee a safer clone of BeatmapDifficulty 2022-01-13 13:23:41 +09:00
86b2ac3217 Remove unnecessary Ruleset null check in BeatmapDifficultyCache 2022-01-13 13:19:49 +09:00
eb70a1eeb7 Replace compatibility properties with direct references 2022-01-12 18:13:14 +09:00
34aa1bf21d Sanitise and remove some usages of Detach which are no longer required 2022-01-12 17:49:11 +09:00
5f7365e8f3 Ensure scores are cleaned up alongside beatmap so they don't have a null reference 2022-01-12 17:49:11 +09:00
f24b2b1be3 Make copying detached changes to realm only exposed for BeatmapSet
Also fixes remaining issues with the copy process.
2022-01-12 17:49:11 +09:00
a4de0f93fa Move manager Update methods to be explicit to where they are still used by legacy code
Also fixes skin hash repopulation being completely broken.
2022-01-12 17:49:11 +09:00
51d6db1bca Add equatable support to IUser and RealmUser
Not sure this will stick, but let's add it for now to make testing
detach support work nicely.
2022-01-12 17:49:11 +09:00
157dfdaa82 Fix protected beatmap sets getting deleted 2022-01-12 17:49:11 +09:00
72656ae01e Fix beatmap restore/undelete flows 2022-01-12 17:49:11 +09:00
46206f70d6 Fix beatmap mass deletion flow 2022-01-12 17:49:11 +09:00
d5239d550a Add refetch for non-managed hide/restore attempts 2022-01-12 17:49:11 +09:00
46e92c3b60 Clean up BeatmapManager query methods 2022-01-12 17:49:11 +09:00
9beabad6a4 Remove hide/restore event flow 2022-01-12 17:49:11 +09:00
c06b5951fd Fix multiple remaining warnings 2022-01-12 17:49:11 +09:00
7509a9ff8f Update BeatmapModelManager.Save to work for editor scenarios 2022-01-12 17:49:11 +09:00
8c3dc4333d Fix incorrect realm access after new beatmap import 2022-01-12 17:49:11 +09:00
2ce80cc030 Add back caching in WorkingBeatmapCache 2022-01-12 17:49:11 +09:00