ViewShell::Implementation::~Implementation() COVERITY_NOEXCEPT_FALSE
{ if ( ! mpUpdateLockForMouse.expired())
{
std::shared_ptr<ToolBarManagerLock> pLock(mpUpdateLockForMouse); if (pLock != nullptr)
{ // Force the ToolBarManagerLock to be released even when the // IsUICaptured() returns <TRUE/>.
pLock->Release(true);
}
}
}
// Clear the selection because the selected object may be removed as // a result of the assignment of the layout.
mrViewShell.GetDrawView()->UnmarkAll();
if (!bHandoutMode)
{ if (pCurrentPage->GetName() != aNewName)
{
pCurrentPage->SetName(aNewName);
// Transform the given request into the four argument form that is // understood by ProcessModifyPageSlot().
SdrLayerAdmin& rLayerAdmin (mrViewShell.GetViewShellBase().GetDocument()->GetLayerAdmin());
SdrLayerID aBackground (rLayerAdmin.GetLayerID(sUNO_LayerName_background));
SdrLayerID aBackgroundObject (rLayerAdmin.GetLayerID(sUNO_LayerName_background_objects));
// Forward the call with the new arguments.
ProcessModifyPageSlot( aRequest, pPage, pPage->GetPageKind());
}
SfxInterfaceId ViewShell::Implementation::GetViewId() const
{ switch (mrViewShell.GetShellType())
{ case ViewShell::ST_IMPRESS: case ViewShell::ST_NOTES: case ViewShell::ST_HANDOUT: return IMPRESS_FACTORY_ID;
case ViewShell::ST_DRAW: return DRAW_FACTORY_ID;
case ViewShell::ST_OUTLINE: return OUTLINE_FACTORY_ID;
case ViewShell::ST_SLIDE_SORTER: return SLIDE_SORTER_FACTORY_ID;
case ViewShell::ST_PRESENTATION: return PRESENTATION_FACTORY_ID;
// Since we have to return a view id for every possible shell type // and there is not (yet) a proper ViewShellBase sub class for the // remaining types we chose the Impress factory as a fall back. case ViewShell::ST_NOTESPANEL: case ViewShell::ST_SIDEBAR: case ViewShell::ST_NONE: default: return IMPRESS_FACTORY_ID;
}
}
ViewShell::Implementation::ToolBarManagerLock::ToolBarManagerLock ( const std::shared_ptr<ToolBarManager>& rpManager)
: mpLock(new ToolBarManager::UpdateLock(rpManager)),
maTimer("sd ToolBarManagerLock maTimer")
{ // Start a timer that will unlock the ToolBarManager update lock when // that is not done explicitly by calling Release().
maTimer.SetInvokeHandler(LINK(this,ToolBarManagerLock,TimeoutCallback));
maTimer.SetTimeout(100);
maTimer.Start();
}
IMPL_LINK_NOARG(ViewShell::Implementation::ToolBarManagerLock, TimeoutCallback, Timer *, void)
{ // If possible then release the lock now. Otherwise start the timer // and try again later. if (Application::IsUICaptured())
{
maTimer.Start();
} else
{
mpSelf.reset();
}
}
void ViewShell::Implementation::ToolBarManagerLock::Release (bool bForce)
{ // If possible then release the lock now. Otherwise try again when the // timer expires. if (bForce || ! Application::IsUICaptured())
{
mpSelf.reset();
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.