Set the '_notifiedActivity' flag early

This way anyone listening to 'activity' signals can safely re-set the flag to
'false' by calling setMonitorActivity(true) again. Right now this is not
guaranteed as the signal is handled asynchonously (and indeed in my PyQT-based
application the signal would be handled *before* the flag is set to 'true'...)
This commit is contained in:
Arnout Engelen
2014-12-07 18:15:14 +01:00
parent 3ce99c7450
commit 2ec7abf56e
+1 -1
View File
@@ -469,8 +469,8 @@ void Session::activityStateSet(int state)
if ( _monitorActivity ) {
//FIXME: See comments in Session::monitorTimerDone()
if (!_notifiedActivity) {
emit activity();
_notifiedActivity=true;
emit activity();
}
}
}