UIContext: Add an easy way to draw drop shadows under rectangular things

This commit is contained in:
Henrik Rydgård committed 2023-07-08 18:25:00 +02:00
1 parent f3d95a2cef
commit 0bf0a4a1ef
4 files changed
+18 -3

No files matched your search

+1 -3
View File
@@ -99,9 +99,7 @@ static void RenderNotice(UIContext &dc, Bounds bounds, float height1, NoticeLeve
uint32_t foreGround = whiteAlpha(alpha);
Bounds shadowBounds = bounds.Expand(10.0f);
dc.Draw()->DrawImage4Grid(dc.theme->dropShadow4Grid, shadowBounds.x, shadowBounds.y + 4.0f, shadowBounds.x2(), shadowBounds.y2(), alphaMul(0xFF000000, 0.9f * alpha), 1.0f);
dc.DrawRectDropShadow(bounds, 12.0f, 0.7f * alpha);
dc.FillRect(background, bounds);