You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by or...@apache.org on 2014/02/17 17:38:11 UTC
svn commit: r1569052 - in /openoffice/trunk/main/sw: inc/ source/core/doc/
source/core/edit/ source/core/frmedt/ source/core/layout/ source/core/view/
source/ui/app/ source/ui/dbui/ source/ui/dialog/ source/ui/dochdl/
source/ui/envelp/ source/ui/index/...
Author: orw
Date: Mon Feb 17 16:38:10 2014
New Revision: 1569052
URL: http://svn.apache.org/r1569052
Log:
124096: avoid unlock of dispatcher by recursive Lock-Unlock-pattern
Modified:
openoffice/trunk/main/sw/inc/docsh.hxx
openoffice/trunk/main/sw/inc/swwait.hxx
openoffice/trunk/main/sw/source/core/doc/docdesc.cxx
openoffice/trunk/main/sw/source/core/edit/autofmt.cxx
openoffice/trunk/main/sw/source/core/edit/edtab.cxx
openoffice/trunk/main/sw/source/core/frmedt/fetab.cxx
openoffice/trunk/main/sw/source/core/layout/layact.cxx
openoffice/trunk/main/sw/source/core/view/viewsh.cxx
openoffice/trunk/main/sw/source/ui/app/appenv.cxx
openoffice/trunk/main/sw/source/ui/app/applab.cxx
openoffice/trunk/main/sw/source/ui/app/docsh.cxx
openoffice/trunk/main/sw/source/ui/app/docsh2.cxx
openoffice/trunk/main/sw/source/ui/app/docshini.cxx
openoffice/trunk/main/sw/source/ui/app/swwait.cxx
openoffice/trunk/main/sw/source/ui/dbui/dbinsdlg.cxx
openoffice/trunk/main/sw/source/ui/dbui/dbmgr.cxx
openoffice/trunk/main/sw/source/ui/dialog/docstdlg.cxx
openoffice/trunk/main/sw/source/ui/dochdl/swdtflvr.cxx
openoffice/trunk/main/sw/source/ui/envelp/envlop1.cxx
openoffice/trunk/main/sw/source/ui/index/toxmgr.cxx
openoffice/trunk/main/sw/source/ui/lingu/hyp.cxx
openoffice/trunk/main/sw/source/ui/misc/glossary.cxx
openoffice/trunk/main/sw/source/ui/misc/redlndlg.cxx
openoffice/trunk/main/sw/source/ui/misc/srtdlg.cxx
openoffice/trunk/main/sw/source/ui/shells/annotsh.cxx
openoffice/trunk/main/sw/source/ui/shells/basesh.cxx
openoffice/trunk/main/sw/source/ui/shells/drawsh.cxx
openoffice/trunk/main/sw/source/ui/shells/drwtxtex.cxx
openoffice/trunk/main/sw/source/ui/shells/frmsh.cxx
openoffice/trunk/main/sw/source/ui/shells/grfsh.cxx
openoffice/trunk/main/sw/source/ui/shells/textsh1.cxx
openoffice/trunk/main/sw/source/ui/uiview/view2.cxx
openoffice/trunk/main/sw/source/ui/uiview/viewling.cxx
openoffice/trunk/main/sw/source/ui/uiview/viewsrch.cxx
Modified: openoffice/trunk/main/sw/inc/docsh.hxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/inc/docsh.hxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/inc/docsh.hxx (original)
+++ openoffice/trunk/main/sw/inc/docsh.hxx Mon Feb 17 16:38:10 2014
@@ -280,12 +280,6 @@ public:
sal_Int16 GetUpdateDocMode() const {return nUpdateDocMode;}
- //Activate wait cursor for all windows of this document
- //Optionally all dispatcher could be Locked
- //Usually locking should be done using the class: SwWaitObject!
- void EnterWait( sal_Bool bLockDispatcher );
- void LeaveWait( sal_Bool bLockDispatcher );
-
void ToggleBrowserMode(sal_Bool bOn, SwView* pView);
sal_uLong LoadStylesFromFile( const String& rURL, SwgReaderOption& rOpt,
Modified: openoffice/trunk/main/sw/inc/swwait.hxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/inc/swwait.hxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/inc/swwait.hxx (original)
+++ openoffice/trunk/main/sw/inc/swwait.hxx Mon Feb 17 16:38:10 2014
@@ -26,15 +26,28 @@
#include <tools/solar.h>
#include "swdllapi.h"
+#include <hash_set>
+
class SwDocShell;
+class SfxDispatcher;
class SW_DLLPUBLIC SwWait
{
- SwDocShell &rDoc;
- sal_Bool bLock;
public:
- SwWait( SwDocShell &rDocShell, sal_Bool bLockDispatcher );
+ // Activate wait cursor for all windows of given document <rDocShell>
+ // Optional all dispatcher could be Locked
+ SwWait(
+ SwDocShell &rDocShell,
+ const bool bLockUnlockDispatcher );
~SwWait();
+
+private:
+ void EnterWaitAndLockDispatcher();
+ void LeaveWaitAndUnlockDispatcher();
+
+ SwDocShell& mrDoc;
+ const bool mbLockUnlockDispatcher;
+ std::unordered_set< SfxDispatcher* > mpLockedDispatchers;
};
#endif
Modified: openoffice/trunk/main/sw/source/core/doc/docdesc.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/doc/docdesc.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/doc/docdesc.cxx (original)
+++ openoffice/trunk/main/sw/source/core/doc/docdesc.cxx Mon Feb 17 16:38:10 2014
@@ -646,7 +646,7 @@ void SwDoc::PrtDataChanged()
pSh->GetViewOptions()->IsPrtFormat() )
{
if ( GetDocShell() )
- pWait = new SwWait( *GetDocShell(), sal_True );
+ pWait = new SwWait( *GetDocShell(), true );
pTmpRoot->StartAllAction();
bEndAction = sal_True;
Modified: openoffice/trunk/main/sw/source/core/edit/autofmt.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/edit/autofmt.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/edit/autofmt.cxx (original)
+++ openoffice/trunk/main/sw/source/core/edit/autofmt.cxx Mon Feb 17 16:38:10 2014
@@ -2683,7 +2683,7 @@ void SwEditShell::AutoFormat( const SvxS
{
aAFFlags = *pAFlags;
if( !aAFFlags.bAFmtByInput )
- pWait = new SwWait( *GetDoc()->GetDocShell(), sal_True );
+ pWait = new SwWait( *GetDoc()->GetDocShell(), true );
}
SwPaM* pCrsr = GetCrsr();
Modified: openoffice/trunk/main/sw/source/core/edit/edtab.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/edit/edtab.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/edit/edtab.cxx (original)
+++ openoffice/trunk/main/sw/source/core/edit/edtab.cxx Mon Feb 17 16:38:10 2014
@@ -131,7 +131,7 @@ sal_Bool SwEditShell::TextToTable( const
sal_Int16 eAdj,
const SwTableAutoFmt* pTAFmt )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
sal_Bool bRet = sal_False;
StartAllAction();
FOREACHPAM_START(this)
@@ -145,7 +145,7 @@ sal_Bool SwEditShell::TextToTable( const
sal_Bool SwEditShell::TableToText( sal_Unicode cCh )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
sal_Bool bRet = sal_False;
SwPaM* pCrsr = GetCrsr();
const SwTableNode* pTblNd =
Modified: openoffice/trunk/main/sw/source/core/frmedt/fetab.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/frmedt/fetab.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/frmedt/fetab.cxx (original)
+++ openoffice/trunk/main/sw/source/core/frmedt/fetab.cxx Mon Feb 17 16:38:10 2014
@@ -106,7 +106,7 @@ TblWait::TblWait( sal_uInt16 nCnt, SwFrm
sal_Bool bWait = 20 < nCnt || 20 < nCnt2 || (pFrm &&
20 < pFrm->ImplFindTabFrm()->GetTable()->GetTabLines().Count());
if( bWait )
- pWait = new SwWait( rDocShell, sal_True );
+ pWait = new SwWait( rDocShell, true );
}
@@ -1145,7 +1145,7 @@ void SwFEShell::SetRowsToRepeat( sal_uIn
SwTabFrm *pTab = pFrm ? pFrm->FindTabFrm() : 0;
if( pTab && pTab->GetTable()->GetRowsToRepeat() != nSet )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
SET_CURR_SHELL( this );
StartAllAction();
GetDoc()->SetRowsToRepeat( *pTab->GetTable(), nSet );
Modified: openoffice/trunk/main/sw/source/core/layout/layact.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/layout/layact.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/layout/layact.cxx (original)
+++ openoffice/trunk/main/sw/source/core/layout/layact.cxx Mon Feb 17 16:38:10 2014
@@ -167,7 +167,7 @@ void SwLayAction::CheckWaitCrsr()
if ( !IsWait() && IsWaitAllowed() && IsPaint() &&
((Ticks() - GetStartTicks()) >= CLOCKS_PER_SEC/2) )
{
- pWait = new SwWait( *pRoot->GetFmt()->GetDoc()->GetDocShell(), sal_True );
+ pWait = new SwWait( *pRoot->GetFmt()->GetDoc()->GetDocShell(), true );
}
}
Modified: openoffice/trunk/main/sw/source/core/view/viewsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/core/view/viewsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/core/view/viewsh.cxx (original)
+++ openoffice/trunk/main/sw/source/core/view/viewsh.cxx Mon Feb 17 16:38:10 2014
@@ -806,7 +806,7 @@ void ViewShell::SetParaSpaceMax( bool bN
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if( pIDSA->get(IDocumentSettingAccess::PARA_SPACE_MAX) != bNew )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::PARA_SPACE_MAX, bNew );
const sal_uInt8 nInv = INV_PRTAREA | INV_TABLE | INV_SECTION;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -818,7 +818,7 @@ void ViewShell::SetParaSpaceMaxAtPages(
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if( pIDSA->get(IDocumentSettingAccess::PARA_SPACE_MAX_AT_PAGES) != bNew )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::PARA_SPACE_MAX_AT_PAGES, bNew );
const sal_uInt8 nInv = INV_PRTAREA | INV_TABLE | INV_SECTION;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -830,7 +830,7 @@ void ViewShell::SetTabCompat( bool bNew
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if( pIDSA->get(IDocumentSettingAccess::TAB_COMPAT) != bNew )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::TAB_COMPAT, bNew );
const sal_uInt8 nInv = INV_PRTAREA | INV_SIZE | INV_TABLE | INV_SECTION;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -842,7 +842,7 @@ void ViewShell::SetAddExtLeading( bool b
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::ADD_EXT_LEADING) != bNew )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::ADD_EXT_LEADING, bNew );
SdrModel* pTmpDrawModel = getIDocumentDrawModelAccess()->GetDrawModel();
if ( pTmpDrawModel )
@@ -857,7 +857,7 @@ void ViewShell::SetUseVirDev( bool bNewV
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::USE_VIRTUAL_DEVICE) != bNewVirtual )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
// this sets the flag at the document and calls PrtDataChanged
IDocumentDeviceAccess* pIDDA = getIDocumentDeviceAccess();
pIDDA->setReferenceDeviceType( bNewVirtual, true );
@@ -871,7 +871,7 @@ void ViewShell::SetAddParaSpacingToTable
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::ADD_PARA_SPACING_TO_TABLE_CELLS) != _bAddParaSpacingToTableCells )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::ADD_PARA_SPACING_TO_TABLE_CELLS, _bAddParaSpacingToTableCells );
const sal_uInt8 nInv = INV_PRTAREA;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -885,7 +885,7 @@ void ViewShell::SetUseFormerLineSpacing(
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::OLD_LINE_SPACING) != _bUseFormerLineSpacing )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::OLD_LINE_SPACING, _bUseFormerLineSpacing );
const sal_uInt8 nInv = INV_PRTAREA;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -898,7 +898,7 @@ void ViewShell::SetUseFormerObjectPositi
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::USE_FORMER_OBJECT_POS) != _bUseFormerObjPos )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::USE_FORMER_OBJECT_POS, _bUseFormerObjPos );
lcl_InvalidateAllObjPos( *this );
}
@@ -910,7 +910,7 @@ void ViewShell::SetConsiderWrapOnObjPos(
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::CONSIDER_WRAP_ON_OBJECT_POSITION) != _bConsiderWrapOnObjPos )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::CONSIDER_WRAP_ON_OBJECT_POSITION, _bConsiderWrapOnObjPos );
lcl_InvalidateAllObjPos( *this );
}
@@ -922,7 +922,7 @@ void ViewShell::SetUseFormerTextWrapping
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING) != _bUseFormerTextWrapping )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING, _bUseFormerTextWrapping );
const sal_uInt8 nInv = INV_PRTAREA | INV_SIZE | INV_TABLE | INV_SECTION;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -936,7 +936,7 @@ void ViewShell::SetDoNotJustifyLinesWith
IDocumentSettingAccess* pIDSA = getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK) != _bDoNotJustifyLinesWithManualBreak )
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
pIDSA->set(IDocumentSettingAccess::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK, _bDoNotJustifyLinesWithManualBreak );
const sal_uInt8 nInv = INV_PRTAREA | INV_SIZE | INV_TABLE | INV_SECTION;
lcl_InvalidateAllCntnt( *this, nInv );
@@ -955,7 +955,7 @@ void ViewShell::SetDoNotJustifyLinesWith
void ViewShell::Reformat()
{
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
// Wir gehen auf Nummer sicher:
// Wir muessen die alten Fontinformationen wegschmeissen,
@@ -997,7 +997,7 @@ void ViewShell::Reformat()
void ViewShell::CalcLayout()
{
SET_CURR_SHELL( this );
- SwWait aWait( *GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *GetDoc()->GetDocShell(), true );
//Cache vorbereiten und restaurieren, damit er nicht versaut wird.
SwSaveSetLRUOfst aSaveLRU( *SwTxtFrm::GetTxtCache(),
Modified: openoffice/trunk/main/sw/source/ui/app/appenv.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/appenv.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/appenv.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/appenv.cxx Mon Feb 17 16:38:10 2014
@@ -252,7 +252,7 @@ static sal_uInt16 nTitleNo = 0;
if (nMode == ENV_NEWDOC || nMode == ENV_INSERT)
{
- SwWait aWait( (SwDocShell&)*xDocSh, sal_True );
+ SwWait aWait( (SwDocShell&)*xDocSh, true );
// Dialog auslesen, Item in Config speichern
const SwEnvItem& rItem = pItem ? *pItem : (const SwEnvItem&) pDlg->GetOutputItemSet()->Get(FN_ENVELOP);
Modified: openoffice/trunk/main/sw/source/ui/app/applab.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/applab.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/applab.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/applab.cxx Mon Feb 17 16:38:10 2014
@@ -239,7 +239,7 @@ static sal_uInt16 nBCTitleNo = 0;
{ // block for locks the dispatcher!!
- SwWait aWait( (SwDocShell&)*xDocSh, sal_True );
+ SwWait aWait( (SwDocShell&)*xDocSh, true );
SET_CURR_SHELL(pSh);
pSh->SetLabelDoc(rItem.bSynchron);
Modified: openoffice/trunk/main/sw/source/ui/app/docsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/docsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/docsh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/docsh.cxx Mon Feb 17 16:38:10 2014
@@ -244,7 +244,7 @@ sal_Bool SwDocShell::ConvertFrom( SfxMed
return sal_False; // #129881# return if no reader is found
SotStorageRef pStg=pRead->getSotStorageRef(); // #i45333# save sot storage ref in case of recursive calls
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
// SfxProgress unterdruecken, wenn man Embedded ist
SW_MOD()->SetEmbeddedLoadSave(
@@ -307,7 +307,7 @@ sal_Bool SwDocShell::Save()
//#i3370# remove quick help to prevent saving of autocorrection suggestions
if(pView)
pView->GetEditWin().StopQuickHelp();
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
CalcLayoutForOLEObjects(); // format for OLE objets
// --> OD 2006-03-17 #i62875#
@@ -416,7 +416,7 @@ sal_Bool SwDocShell::SaveAs( SfxMedium&
}
}
}
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
//#i3370# remove quick help to prevent saving of autocorrection suggestions
if(pView)
pView->GetEditWin().StopQuickHelp();
@@ -746,7 +746,7 @@ sal_Bool SwDocShell::ConvertTo( SfxMediu
//Keine View also das ganze Dokument!
if ( pWrtShell )
{
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
// --> OD 2009-12-31 #i106906#
const sal_Bool bFormerLockView = pWrtShell->IsViewLocked();
pWrtShell->LockView( sal_True );
Modified: openoffice/trunk/main/sw/source/ui/app/docsh2.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/docsh2.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/docsh2.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/docsh2.cxx Mon Feb 17 16:38:10 2014
@@ -242,12 +242,10 @@ void lcl_processCompatibleSfxHint( const
void SwDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
- if( !pDoc )
- {
-//MA: Kommt bei der OLE-Registration vor!
-// ASSERT( !this, "DocShell ist nicht richtig initialisiert!" );
- return ;
- }
+ if( !pDoc )
+ {
+ return ;
+ }
#ifdef FUTURE_VBA
uno::Reference< script::vba::XVBAEventProcessor > xVbaEvents = pDoc->GetVbaEventProcessor();
@@ -255,74 +253,66 @@ void SwDocShell::Notify( SfxBroadcaster&
lcl_processCompatibleSfxHint( xVbaEvents, rHint );
#endif
- sal_uInt16 nAction = 0;
- if( rHint.ISA(SfxSimpleHint) )
- {
- // swithc for more actions
- switch( ((SfxSimpleHint&) rHint).GetId() )
- {
- case SFX_HINT_TITLECHANGED:
- if( GetMedium() )
- nAction = 2;
- break;
+ sal_uInt16 nAction = 0;
+ if( rHint.ISA(SfxSimpleHint) )
+ {
+ // swithc for more actions
+ switch( ((SfxSimpleHint&) rHint).GetId() )
+ {
+ case SFX_HINT_TITLECHANGED:
+ if( GetMedium() )
+ nAction = 2;
+ break;
}
- }
- else if( rHint.ISA(SfxEventHint) &&
+ }
+ else if( rHint.ISA(SfxEventHint) &&
((SfxEventHint&) rHint).GetEventId() == SFX_EVENT_LOADFINISHED )
{
- // --> OD 2004-12-03 #i38126# - own action id
nAction = 3;
- // <--
}
- if( nAction )
- {
+ if( nAction )
+ {
sal_Bool bUnlockView = sal_True; //initializing prevents warning
- if( pWrtShell )
- {
- bUnlockView = !pWrtShell->IsViewLocked();
- pWrtShell->LockView( sal_True ); //lock visible section
- pWrtShell->StartAllAction();
- }
- switch( nAction )
- {
- case 2:
- pDoc->GetSysFldType( RES_FILENAMEFLD )->UpdateFlds();
- break;
- // --> OD 2004-12-03 #i38126# - own action for event LOADFINISHED
- // in order to avoid a modified document.
- // --> OD 2005-02-01 #i41679# - Also for the instance of <SwDoc>
- // it has to be assured, that it's not modified.
+ if( pWrtShell )
+ {
+ bUnlockView = !pWrtShell->IsViewLocked();
+ pWrtShell->LockView( sal_True ); //lock visible section
+ pWrtShell->StartAllAction();
+ }
+ switch( nAction )
+ {
+ case 2:
+ pDoc->GetSysFldType( RES_FILENAMEFLD )->UpdateFlds();
+ break;
+
+ // own action for event LOADFINISHED in order to avoid a modified document.
+ // Also for the instance of <SwDoc> it has to be assured, that it's not modified.
// Perform the same as for action id 1, but disable <SetModified>.
case 3:
{
const bool bResetModified = IsEnableSetModified();
if ( bResetModified )
EnableSetModified( sal_False );
- // --> OD 2005-02-01 #i41679#
const bool bIsDocModified = pDoc->IsModified();
- // <--
pDoc->DocInfoChgd( );
- // --> OD 2005-02-01 #i41679#
if ( !bIsDocModified )
pDoc->ResetModified();
- // <--
if ( bResetModified )
EnableSetModified( sal_True );
}
break;
- // <--
- }
+ }
- if( pWrtShell )
- {
- pWrtShell->EndAllAction();
- if( bUnlockView )
- pWrtShell->LockView( sal_False );
- }
- }
+ if( pWrtShell )
+ {
+ pWrtShell->EndAllAction();
+ if( bUnlockView )
+ pWrtShell->LockView( sal_False );
+ }
+ }
}
/*--------------------------------------------------------------------
@@ -1445,7 +1435,7 @@ void SwDocShell::Execute(SfxRequest& rRe
{
if( PrepareClose( sal_False ) )
{
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
//bDone = bCreateHtml //#outline level,removed by zhaojianwei
// ? pDoc->GenerateHTMLDoc( aFileName, pSplitColl )
Modified: openoffice/trunk/main/sw/source/ui/app/docshini.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/docshini.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/docshini.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/docshini.cxx Mon Feb 17 16:38:10 2014
@@ -567,7 +567,7 @@ sal_Bool SwDocShell::Load( SfxMedium& r
nUpdateDocMode = pUpdateDocItem ? pUpdateDocItem->GetValue() : document::UpdateDocMode::NO_UPDATE;
}
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
sal_uInt32 nErr = ERR_SWG_READ_ERROR;
switch( GetCreateMode() )
{
@@ -684,7 +684,7 @@ sal_Bool SwDocShell::LoadFrom( SfxMediu
if ( xAccess->hasByName( aStreamName ) && rMedium.GetStorage()->isStreamElement( aStreamName ) )
{
// Das Laden
- SwWait aWait( *this, sal_True );
+ SwWait aWait( *this, true );
{
ASSERT( !mxBasePool.is(), "wer hat seinen Pool nicht zerstoert?" );
mxBasePool = new SwDocStyleSheetPool( *pDoc, SFX_CREATE_MODE_ORGANIZER == GetCreateMode() );
Modified: openoffice/trunk/main/sw/source/ui/app/swwait.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/app/swwait.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/app/swwait.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/app/swwait.cxx Mon Feb 17 16:38:10 2014
@@ -24,48 +24,69 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sw.hxx"
+#include <swwait.hxx>
+#include <docsh.hxx>
#include <sfx2/viewfrm.hxx>
#include <sfx2/dispatch.hxx>
#include <vcl/window.hxx>
-#include <docsh.hxx>
-#include <swwait.hxx>
-void SwDocShell::EnterWait( sal_Bool bLockDispatcher )
+SwWait::SwWait(
+ SwDocShell &rDocShell,
+ const bool bLockUnlockDispatcher )
+ : mrDoc ( rDocShell )
+ , mbLockUnlockDispatcher( bLockUnlockDispatcher )
+ , mpLockedDispatchers()
{
- SfxViewFrame *pFrame = SfxViewFrame::GetFirst( this, sal_False );
- while ( pFrame )
- {
- pFrame->GetWindow().EnterWait();
- if ( bLockDispatcher )
- pFrame->GetDispatcher()->Lock( sal_True );
- pFrame = SfxViewFrame::GetNext( *pFrame, this, sal_False );
- }
+ EnterWaitAndLockDispatcher();
}
-void SwDocShell::LeaveWait( sal_Bool bLockDispatcher )
+SwWait::~SwWait()
{
- SfxViewFrame *pFrame = SfxViewFrame::GetFirst( this, sal_False );
- while ( pFrame )
- {
- pFrame->GetWindow().LeaveWait();
- if ( bLockDispatcher )
- pFrame->GetDispatcher()->Lock( sal_False );
- pFrame = SfxViewFrame::GetNext( *pFrame, this, sal_False );
- }
+ LeaveWaitAndUnlockDispatcher();
}
-SwWait::SwWait( SwDocShell &rDocShell, sal_Bool bLockDispatcher ) :
- rDoc ( rDocShell ),
- bLock( bLockDispatcher )
+void SwWait::EnterWaitAndLockDispatcher()
{
- rDoc.EnterWait( bLock );
+ SfxViewFrame *pFrame = SfxViewFrame::GetFirst( &mrDoc, sal_False );
+ while ( pFrame )
+ {
+ pFrame->GetWindow().EnterWait();
+ if ( mbLockUnlockDispatcher )
+ {
+ // do not look already locked dispatchers
+ SfxDispatcher* pDispatcher = pFrame->GetDispatcher();
+ if ( !pDispatcher->IsLocked() )
+ {
+ pDispatcher->Lock( sal_True );
+ mpLockedDispatchers.insert( pDispatcher );
+ }
+ }
+
+ pFrame = SfxViewFrame::GetNext( *pFrame, &mrDoc, sal_False );
+ }
}
-SwWait::~SwWait()
+void SwWait::LeaveWaitAndUnlockDispatcher()
{
- rDoc.LeaveWait( bLock );
+ SfxViewFrame *pFrame = SfxViewFrame::GetFirst( &mrDoc, sal_False );
+ while ( pFrame )
+ {
+ pFrame->GetWindow().LeaveWait();
+ if ( mbLockUnlockDispatcher )
+ {
+ // only unlock dispatchers which had been locked
+ SfxDispatcher* pDispatcher = pFrame->GetDispatcher();
+ if ( mpLockedDispatchers.find( pDispatcher ) != mpLockedDispatchers.end() )
+ {
+ mpLockedDispatchers.erase( pDispatcher );
+ pDispatcher->Lock( sal_False );
+ }
+ }
+
+ pFrame = SfxViewFrame::GetNext( *pFrame, &mrDoc, sal_False );
+ }
}
Modified: openoffice/trunk/main/sw/source/ui/dbui/dbinsdlg.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/dbui/dbinsdlg.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/dbui/dbinsdlg.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/dbui/dbinsdlg.cxx Mon Feb 17 16:38:10 2014
@@ -1223,7 +1223,7 @@ void SwInsertDBColAutoPilot::DataToDoc(
break;
if( 10 == i )
- pWait = ::std::auto_ptr<SwWait>(new SwWait( *pView->GetDocShell(), sal_True ));
+ pWait = ::std::auto_ptr<SwWait>(new SwWait( *pView->GetDocShell(), true ));
}
rSh.MoveTable( GetfnTableCurr(), GetfnTableStart() );
@@ -1455,7 +1455,7 @@ void SwInsertDBColAutoPilot::DataToDoc(
rSh.SwEditShell::SplitNode();
if( 10 == i )
- pWait = ::std::auto_ptr<SwWait>(new SwWait( *pView->GetDocShell(), sal_True ));
+ pWait = ::std::auto_ptr<SwWait>(new SwWait( *pView->GetDocShell(), true ));
}
if( !bSetCrsr && pMark != NULL)
Modified: openoffice/trunk/main/sw/source/ui/dbui/dbmgr.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/dbui/dbmgr.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/dbui/dbmgr.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/dbui/dbmgr.cxx Mon Feb 17 16:38:10 2014
@@ -504,7 +504,7 @@ void SwNewDBMgr::ImportFromConnection( S
ImportDBEntry(pSh);
if( 10 == ++i )
- pWait = new SwWait( *pSh->GetView().GetDocShell(), sal_True);
+ pWait = new SwWait( *pSh->GetView().GetDocShell(), true );
} while(ToNextMergeRecord());
}
Modified: openoffice/trunk/main/sw/source/ui/dialog/docstdlg.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/dialog/docstdlg.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/dialog/docstdlg.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/dialog/docstdlg.cxx Mon Feb 17 16:38:10 2014
@@ -166,7 +166,7 @@ void SwDocStatPage::Update()
ASSERT( pSh, "Shell not found" );
- SwWait aWait( *pSh->GetDoc()->GetDocShell(), sal_True );
+ SwWait aWait( *pSh->GetDoc()->GetDocShell(), true );
pSh->StartAction();
aDocStat = pSh->GetDoc()->GetDocStat();
pSh->GetDoc()->UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/dochdl/swdtflvr.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/dochdl/swdtflvr.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/dochdl/swdtflvr.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/dochdl/swdtflvr.cxx Mon Feb 17 16:38:10 2014
@@ -831,7 +831,7 @@ int SwTransferable::PrepareForCopy( sal_
{
SwWait *pWait = 0;
if( pWrtShell->ShouldWait() )
- pWait = new SwWait( *pWrtShell->GetView().GetDocShell(), sal_True );
+ pWait = new SwWait( *pWrtShell->GetView().GetDocShell(), true );
pClpDocFac = new SwDocFac;
@@ -996,7 +996,7 @@ int SwTransferable::CalculateAndCopy()
{
if(!pWrtShell)
return 0;
- SwWait aWait( *pWrtShell->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pWrtShell->GetView().GetDocShell(), true );
String aStr( pWrtShell->Calculate() );
@@ -1018,7 +1018,7 @@ int SwTransferable::CopyGlossary( SwText
{
if(!pWrtShell)
return 0;
- SwWait aWait( *pWrtShell->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pWrtShell->GetView().GetDocShell(), true );
pClpDocFac = new SwDocFac;
SwDoc *const pCDoc = lcl_GetDoc(*pClpDocFac);
@@ -1163,8 +1163,7 @@ int SwTransferable::PasteData( Transfera
const Point* pPt, sal_Int8 nDropAction,
sal_Bool bPasteSelection )
{
- SwWait aWait( *rSh.GetView().
- GetDocShell(), sal_False );
+ SwWait aWait( *rSh.GetView().GetDocShell(), false );
SwTrnsfrActionAndUndo* pAction = 0;
SwModule* pMod = SW_MOD();
@@ -2854,7 +2853,7 @@ int SwTransferable::PasteFormat( SwWrtSh
TransferableDataHelper& rData,
sal_uLong nFormat )
{
- SwWait aWait( *rSh.GetView().GetDocShell(), sal_False );
+ SwWait aWait( *rSh.GetView().GetDocShell(), false );
int nRet = 0;
sal_uLong nPrivateFmt = FORMAT_PRIVATE;
Modified: openoffice/trunk/main/sw/source/ui/envelp/envlop1.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/envelp/envlop1.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/envelp/envlop1.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/envelp/envlop1.cxx Mon Feb 17 16:38:10 2014
@@ -281,7 +281,7 @@ SwEnvPage::~SwEnvPage()
IMPL_LINK( SwEnvPage, DatabaseHdl, ListBox *, pListBox )
{
- SwWait aWait( *pSh->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pSh->GetView().GetDocShell(), true );
if (pListBox == &aDatabaseLB)
{
Modified: openoffice/trunk/main/sw/source/ui/index/toxmgr.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/index/toxmgr.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/index/toxmgr.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/index/toxmgr.cxx Mon Feb 17 16:38:10 2014
@@ -293,7 +293,7 @@ sal_Bool SwTOXMgr::UpdateOrInsertTOX(con
SwTOXBase** ppBase,
const SfxItemSet* pSet)
{
- SwWait aWait( *pSh->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pSh->GetView().GetDocShell(), true );
sal_Bool bRet = sal_True;
const SwTOXBase* pCurTOX = ppBase && *ppBase ? *ppBase : GetCurTOX();
SwTOXBase* pTOX = (SwTOXBase*)pCurTOX;
Modified: openoffice/trunk/main/sw/source/ui/lingu/hyp.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/lingu/hyp.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/lingu/hyp.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/lingu/hyp.cxx Mon Feb 17 16:38:10 2014
@@ -96,7 +96,7 @@ sal_Bool SwHyphWrapper::SpellContinue()
if( bAutomatic )
{
PSH->StartAllAction();
- pWait = new SwWait( *pView->GetDocShell(), sal_True );
+ pWait = new SwWait( *pView->GetDocShell(), true );
}
uno::Reference< uno::XInterface > xHyphWord = bInSelection ?
Modified: openoffice/trunk/main/sw/source/ui/misc/glossary.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/misc/glossary.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/misc/glossary.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/misc/glossary.cxx Mon Feb 17 16:38:10 2014
@@ -1091,7 +1091,7 @@ sal_Bool SwGlTreeListBox::NotifyMoving(
if(pDestParent != pSrcParent)
{
SwGlossaryDlg* pDlg = (SwGlossaryDlg*)Window::GetParent();
- SwWait aWait( *pDlg->pSh->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pDlg->pSh->GetView().GetDocShell(), true );
GroupUserData* pGroupData = (GroupUserData*)pSrcParent->GetUserData();
String sSourceGroup(pGroupData->sGroupName);
@@ -1139,7 +1139,7 @@ sal_Bool SwGlTreeListBox::NotifyCopying
if(pDestParent != pSrcParent)
{
SwGlossaryDlg* pDlg = (SwGlossaryDlg*)Window::GetParent();
- SwWait aWait( *pDlg->pSh->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pDlg->pSh->GetView().GetDocShell(), true );
GroupUserData* pGroupData = (GroupUserData*)pSrcParent->GetUserData();
String sSourceGroup(pGroupData->sGroupName);
Modified: openoffice/trunk/main/sw/source/ui/misc/redlndlg.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/misc/redlndlg.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/misc/redlndlg.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/misc/redlndlg.cxx Mon Feb 17 16:38:10 2014
@@ -145,7 +145,7 @@ void SwModelessRedlineAcceptDlg::Activat
if (pChildWin->GetOldDocShell() != pDocSh)
{ // Dok-Wechsel
- SwWait aWait( *pDocSh, sal_False );
+ SwWait aWait( *pDocSh, false );
SwWrtShell* pSh = pView->GetWrtShellPtr();
pChildWin->SetOldDocShell(pDocSh); // Rekursion vermeiden (durch Modified-Hdl)
@@ -310,7 +310,7 @@ SwRedlineAcceptDlg::~SwRedlineAcceptDlg(
void SwRedlineAcceptDlg::Init(sal_uInt16 nStart)
{
- SwWait aWait( *::GetActiveView()->GetDocShell(), sal_False );
+ SwWait aWait( *::GetActiveView()->GetDocShell(), false );
pTable->SetUpdateMode(sal_False);
aUsedSeqNo.Remove((sal_uInt16)0, aUsedSeqNo.Count());
@@ -480,7 +480,7 @@ void SwRedlineAcceptDlg::Activate()
return;
SwView *pView = ::GetActiveView();
- SwWait aWait( *pView->GetDocShell(), sal_False );
+ SwWait aWait( *pView->GetDocShell(), false );
aUsedSeqNo.Remove((sal_uInt16)0, aUsedSeqNo.Count());
@@ -922,7 +922,7 @@ void SwRedlineAcceptDlg::CallAcceptRejec
if( !bAccept )
FnAccRej = &SwEditShell::RejectRedline;
- SwWait aWait( *pSh->GetView().GetDocShell(), sal_True );
+ SwWait aWait( *pSh->GetView().GetDocShell(), true );
pSh->StartAction();
// #111827#
@@ -1328,7 +1328,7 @@ IMPL_LINK( SwRedlineAcceptDlg, CommandHd
if (pTable->GetSortedCol() == nSortMode)
bSortDir = !pTable->GetSortDirection();
- SwWait aWait( *::GetActiveView()->GetDocShell(), sal_False );
+ SwWait aWait( *::GetActiveView()->GetDocShell(), false );
pTable->SortByCol(nSortMode, bSortDir);
if (nSortMode == 0xffff)
Init(); // Alles neu fuellen
Modified: openoffice/trunk/main/sw/source/ui/misc/srtdlg.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/misc/srtdlg.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/misc/srtdlg.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/misc/srtdlg.cxx Mon Feb 17 16:38:10 2014
@@ -392,7 +392,7 @@ void SwSortDlg::Apply()
sal_Bool bRet;
{
- SwWait aWait( *rSh.GetView().GetDocShell(), sal_True );
+ SwWait aWait( *rSh.GetView().GetDocShell(), true );
rSh.StartAllAction();
if( 0 != (bRet = rSh.Sort( aOptions )))
rSh.SetModified();
Modified: openoffice/trunk/main/sw/source/ui/shells/annotsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/annotsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/annotsh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/annotsh.cxx Mon Feb 17 16:38:10 2014
@@ -455,7 +455,7 @@ void SwAnnotationShell::Exec( SfxRequest
SwDocStat aCurr;
SwDocStat aDocStat( rSh.getIDocumentStatistics()->GetDocStat() );
{
- SwWait aWait( *rView.GetDocShell(), sal_True );
+ SwWait aWait( *rView.GetDocShell(), true );
rSh.StartAction();
rSh.CountWords( aCurr );
rSh.UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/shells/basesh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/basesh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/basesh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/basesh.cxx Mon Feb 17 16:38:10 2014
@@ -647,7 +647,7 @@ void SwBaseShell::Execute(SfxRequest &rR
break;
case FN_UPDATE_CHARTS:
{
- SwWait aWait( *rView.GetDocShell(), sal_True );
+ SwWait aWait( *rView.GetDocShell(), true );
rSh.UpdateAllCharts();
}
break;
@@ -752,7 +752,7 @@ void SwBaseShell::Execute(SfxRequest &rR
if ( (!rSh.IsSelFrmMode() || nSelType & nsSelectionType::SEL_GRF) &&
nGalleryItemType == com::sun::star::gallery::GalleryItemType::GRAPHIC )
{
- SwWait aWait( *rView.GetDocShell(), sal_True );
+ SwWait aWait( *rView.GetDocShell(), true );
String aGrfName, aFltName;
const Graphic aGrf( pGalleryItem->GetGraphic() );
Modified: openoffice/trunk/main/sw/source/ui/shells/drawsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/drawsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/drawsh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/drawsh.cxx Mon Feb 17 16:38:10 2014
@@ -340,7 +340,7 @@ void SwDrawShell::Execute(SfxRequest &rR
SwDocStat aCurr;
SwDocStat aDocStat( rSh.getIDocumentStatistics()->GetDocStat() );
{
- SwWait aWait( *GetView().GetDocShell(), sal_True );
+ SwWait aWait( *GetView().GetDocShell(), true );
rSh.StartAction();
rSh.CountWords( aCurr );
rSh.UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/shells/drwtxtex.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/drwtxtex.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/drwtxtex.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/drwtxtex.cxx Mon Feb 17 16:38:10 2014
@@ -418,7 +418,7 @@ void SwDrawTextShell::Execute( SfxReques
SwDocStat aCurr;
SwDocStat aDocStat( rSh.getIDocumentStatistics()->GetDocStat() );
{
- SwWait aWait( *GetView().GetDocShell(), sal_True );
+ SwWait aWait( *GetView().GetDocShell(), true );
rSh.StartAction();
rSh.CountWords( aCurr );
rSh.UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/shells/frmsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/frmsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/frmsh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/frmsh.cxx Mon Feb 17 16:38:10 2014
@@ -282,7 +282,7 @@ void SwFrameShell::Execute(SfxRequest &r
SwDocStat aCurr;
SwDocStat aDocStat( rSh.getIDocumentStatistics()->GetDocStat() );
{
- SwWait aWait( *GetView().GetDocShell(), sal_True );
+ SwWait aWait( *GetView().GetDocShell(), true );
rSh.StartAction();
rSh.CountWords( aCurr );
rSh.UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/shells/grfsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/grfsh.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/grfsh.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/grfsh.cxx Mon Feb 17 16:38:10 2014
@@ -321,7 +321,7 @@ void SwGrfShell::Execute(SfxRequest &rRe
if( sGrfNm.Len() )
{
SwDocShell* pDocSh = GetView().GetDocShell();
- SwWait aWait( *pDocSh, sal_True );
+ SwWait aWait( *pDocSh, true );
SfxMedium* pMedium = pDocSh->GetMedium();
INetURLObject aAbs;
if( pMedium )
Modified: openoffice/trunk/main/sw/source/ui/shells/textsh1.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/shells/textsh1.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/shells/textsh1.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/shells/textsh1.cxx Mon Feb 17 16:38:10 2014
@@ -1358,7 +1358,7 @@ void SwTextShell::Execute(SfxRequest &rR
SwDocStat aCurr;
SwDocStat aDocStat( rSh.getIDocumentStatistics()->GetDocStat() );
{
- SwWait aWait( *GetView().GetDocShell(), sal_True );
+ SwWait aWait( *GetView().GetDocShell(), true );
rSh.StartAction();
rSh.CountWords( aCurr );
rSh.UpdateDocStat( aDocStat );
Modified: openoffice/trunk/main/sw/source/ui/uiview/view2.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/uiview/view2.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/uiview/view2.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/uiview/view2.cxx Mon Feb 17 16:38:10 2014
@@ -209,7 +209,7 @@ int SwView::InsertGraphic( const String
sal_Bool bLink, GraphicFilter *pFlt,
Graphic* pPreviewGrf, sal_Bool bRule )
{
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
Graphic aGrf;
int nRes = GRFILTER_OK;
@@ -2146,7 +2146,7 @@ long SwView::InsertMedium( sal_uInt16 nS
sal_uLong nErrno;
{ //Scope for SwWait-Object, to be able to execute slots
//outside this scope.
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
pWrtShell->StartAllAction();
if ( pWrtShell->HasSelection() )
pWrtShell->DelRight(); // Selektionen loeschen
@@ -2206,7 +2206,7 @@ extern int lcl_FindDocShell( SfxObjectSh
sFltNm, nVersion, pDocSh );
if( nRet )
{
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
pWrtShell->StartAllAction();
pWrtShell->EnterStdMode(); // Selektionen loeschen
Modified: openoffice/trunk/main/sw/source/ui/uiview/viewling.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/uiview/viewling.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/uiview/viewling.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/uiview/viewling.cxx Mon Feb 17 16:38:10 2014
@@ -626,7 +626,7 @@ void SwView::StartThesaurus()
{
// create dialog
{ //Scope for SwWait-Object
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
// load library with dialog only on demand ...
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
pDlg = pFact->CreateThesaurusDialog( &GetEditWin(), xThes, aTmp, eLang );
Modified: openoffice/trunk/main/sw/source/ui/uiview/viewsrch.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sw/source/ui/uiview/viewsrch.cxx?rev=1569052&r1=1569051&r2=1569052&view=diff
==============================================================================
--- openoffice/trunk/main/sw/source/ui/uiview/viewsrch.cxx (original)
+++ openoffice/trunk/main/sw/source/ui/uiview/viewsrch.cxx Mon Feb 17 16:38:10 2014
@@ -335,7 +335,7 @@ void SwView::ExecSearch(SfxRequest& rReq
sal_uLong nFound;
{ //Scope for SwWait-Object
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
pWrtShell->StartAllAction();
nFound = FUNC_Search( aOpts );
pWrtShell->EndAllAction();
@@ -479,7 +479,7 @@ sal_Bool SwView::SearchAndWrap(sal_Bool
if (!pSrchItem->GetSelection())
(pWrtShell->*pWrtShell->fnKillSel)(0, sal_False);
- SwWait *pWait = new SwWait( *GetDocShell(), sal_True );
+ SwWait *pWait = new SwWait( *GetDocShell(), true );
if( FUNC_Search( aOpts ) )
{
bFound = sal_True;
@@ -546,7 +546,7 @@ sal_Bool SwView::SearchAndWrap(sal_Bool
}
pWrtShell->StartAllAction();
pWrtShell->Pop(sal_False);
- pWait = new SwWait( *GetDocShell(), sal_True );
+ pWait = new SwWait( *GetDocShell(), true );
sal_Bool bSrchBkwrd = DOCPOS_START == aOpts.eEnd;
@@ -578,7 +578,7 @@ sal_Bool SwView::SearchAndWrap(sal_Bool
sal_Bool SwView::SearchAll(sal_uInt16* pFound)
{
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
pWrtShell->StartAllAction();
SwSearchOptions aOpts( pWrtShell, pSrchItem->GetBackward() );
@@ -607,7 +607,7 @@ sal_Bool SwView::SearchAll(sal_uInt16* p
void SwView::Replace()
{
- SwWait aWait( *GetDocShell(), sal_True );
+ SwWait aWait( *GetDocShell(), true );
pWrtShell->StartAllAction();