summaryrefslogtreecommitdiff
path: root/src/ui/widget.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/widget.c')
-rw-r--r--src/ui/widget.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/ui/widget.c b/src/ui/widget.c
index c1b95130..2bdda691 100644
--- a/src/ui/widget.c
+++ b/src/ui/widget.c
@@ -681,6 +681,26 @@ void drawBackground_Widget(const iWidget *d) {
681 iRect rect = bounds_Widget(d); 681 iRect rect = bounds_Widget(d);
682 iPaint p; 682 iPaint p;
683 init_Paint(&p); 683 init_Paint(&p);
684 if (d->flags & mouseModal_WidgetFlag) {
685 p.alpha = 128;
686 SDL_SetRenderDrawBlendMode(renderer_Window(get_Window()), SDL_BLENDMODE_BLEND);
687 int fadeColor;
688 switch (colorTheme_App()) {
689 default:
690 fadeColor = black_ColorId;
691 break;
692 case light_ColorTheme:
693 fadeColor = gray25_ColorId;
694 break;
695 case pureWhite_ColorTheme:
696 fadeColor = gray50_ColorId;
697 break;
698 }
699 fillRect_Paint(&p,
700 initCorners_Rect(zero_I2(), rootSize_Window(get_Window())),
701 fadeColor);
702 SDL_SetRenderDrawBlendMode(renderer_Window(get_Window()), SDL_BLENDMODE_NONE);
703 }
684 if (d->bgColor >= 0) { 704 if (d->bgColor >= 0) {
685#if defined (iPlatformAppleMobile) 705#if defined (iPlatformAppleMobile)
686 if (d->flags & (drawBackgroundToHorizontalSafeArea_WidgetFlag | 706 if (d->flags & (drawBackgroundToHorizontalSafeArea_WidgetFlag |