Fixed extender appearence in dialogs of applets on the desktop.

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=875773
This commit is contained in:
Rob Scheepmaker 2008-10-25 14:49:31 +00:00
parent d09ca6858f
commit 08b16a80dc
2 changed files with 5 additions and 2 deletions

View File

@ -399,7 +399,8 @@ void ExtenderItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *opti
painter->setRenderHint(QPainter::TextAntialiasing, true);
painter->setRenderHint(QPainter::Antialiasing, true);
if (d->background->enabledBorders() != (PanelSvg::LeftBorder | PanelSvg::RightBorder)) {
if (d->background->enabledBorders() != (PanelSvg::LeftBorder | PanelSvg::RightBorder) &&
d->background->enabledBorders()) {
//Don't paint if only the left and right borders are enabled, we only use the left and right
//border in this situation to set the correct margins on this item.
d->background->paintPanel(painter, QPointF(0, 0));

View File

@ -242,7 +242,9 @@ void PopupAppletPrivate::popupConstraintsEvent(Plasma::Constraints constraints)
Extender *extender = qobject_cast<Extender*>(gWidget);
if (extender) {
if (q->location() == TopEdge) {
if (q->formFactor() == MediaCenter || q->formFactor() == Planar) {
extender->setExtenderAppearance(Extender::NoBorders);
} else if (q->location() == TopEdge) {
extender->setExtenderAppearance(Extender::TopDownStacked);
} else {
extender->setExtenderAppearance(Extender::BottomUpStacked);