[Libreoffice-commits] core.git: include/vcl vcl/source
Tobias Madl
tobias.madl.dev at gmail.com
Thu May 14 06:28:48 PDT 2015
include/vcl/scheduler.hxx | 1 +
vcl/source/app/scheduler.cxx | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
New commits:
commit b6044f76405cdf2a956d2c429d5d29f4c711363c
Author: Tobias Madl <tobias.madl.dev at gmail.com>
Date: Wed May 6 08:34:28 2015 +0000
Scheduler: Deactivate task without deletion
Now a task can be temporary deactivatet, without deletion.
Change-Id: Ie72f0fe0e1529e2216271a3ae73be1c406947dec
Reviewed-on: https://gerrit.libreoffice.org/15640
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/include/vcl/scheduler.hxx b/include/vcl/scheduler.hxx
index da3fb1f..5ce31e2 100644
--- a/include/vcl/scheduler.hxx
+++ b/include/vcl/scheduler.hxx
@@ -76,6 +76,7 @@ public:
virtual void Stop();
bool IsActive() const { return mbActive; }
+ void SetInActive() { mbActive = false; }
Scheduler& operator=( const Scheduler& rScheduler );
static void ImplDeInitScheduler();
diff --git a/vcl/source/app/scheduler.cxx b/vcl/source/app/scheduler.cxx
index a213fe2..20b11dc 100644
--- a/vcl/source/app/scheduler.cxx
+++ b/vcl/source/app/scheduler.cxx
@@ -47,7 +47,7 @@ ImplSchedulerData *ImplSchedulerData::GetMostImportantTask( bool bTimer )
for ( ImplSchedulerData *pSchedulerData = pSVData->mpFirstSchedulerData; pSchedulerData; pSchedulerData = pSchedulerData->mpNext )
{
if ( !pSchedulerData->mpScheduler || pSchedulerData->mbDelete || pSchedulerData->mnUpdateStack >= pSVData->mnUpdateStack
- || !pSchedulerData->mpScheduler->ReadyForSchedule( bTimer ) )
+ || !pSchedulerData->mpScheduler->ReadyForSchedule( bTimer ) || !pSchedulerData->mpScheduler->IsActive())
continue;
if (!pMostUrgent)
pMostUrgent = pSchedulerData;
More information about the Libreoffice-commits
mailing list