mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-23 18:32:49 +00:00
plasma: remove unused private methods
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
2b45ac1a73
commit
222c0282be
3 changed files with 1 additions and 30 deletions
|
@ -1065,32 +1065,6 @@ void IconWidgetPrivate::layoutTextItems(const QStyleOptionGraphicsItem *option,
|
|||
//kDebug() << "final position is" << labelLayout->position();
|
||||
}
|
||||
|
||||
QBrush IconWidgetPrivate::foregroundBrush(const QStyleOptionGraphicsItem *option) const
|
||||
{
|
||||
const QPalette::ColorGroup group = option->state & QStyle::State_Enabled ?
|
||||
QPalette::Normal : QPalette::Disabled;
|
||||
|
||||
// Always use the highlight color for selected items
|
||||
if (option->state & QStyle::State_Selected) {
|
||||
return option->palette.brush(group, QPalette::HighlightedText);
|
||||
}
|
||||
return option->palette.brush(group, QPalette::Text);
|
||||
}
|
||||
|
||||
QBrush IconWidgetPrivate::backgroundBrush(const QStyleOptionGraphicsItem *option) const
|
||||
{
|
||||
const QPalette::ColorGroup group = option->state & QStyle::State_Enabled ?
|
||||
QPalette::Normal : QPalette::Disabled;
|
||||
|
||||
QBrush background(Qt::NoBrush);
|
||||
|
||||
// Always use the highlight color for selected items
|
||||
if (option->state & QStyle::State_Selected) {
|
||||
background = option->palette.brush(group, QPalette::Highlight);
|
||||
}
|
||||
return background;
|
||||
}
|
||||
|
||||
void IconWidgetPrivate::drawTextItems(QPainter *painter,
|
||||
const QStyleOptionGraphicsItem *option,
|
||||
const QTextLayout &labelLayout,
|
||||
|
|
|
@ -153,9 +153,6 @@ public:
|
|||
|
||||
QSizeF displaySizeHint(const QStyleOptionGraphicsItem *option, const qreal width) const;
|
||||
|
||||
QBrush foregroundBrush(const QStyleOptionGraphicsItem *option) const;
|
||||
QBrush backgroundBrush(const QStyleOptionGraphicsItem *option) const;
|
||||
|
||||
QString elidedText(QTextLayout &layout,
|
||||
const QSizeF &maxSize) const;
|
||||
|
||||
|
|
|
@ -95,7 +95,7 @@ Label::Label(QGraphicsWidget *parent)
|
|||
: QGraphicsProxyWidget(parent),
|
||||
d(new LabelPrivate(this))
|
||||
{
|
||||
QLabel *native = new QLabel;
|
||||
QLabel *native = new QLabel();
|
||||
|
||||
native->setWindowFlags(native->windowFlags()|Qt::BypassGraphicsProxyWidget);
|
||||
native->setAttribute(Qt::WA_NoSystemBackground);
|
||||
|
|
Loading…
Add table
Reference in a new issue