Prefer inner scopes
Don't request data until we're going to use it. Don't emit about config changes if config doesn't change
This commit is contained in:
parent
0dba9044bf
commit
596dc7523d
@ -563,13 +563,13 @@ void Containment::reactToScreenChange()
|
||||
{
|
||||
int newScreen = screen();
|
||||
|
||||
KConfigGroup c = config();
|
||||
if (newScreen >= 0) {
|
||||
d->lastScreen = newScreen;
|
||||
KConfigGroup c = config();
|
||||
c.writeEntry("lastScreen", d->lastScreen);
|
||||
emit configNeedsSaving();
|
||||
}
|
||||
|
||||
emit configNeedsSaving();
|
||||
emit screenChanged(newScreen);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user