1
0
mirror of https://github.com/KDE/latte-dock.git synced 2025-03-23 02:50:12 +03:00

fix #634,load the dockWin flag after copy

This commit is contained in:
Michail Vourlakos 2017-07-29 23:07:00 +03:00
parent 6833406509
commit c154eae4c7
2 changed files with 5 additions and 4 deletions

View File

@ -68,7 +68,6 @@ DockView::DockView(Plasma::Corona *corona, QScreen *targetScreen, bool dockWindo
| Qt::NoDropShadowWindowHint
| Qt::WindowDoesNotAcceptFocus;
if (dockWindowBehavior) {
setFlags(flags);
} else {
@ -83,7 +82,7 @@ DockView::DockView(Plasma::Corona *corona, QScreen *targetScreen, bool dockWindo
setScreenToFollow(qGuiApp->primaryScreen());
connect(this, &DockView::containmentChanged
, this, [&]() {
, this, [ &, dockWindowBehavior]() {
qDebug() << "dock view c++ containment changed 1...";
if (!this->containment())
@ -91,6 +90,8 @@ DockView::DockView(Plasma::Corona *corona, QScreen *targetScreen, bool dockWindo
qDebug() << "dock view c++ containment changed 2...";
setDockWinBehavior(dockWindowBehavior);
restoreConfig();
reconsiderScreen();
@ -1958,7 +1959,7 @@ void DockView::saveConfig()
auto config = this->containment()->config();
config.writeEntry("onPrimary", m_onPrimary);
config.writeEntry("dockWindowBehavior", m_dockWinBehavior);
emit this->containment()->configNeedsSaving();
config.sync();
}
void DockView::restoreConfig()

View File

@ -255,7 +255,7 @@ private:
bool m_behaveAsPlasmaPanel{false};
bool m_forceDrawCenteredBorders{false};
bool m_dockWinBehavior{false};
bool m_dockWinBehavior{true};
bool m_drawShadows{true};
bool m_drawEffects{false};
bool m_inDelete{false};