mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 02:36:34 +01:00
Port from deprecated QPalette::background() > QPalette::window()
Signed-off-by: Juraj Oravec <sgd.orava@gmail.com>
This commit is contained in:
parent
03b2880f8b
commit
14719b3ec3
@ -88,6 +88,6 @@ void WebScrollBar::performScroll()
|
||||
void WebScrollBar::paintEvent(QPaintEvent *ev)
|
||||
{
|
||||
QPainter painter(this);
|
||||
painter.fillRect(ev->rect(), palette().background());
|
||||
painter.fillRect(ev->rect(), palette().window());
|
||||
QScrollBar::paintEvent(ev);
|
||||
}
|
||||
|
@ -58,15 +58,13 @@ public:
|
||||
private:
|
||||
void paintEvent(QPaintEvent *ev) override
|
||||
{
|
||||
Q_UNUSED(ev)
|
||||
|
||||
QStyleOption option;
|
||||
option.initFrom(this);
|
||||
option.rect = rect();
|
||||
|
||||
QPainter p(this);
|
||||
if (mApp->styleName() == QL1S("breeze")) {
|
||||
p.fillRect(ev->rect(), option.palette.background());
|
||||
p.fillRect(ev->rect(), option.palette.window());
|
||||
} else {
|
||||
style()->drawPrimitive(QStyle::PE_PanelScrollAreaCorner, &option, &p, this);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user