Skip to content

Commit

Permalink
fix: repaint widget mask color when the color changed
Browse files Browse the repository at this point in the history
  • Loading branch information
zccrs committed May 8, 2019
1 parent 07eab80 commit 7553188
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/widgets/dblureffectwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,10 @@ void DBlurEffectWidgetPrivate::setMaskColor(const QColor &color)
if (isBehindWindowBlendMode()) {
maskColor.setAlpha(DWindowManagerHelper::instance()->hasBlurWindow() ? maskAlpha : MASK_COLOR_ALPHA_DEFAULT);
}

D_Q(DBlurEffectWidget);

q->update();
}

bool DBlurEffectWidgetPrivate::updateWindowBlurArea(QWidget *topLevelWidget)
Expand Down Expand Up @@ -609,8 +613,6 @@ void DBlurEffectWidget::setMaskAlpha(quint8 alpha) {

d->setMaskAlpha(alpha);

update();

Q_EMIT maskAlphaChanged(alpha);
}

Expand All @@ -628,7 +630,6 @@ void DBlurEffectWidget::setMaskColor(QColor maskColor)

d->maskColorType = CustomColor;
d->setMaskColor(maskColor);
update();

Q_EMIT maskColorChanged(maskColor);
}
Expand Down

0 comments on commit 7553188

Please sign in to comment.