summaryrefslogtreecommitdiff
path: root/sfx2/source/control/bindings.cxx
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2016-07-20 10:54:30 +0200
committerJan-Marek Glogowski <glogow@fbihome.de>2017-01-17 16:08:46 +0100
commit9e51007039770370182839846676b205f5c34c57 (patch)
tree0f00a1fc0b26a39b9bbf33e413cfba6d93c7596c /sfx2/source/control/bindings.cxx
parent9235c5a3c2c7038b75606235859057f13824d5a1 (diff)
tdf#97087 GDB pretty print the Scheduler task list
In addition to the GDB pretty printer, this annotates a lot more Timers and Idles. Change-Id: I5b93fab02161b23bb753e65ef92643a04fb0789c
Diffstat (limited to 'sfx2/source/control/bindings.cxx')
-rw-r--r--sfx2/source/control/bindings.cxx53
1 files changed, 27 insertions, 26 deletions
diff --git a/sfx2/source/control/bindings.cxx b/sfx2/source/control/bindings.cxx
index e5f1d86db779..f1e5e334ab19 100644
--- a/sfx2/source/control/bindings.cxx
+++ b/sfx2/source/control/bindings.cxx
@@ -144,7 +144,7 @@ public:
bool bAllMsgDirty; // Has a MessageServer been invalidated?
bool bAllDirty; // After InvalidateAll
bool bCtrlReleased; // while EnterRegistrations
- AutoTimer aTimer; // for volatile Slots
+ AutoTimer aAutoTimer; // for volatile Slots
bool bInUpdate; // for Assertions
bool bInNextJob; // for Assertions
bool bFirstRound; // First round in Update
@@ -179,7 +179,8 @@ SfxBindings::SfxBindings()
// all caches are valid (no pending invalidate-job)
// create the list of caches
pImpl->pCaches = new SfxStateCacheArr_Impl;
- pImpl->aTimer.SetTimeoutHdl( LINK(this, SfxBindings, NextJob) );
+ pImpl->aAutoTimer.SetTimeoutHdl( LINK(this, SfxBindings, NextJob) );
+ pImpl->aAutoTimer.SetDebugName( "sfx::SfxBindings aAutoTimer" );
}
@@ -203,7 +204,7 @@ SfxBindings::~SfxBindings()
ENTERREGISTRATIONS();
- pImpl->aTimer.Stop();
+ pImpl->aAutoTimer.Stop();
DeleteControllers_Impl();
// Delete Caches
@@ -604,9 +605,9 @@ void SfxBindings::InvalidateAll
pImpl->nMsgPos = 0;
if ( !nRegLevel )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
}
}
@@ -655,9 +656,9 @@ void SfxBindings::Invalidate
pImpl->nMsgPos = 0;
if ( !nRegLevel )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
}
}
@@ -707,9 +708,9 @@ void SfxBindings::InvalidateShell
pImpl->nMsgPos = 0;
if ( !nRegLevel )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
pImpl->bFirstRound = true;
pImpl->nFirstShell = nLevel;
}
@@ -743,9 +744,9 @@ void SfxBindings::Invalidate
pImpl->nMsgPos = std::min(GetSlotPos(nId), pImpl->nMsgPos);
if ( !nRegLevel )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
}
}
}
@@ -779,9 +780,9 @@ void SfxBindings::Invalidate
pImpl->nMsgPos = std::min(GetSlotPos(nId), pImpl->nMsgPos);
if ( !nRegLevel )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
}
}
}
@@ -1449,7 +1450,7 @@ bool SfxBindings::NextJob_Impl(Timer * pTimer)
if ( Application::GetLastInputInterval() < MAX_INPUT_DELAY && pTimer )
{
- pImpl->aTimer.SetTimeout(TIMEOUT_UPDATING);
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_UPDATING);
return true;
}
@@ -1477,7 +1478,7 @@ bool SfxBindings::NextJob_Impl(Timer * pTimer)
}
pImpl->bAllDirty = false;
- pImpl->aTimer.SetTimeout(TIMEOUT_UPDATING);
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_UPDATING);
// at least 10 loops and further if more jobs are available but no input
bool bPreEmptive = pTimer && !pSfxApp->Get_Impl()->nInReschedule;
@@ -1525,7 +1526,7 @@ bool SfxBindings::NextJob_Impl(Timer * pTimer)
pImpl->nMsgPos = 0;
- pImpl->aTimer.Stop();
+ pImpl->aAutoTimer.Stop();
// Update round is finished
pImpl->bInNextJob = false;
@@ -1561,7 +1562,7 @@ sal_uInt16 SfxBindings::EnterRegistrations(const char *pFile, int nLine)
if ( ++nRegLevel == 1 )
{
// stop background-processing
- pImpl->aTimer.Stop();
+ pImpl->aAutoTimer.Stop();
// flush the cache
pImpl->nCachedFunc1 = 0;
@@ -1627,9 +1628,9 @@ void SfxBindings::LeaveRegistrations( const char *pFile, int nLine )
return;
if ( pImpl->pCaches && !pImpl->pCaches->empty() )
{
- pImpl->aTimer.Stop();
- pImpl->aTimer.SetTimeout(TIMEOUT_FIRST);
- pImpl->aTimer.Start();
+ pImpl->aAutoTimer.Stop();
+ pImpl->aAutoTimer.SetTimeout(TIMEOUT_FIRST);
+ pImpl->aAutoTimer.Start();
}
}
@@ -1722,7 +1723,7 @@ void SfxBindings::StartUpdate_Impl( bool bComplete )
if ( !bComplete )
// Update may be interrupted
- NextJob_Impl(&pImpl->aTimer);
+ NextJob_Impl(&pImpl->aAutoTimer);
else
// Update all slots in a row
NextJob_Impl(nullptr);