mirror of
https://github.com/KDE/latte-dock.git
synced 2025-03-21 22:50:14 +03:00
fix #444,use m_drawShadows for external shadows
This commit is contained in:
parent
7d3458d45c
commit
d1cb29b716
@ -780,7 +780,7 @@ void DockView::setBehaveAsPlasmaPanel(bool behavior)
|
||||
|
||||
m_behaveAsPlasmaPanel = behavior;
|
||||
|
||||
if (m_behaveAsPlasmaPanel) {
|
||||
if (m_behaveAsPlasmaPanel && m_drawShadows) {
|
||||
PanelShadows::self()->addWindow(this, enabledBorders());
|
||||
} else {
|
||||
PanelShadows::self()->removeWindow(this);
|
||||
@ -805,6 +805,14 @@ void DockView::setDrawShadows(bool draw)
|
||||
|
||||
m_drawShadows = draw;
|
||||
|
||||
if (m_behaveAsPlasmaPanel && m_drawShadows) {
|
||||
PanelShadows::self()->addWindow(this, enabledBorders());
|
||||
} else {
|
||||
PanelShadows::self()->removeWindow(this);
|
||||
m_enabledBorders = Plasma::FrameSvg::AllBorders;
|
||||
emit enabledBordersChanged();
|
||||
}
|
||||
|
||||
emit drawShadowsChanged();
|
||||
}
|
||||
|
||||
@ -1633,7 +1641,7 @@ void DockView::updateEnabledBorders()
|
||||
emit enabledBordersChanged();
|
||||
}
|
||||
|
||||
if (!m_behaveAsPlasmaPanel) {
|
||||
if (!m_behaveAsPlasmaPanel || !m_drawShadows) {
|
||||
PanelShadows::self()->removeWindow(this);
|
||||
} else {
|
||||
PanelShadows::self()->setEnabledBorders(this, borders);
|
||||
|
Loading…
x
Reference in New Issue
Block a user