1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 18:07:24 +08:00
Commit Graph

21617 Commits

Author SHA1 Message Date
Bartłomiej Dach
a8f16503e2 Add backslash escaping to new link format
For users to be able to add square brackets inside of links using
the new format, the regular expression used for parsing those links
contained a balancing group, which can be used for matching pairs
of tokens (in this case, opening and closing brackets, in that order).
However, this means that users could not post links with unmatched
brackets inside of them (ie. ones that contain single brackets, or
a closing bracket and then an opening one). Allow for escaping opening
and closing brackets using the backslash character.

The change substitutes this old fragment of the regex in the display
text group:

    [^\[\]]*        // any character other than closing/opening bracket

for this one:

    (((?<=\\)[\[\]])|[^\[\]])*

The second pattern in the alternative remains the same; the first one
performs the escaping, as follows:

    (
        (?<=\\)     // positive lookbehind expression:
                    // this match will succeed, if the next expression
                    // is preceded by a single backslash
        [\[\]]      // either an opening or closing brace
    )

Since the entire display group is matched, unfortunately the lookbehind
expression does not actually strip the backslashes, so they are
manually stripped in handleMatches.

As demonstrated in the unit tests attached, this also allows balanced
brackets to be mixed with escaped ones.
2019-09-03 23:18:39 +02:00
Dean Herbert
8d52d282e9
Merge pull request #5928 from bdach/consistent-mod-button-sounds
Fix inconsistent sound effects on mod buttons

Co-authored-by: Dean Herbert <pe@ppy.sh>
2019-09-03 19:42:21 +09:00
Dean Herbert
e98059267d Improve xmldoc 2019-09-03 19:21:24 +09:00
Dean Herbert
299d528654 Simplify implementation 2019-09-03 19:20:23 +09:00
Dean Herbert
e88965b433 Merge remote-tracking branch 'upstream/master' into consistent-mod-button-sounds 2019-09-03 19:18:59 +09:00
Dean Herbert
609adf4b59
Fix catch catcher lookups (#5964)
Fix catch catcher lookups

Co-authored-by: null <27856297+dependabot-preview[bot]@users.noreply.github.com>
2019-09-03 19:08:49 +09:00
Dean Herbert
312e12e3b4
Add spacing to difficulty icons on direct panels (#5957)
Add spacing to difficulty icons on direct panels
2019-09-03 18:44:58 +09:00
Dean Herbert
858828d4ef Merge remote-tracking branch 'upstream/dependabot/nuget/ppy.osu.Game.Resources-2019.903.1' into fix-catch-catcher 2019-09-03 18:31:19 +09:00
dependabot-preview[bot]
352fd3efda
Bump ppy.osu.Game.Resources from 2019.903.0 to 2019.903.1
Bumps [ppy.osu.Game.Resources](https://github.com/ppy/osu-resources) from 2019.903.0 to 2019.903.1.
- [Release notes](https://github.com/ppy/osu-resources/releases)
- [Commits](https://github.com/ppy/osu-resources/compare/2019.903.0...2019.903.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 09:18:24 +00:00
Dean Herbert
976f5020c0
Fix ring glow lookup being incorrect (#5963)
Fix ring glow lookup being incorrect

Co-authored-by: Dan Balasescu <smoogipoo@smgi.me>
2019-09-03 16:31:12 +09:00
Dan Balasescu
3854bc68e0
Merge branch 'master' into fix-ring-glow-lookup 2019-09-03 16:14:07 +09:00
Dan Balasescu
953ea83cb6
Merge pull request #5956 from Joehuu/center-icon-and-text-correctly
Center icon and text using anchor and origin instead of margin
2019-09-03 15:30:12 +09:00
Dan Balasescu
b7f1efbf38
Merge branch 'master' into center-icon-and-text-correctly 2019-09-03 14:51:59 +09:00
Dean Herbert
d1cdf49dd5 Revert SkinnableSprite lookups to old behaviour 2019-09-03 14:21:54 +09:00
Dean Herbert
10862f40c6
Don't display hit errors for non-timed hitobjects (#5952)
Don't display hit errors for non-timed hitobjects

Co-authored-by: Dean Herbert <pe@ppy.sh>
2019-09-03 13:29:35 +09:00
Dean Herbert
05ed9d3802 Merge remote-tracking branch 'upstream/master' into non-timeoffset-judgements 2019-09-03 13:07:58 +09:00
Dean Herbert
4cad55cee6 Move hit windows lookup to DrawableRuleset 2019-09-03 13:05:03 +09:00
Dean Herbert
4f3511e8e9 Fix ring glow lookup being incorrect 2019-09-03 12:32:10 +09:00
Dan Balasescu
93c3e5a072
Merge pull request #5893 from peppy/play-to-gameplay
Rename "play" resources to "gameplay"
2019-09-03 12:26:42 +09:00
Dean Herbert
de2d3121f7 Merge remote-tracking branch 'upstream/dependabot/nuget/ppy.osu.Game.Resources-2019.903.0' into play-to-gameplay 2019-09-03 12:06:10 +09:00
dependabot-preview[bot]
11dfdc33d5
Bump ppy.osu.Game.Resources from 2019.830.0 to 2019.903.0
Bumps [ppy.osu.Game.Resources](https://github.com/ppy/osu-resources) from 2019.830.0 to 2019.903.0.
- [Release notes](https://github.com/ppy/osu-resources/releases)
- [Commits](https://github.com/ppy/osu-resources/compare/2019.830.0...2019.903.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 03:05:45 +00:00
Dean Herbert
444419b2e6 Update resources 2019-09-03 12:04:49 +09:00
Dean Herbert
4a8bdbd014 Merge remote-tracking branch 'upstream/master' into play-to-gameplay 2019-09-03 12:04:46 +09:00
Dan Balasescu
6a3f210766
Merge pull request #5961 from jorolf/background-beat
Add a 60bpm beat when no beatmap is playing
2019-09-03 11:49:19 +09:00
Dean Herbert
0261456d5a
Merge branch 'master' into play-to-gameplay 2019-09-03 11:42:15 +09:00
smoogipoo
eab06995d0 Add some whitespace 2019-09-03 11:37:56 +09:00
smoogipoo
ec8726e163 Merge remote-tracking branch 'origin/master' into background-beat 2019-09-03 11:35:20 +09:00
Dan Balasescu
97b824d7d2
Merge pull request #5892 from peppy/iskincomponent
Introduce the concept of SkinComponents
2019-09-03 11:31:36 +09:00
jorolf
3b769128a8 Add a 60bpm beat when no beatmap is playing 2019-09-03 00:57:29 +02:00
Joehu
ce446826e8 Match web's max diff icon number 2019-09-02 11:00:12 -07:00
Joehu
5d3f3b7cc2 Add spacing to diff icons on direct panels 2019-09-02 10:59:43 -07:00
Joehu
6ca17bdfd5 Center icon and text using anchor and origin instead of margin 2019-09-02 10:42:21 -07:00
Bartłomiej Dach
53c254c6a5 Replace Array.IndexOf() with Contains() 2019-09-02 19:01:36 +02:00
Dean Herbert
09097f7680
Merge branch 'master' into iskincomponent 2019-09-02 22:38:57 +09:00
Dean Herbert
3443a9517f
Merge pull request #5953 from peppy/fix-direct-panel-unbind-nullref
Fix potential null reference on DirectPanel unbind
2019-09-02 21:35:17 +09:00
Dean Herbert
d688aee258
Add other sample functions to SkinnableSound (#5728)
Add other sample functions to SkinnableSound

Co-authored-by: Dean Herbert <pe@ppy.sh>
2019-09-02 19:14:45 +09:00
Dean Herbert
0ee0184e01 Remove unnecessary usings 2019-09-02 19:13:06 +09:00
Dean Herbert
1e7528c2b3 Merge remote-tracking branch 'upstream/master' into non-timeoffset-judgements 2019-09-02 19:13:00 +09:00
Dean Herbert
b460f76fa6 Adjust file spacing slightly 2019-09-02 19:01:43 +09:00
Dean Herbert
0bfe4650c3 Early return if no change occurred in looping value 2019-09-02 19:01:17 +09:00
smoogipoo
90671e0617 Attempt to not break per-hitobject hitwindows 2019-09-02 18:58:13 +09:00
smoogipoo
8302658186 Fix other potential nullref cases that rider missed 2019-09-02 18:31:33 +09:00
Dean Herbert
f08b523abf Name tuple items 2019-09-02 18:20:30 +09:00
Dean Herbert
9c53430a0f Only initialise when required 2019-09-02 18:18:59 +09:00
Dean Herbert
eaeecfb300 Merge remote-tracking branch 'upstream/master' into add-adjustment-function-for-skinnable-sound 2019-09-02 18:15:17 +09:00
smoogipoo
f20e07136a Add attribute to catch potential future nullrefs 2019-09-02 17:48:41 +09:00
smoogipoo
4c150839c0 Fix potential diffcalc hitwindow nullref 2019-09-02 17:38:58 +09:00
Dean Herbert
6009cd2537
Fix OsuLegacySkin fallback logic being incorrect (#5948)
Fix OsuLegacySkin fallback logic being incorrect

Co-authored-by: Dan Balasescu <smoogipoo@smgi.me>
2019-09-02 17:23:18 +09:00
Dean Herbert
be5baef386
Merge pull request #5778 from EVAST9919/kudosu-info
Add kudosu history to UserProfileOverlay
2019-09-02 17:22:53 +09:00
Dan Balasescu
7e0e4d9fbc
Merge branch 'master' into fix-config-fallback-logic 2019-09-02 17:20:26 +09:00