set the mask only when needed

override kwin shadow

svn path=/trunk/KDE/kdelibs/; revision=1099659
This commit is contained in:
Marco Martin 2010-03-05 22:36:20 +00:00
parent 270ffa55d5
commit 573438a9a8

View File

@ -222,6 +222,7 @@ void ToolTip::showEvent(QShowEvent *e)
checkSize();
QWidget::showEvent(e);
d->preview->setInfo();
WindowEffects::overrideShadow(winId(), true);
}
void ToolTip::hideEvent(QHideEvent *e)
@ -355,7 +356,11 @@ void ToolTip::resizeEvent(QResizeEvent *e)
{
QWidget::resizeEvent(e);
d->background->resizeFrame(size());
setMask(d->background->mask());
if (Plasma::Theme::defaultTheme()->windowTranslucencyEnabled()) {
clearMask();
} else {
setMask(d->background->mask());
}
d->preview->setInfo();
if (isVisible()) {