Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
KMail
Commits
199dfee4
Commit
199dfee4
authored
Apr 03, 2022
by
Laurent Montel
Browse files
Update color when we change theme
parent
02d60acd
Pipeline
#158886
passed with stage
in 4 minutes and 55 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/kontactplugin/summary/summaryview_part.cpp
View file @
199dfee4
...
...
@@ -428,8 +428,9 @@ void SummaryViewPart::initGUI(KontactInterface::Core *core)
mMainWidget
->
setFocusPolicy
(
Qt
::
StrongFocus
);
setWidget
(
sa
);
// KF5: port it
// connect(KGlobalSettings::self(), &KGlobalSettings::kdisplayPaletteChanged, this, &SummaryViewPart::slotAdjustPalette);
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
connect
(
qApp
,
&
QApplication
::
paletteChanged
,
this
,
&
SummaryViewPart
::
slotAdjustPalette
);
#endif
slotAdjustPalette
();
mMainLayout
=
new
QVBoxLayout
(
mMainWidget
);
...
...
@@ -506,3 +507,13 @@ QString SummaryViewPart::widgetName(QWidget *widget) const
return
{};
}
bool
SummaryViewPart
::
event
(
QEvent
*
e
)
{
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
if
(
e
->
type
()
==
QEvent
::
ApplicationPaletteChange
)
{
slotAdjustPalette
();
}
#endif
return
KParts
::
Part
::
event
(
e
);
}
src/kontactplugin/summary/summaryview_part.h
View file @
199dfee4
...
...
@@ -49,6 +49,7 @@ Q_SIGNALS:
protected:
void
partActivateEvent
(
KParts
::
PartActivateEvent
*
event
)
override
;
bool
event
(
QEvent
*
e
)
override
;
protected
Q_SLOTS
:
void
slotConfigure
();
void
updateWidgets
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment