1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 19:03:08 +08:00

Add comment about padding update computation

This commit is contained in:
Dean Herbert 2020-04-23 12:47:57 +09:00
parent 49568a3d56
commit 2e022fbcb5

View File

@ -164,6 +164,8 @@ namespace osu.Game.Rulesets.Taiko.UI
{ {
base.Update(); base.Update();
// Padding is required to be updated for elements which are based on "absolute" X sized elements.
// This is basically allowing for correct alignment as relative pieces move around them.
rightArea.Padding = new MarginPadding { Left = leftArea.DrawWidth }; rightArea.Padding = new MarginPadding { Left = leftArea.DrawWidth };
hitTargetOffsetContent.Padding = new MarginPadding { Left = HitTarget.DrawWidth / 2 }; hitTargetOffsetContent.Padding = new MarginPadding { Left = HitTarget.DrawWidth / 2 };
} }