summaryrefslogtreecommitdiff
path: root/sfx2
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
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')
-rw-r--r--sfx2/source/appl/appcfg.cxx1
-rw-r--r--sfx2/source/control/bindings.cxx53
-rw-r--r--sfx2/source/control/dispatch.cxx1
-rw-r--r--sfx2/source/control/itemdel.cxx2
-rw-r--r--sfx2/source/dialog/dockwin.cxx1
5 files changed, 31 insertions, 27 deletions
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index b7e89dcd2de5..f0a87265eb82 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -110,6 +110,7 @@ SfxEventAsyncer_Impl::SfxEventAsyncer_Impl( const SfxEventHint& rHint )
pIdle.reset( new Idle("SfxEventASyncer") );
pIdle->SetIdleHdl( LINK(this, SfxEventAsyncer_Impl, IdleHdl) );
pIdle->SetPriority( SchedulerPriority::HIGHEST );
+ pIdle->SetDebugName( "sfx::SfxEventAsyncer_Impl pIdle" );
pIdle->Start();
}
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);
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index 93e5c778d8f2..49e7e5406459 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -452,6 +452,7 @@ void SfxDispatcher::Construct_Impl()
xImp->aIdle.SetPriority(SchedulerPriority::MEDIUM);
xImp->aIdle.SetIdleHdl( LINK(this, SfxDispatcher, EventHdl_Impl ) );
+ xImp->aIdle.SetDebugName( "sfx::SfxDispatcher_Impl aIdle" );
}
SfxDispatcher::SfxDispatcher()
diff --git a/sfx2/source/control/itemdel.cxx b/sfx2/source/control/itemdel.cxx
index a1d6478a45fd..c835b8c145d5 100644
--- a/sfx2/source/control/itemdel.cxx
+++ b/sfx2/source/control/itemdel.cxx
@@ -42,7 +42,7 @@ public:
SfxItemDisruptor_Impl::SfxItemDisruptor_Impl(SfxPoolItem *const pItemToDisrupt)
: pItem(pItemToDisrupt)
- , m_Idle("SfxItemDisruptor_Impl")
+ , m_Idle("sfx SfxItemDisruptor_Impl::Delete")
{
m_Idle.SetIdleHdl(LINK(this, SfxItemDisruptor_Impl, Delete));
m_Idle.SetPriority(SchedulerPriority::DEFAULT_IDLE);
diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx
index 16d71547ada1..6178bd0df75b 100644
--- a/sfx2/source/dialog/dockwin.cxx
+++ b/sfx2/source/dialog/dockwin.cxx
@@ -435,6 +435,7 @@ SfxDockingWindow_Impl::SfxDockingWindow_Impl(SfxDockingWindow* pBase)
{
aMoveIdle.SetPriority(SchedulerPriority::RESIZE);
aMoveIdle.SetIdleHdl(LINK(pBase,SfxDockingWindow,TimerHdl));
+ aMoveIdle.SetDebugName( "sfx::SfxDockingWindow_Impl aMoveIdle" );
}
/* [Description]