win32 compile fix

svn path=/trunk/KDE/kdebase/apps/; revision=941223
This commit is contained in:
Ralf Habacker 2009-03-19 07:19:10 +00:00
parent d4f8439d91
commit 9a810d4df0

View file

@ -197,7 +197,11 @@ QRegion KToolTipDelegate::shapeMask(const KStyleOptionToolTip *option) const
bool KToolTipDelegate::haveAlphaChannel() const
{
#ifdef Q_WS_X11
return QX11Info::isCompositingManagerRunning();
#else
return false;
#endif
}
@ -226,9 +230,11 @@ private:
KTipLabel::KTipLabel() : QWidget(0, Qt::ToolTip)
{
#ifdef Q_WS_X11
if (QX11Info::isCompositingManagerRunning()) {
setAttribute(Qt::WA_TranslucentBackground);
}
#endif
}
void KTipLabel::showTip(const QPoint &pos, const KToolTipItem *item)
@ -254,10 +260,12 @@ void KTipLabel::paintEvent(QPaintEvent*)
KStyleOptionToolTip option = styleOption();
option.rect = rect();
#ifdef Q_WS_X11
if (QX11Info::isCompositingManagerRunning())
XShapeCombineRegion(x11Info().display(), winId(), ShapeInput, 0, 0,
delegate()->inputShape(&option).handle(), ShapeSet);
else
#endif
setMask(delegate()->shapeMask(&option));
QPainter p(this);