openoffice-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: r1579184 [27/33] - in /openoffice/branches/alg_writerframes: ./ ext_sources/ extras/l10n/source/de/ extras/l10n/source/es/ extras/l10n/source/eu/ extras/l10n/source/hi/ extras/l10n/source/kk/ extras/l10n/source/lt/ extras/l10n/source/nb/ ex...
Date Wed, 19 Mar 2014 10:15:07 GMT
Modified: openoffice/branches/alg_writerframes/main/sw/source/core/frmedt/fetab.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/frmedt/fetab.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/frmedt/fetab.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/frmedt/fetab.cxx Wed Mar 19 10:14:42 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/branches/alg_writerframes/main/sw/source/core/graphic/ndgrf.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/graphic/ndgrf.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/graphic/ndgrf.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/graphic/ndgrf.cxx Wed Mar 19 10:14:42 2014
@@ -739,21 +739,57 @@ void SwGrfNode::InsertLink( const String
 
 void SwGrfNode::ReleaseLink()
 {
-	if( refLink.Is() )
-	{
-		// erst die Grafik reinswappen!
-//		if( aGraphic.IsSwapOut() || !refLink->IsSynchron() )
-		{
-			bInSwapIn = sal_True;
+    if( refLink.Is() )
+    {
+        // #15508# remember some stuff from the linked graphic
+        const String aFileName(maGrfObj.GetLink());
+        const Graphic aLocalGraphic(maGrfObj.GetGraphic());
+        const bool bHasOriginalData(aLocalGraphic.IsLink());
+
+        {
+            bInSwapIn = sal_True;
             SwBaseLink* pLink = (SwBaseLink*)(::sfx2::SvBaseLink*) refLink;
             //TODO pLink->setInputStream(getInputStream());
-			pLink->SwapIn( sal_True, sal_True );
-			bInSwapIn = sal_False;
-		}
+            pLink->SwapIn( sal_True, sal_True );
+            bInSwapIn = sal_False;
+        }
+
         getIDocumentLinksAdministration()->GetLinkManager().Remove( refLink );
-		refLink.Clear();
-		maGrfObj.SetLink();
-	}
+        refLink.Clear();
+        maGrfObj.SetLink();
+
+        // #15508# added extra processing after getting rid of the link. Use whatever is
+        // known from the formally linked graphic to get to a state as close to a directly
+        // unlinked insterted graphic as possible. Goal is to have a valid GfxLink at the
+        // ImplGraphic (see there) that holds temporary data to the original data and type
+        // information about the original data. Only when this is given will
+        // SvXMLGraphicHelper::ImplInsertGraphicURL which is used at export use that type
+        // and use the original graphic at export for the ODF, without evtl. recoding
+        // of trhe bitmap graphic data to something without loss (e.g. PNG) but bigger
+        if(bHasOriginalData)
+        {
+            // #15508# if we have the original data at the Graphic, let it survive
+            // by using that Graphic again, this time at a GraphicObject without link.
+            // This happens e.g. when inserting a linked graphic and breaking the link
+            maGrfObj.SetGraphic(aLocalGraphic);
+        }
+        else if(aFileName.Len())
+        {
+            // #15508# we have no original data, but a file name. This happens e.g.
+            // when inserting a linked graphic and save, reload document. Try to access
+            // that data from the original file; if this works, use it. Else use the
+            // data we have (but without knowing the original format)
+            int nRes = GRFILTER_OK;
+            GraphicFilter* pFlt = GraphicFilter::GetGraphicFilter();
+            Graphic aNew;
+            nRes = GraphicFilter::LoadGraphic( aFileName, String(), aNew, pFlt);
+
+            if(GRFILTER_OK == nRes)
+            {
+                maGrfObj.SetGraphic(aNew);
+            }
+        }
+    }
 }
 
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/inc/MarkManager.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/inc/MarkManager.hxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/inc/MarkManager.hxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/inc/MarkManager.hxx Wed Mar 19 10:14:42 2014
@@ -95,10 +95,13 @@ namespace sw { namespace mark
             virtual sal_Int32 getAnnotationMarksCount() const;
             virtual const_iterator_t findAnnotationMark( const ::rtl::OUString& rName ) const;
 
+            virtual void assureSortedMarkContainers() const;
+
         private:
             // make names
             ::rtl::OUString getUniqueMarkName(const ::rtl::OUString& rName) const;
             void sortMarks();
+            void sortSubsetMarks();
 
             // container for all marks
             container_t m_vAllMarks;

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/inc/UndoRedline.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/inc/UndoRedline.hxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/inc/UndoRedline.hxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/inc/UndoRedline.hxx Wed Mar 19 10:14:42 2014
@@ -38,10 +38,10 @@ class SwUndoDelete;
 class SwUndoRedline : public SwUndo, public SwUndRng
 {
 protected:
-    SwRedlineData* pRedlData;
-    SwRedlineSaveDatas* pRedlSaveData;
-    SwUndoId nUserId;
-    sal_Bool bHiddenRedlines;
+    SwRedlineData* mpRedlData;
+    SwRedlineSaveDatas* mpRedlSaveData;
+    SwUndoId mnUserId;
+    sal_Bool mbHiddenRedlines;
 
     virtual void UndoRedlineImpl(SwDoc & rDoc, SwPaM & rPam);
     virtual void RedoRedlineImpl(SwDoc & rDoc, SwPaM & rPam);
@@ -54,7 +54,7 @@ public:
     virtual void UndoImpl( ::sw::UndoRedoContext & );
     virtual void RedoImpl( ::sw::UndoRedoContext & );
 
-    SwUndoId GetUserId() const { return nUserId; }
+    SwUndoId GetUserId() const { return mnUserId; }
     sal_uInt16 GetRedlSaveCount() const;
 };
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/inc/bookmrk.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/inc/bookmrk.hxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/inc/bookmrk.hxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/inc/bookmrk.hxx Wed Mar 19 10:14:42 2014
@@ -49,17 +49,17 @@ namespace sw { namespace mark
     {
         public:
             //getters
-            virtual SwPosition& GetMarkPos() const
+            virtual const SwPosition& GetMarkPos() const
                 { return *m_pPos1; }
             virtual const ::rtl::OUString& GetName() const
                 { return m_aName; }
             virtual bool IsCoveringPosition(const SwPosition& rPos) const;
-            virtual SwPosition& GetOtherMarkPos() const
+            virtual const SwPosition& GetOtherMarkPos() const
             {
                 OSL_PRECOND(IsExpanded(), "<SwPosition::GetOtherMarkPos(..)> - I have no other Pos set." );
                 return *m_pPos2;
             }
-            virtual SwPosition& GetMarkStart() const
+            virtual const SwPosition& GetMarkStart() const
             {
                 if( !IsExpanded() ) return GetMarkPos( );
                 if ( GetMarkPos( ) < GetOtherMarkPos( ) )
@@ -67,7 +67,7 @@ namespace sw { namespace mark
                 else
                     return GetOtherMarkPos( );
             }
-            virtual SwPosition& GetMarkEnd() const
+            virtual const SwPosition& GetMarkEnd() const
             {
                 if( !IsExpanded() ) return GetMarkPos();
                 if ( GetMarkPos( ) > GetOtherMarkPos( ) )
@@ -76,7 +76,7 @@ namespace sw { namespace mark
                     return GetOtherMarkPos( );
             }
             virtual bool IsExpanded() const
-                { return m_pPos2; }
+                { return (m_pPos2.get() != NULL); }
 
             //setters
             virtual void SetName(const ::rtl::OUString& rName)
@@ -228,6 +228,9 @@ namespace sw { namespace mark
             virtual void SetFieldHelptext(const ::rtl::OUString& aFieldHelptext)
                 { m_aFieldHelptext = aFieldHelptext; }
 
+            void SetMarkStartPos( const SwPosition& rNewStartPos );
+            void SetMarkEndPos( const SwPosition& rNewEndPos );
+
             virtual void Invalidate();
             virtual rtl::OUString ToString() const;
         private:

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/inc/crossrefbookmark.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/inc/crossrefbookmark.hxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/inc/crossrefbookmark.hxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/inc/crossrefbookmark.hxx Wed Mar 19 10:14:42 2014
@@ -41,10 +41,10 @@ namespace sw { namespace mark
                 const ::rtl::OUString& rPrefix);
 
             // getters
-            virtual SwPosition& GetOtherMarkPos() const;
-            virtual SwPosition& GetMarkStart() const
+            virtual const SwPosition& GetOtherMarkPos() const;
+            virtual const SwPosition& GetMarkStart() const
                 { return *m_pPos1; }
-            virtual SwPosition& GetMarkEnd() const
+            virtual const SwPosition& GetMarkEnd() const
                 { return *m_pPos1; }
             virtual bool IsExpanded() const
                 { return false; }

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/layout/layact.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/layout/layact.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/layout/layact.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/layout/layact.cxx Wed Mar 19 10:14:42 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/branches/alg_writerframes/main/sw/source/core/text/inftxt.hxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/text/inftxt.hxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/text/inftxt.hxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/text/inftxt.hxx Wed Mar 19 10:14:42 2014
@@ -608,7 +608,6 @@ public:
     inline void Right( const SwTwips nNew ) { nRight = nNew; }
     inline SwTwips First() const { return nFirst; }
     inline void First( const SwTwips nNew ) { nFirst = nNew; }
-    inline SwTwips CurrLeft() const { return (nLineStart ? nLeft : nFirst); }
 	inline KSHORT RealWidth() const { return nRealWidth; }
 	inline void RealWidth( const KSHORT nNew ) { nRealWidth = nNew; }
 	inline KSHORT ForcedLeftMargin() const { return nForcedLeftMargin; }

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/text/portxt.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/text/portxt.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/text/portxt.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/text/portxt.cxx Wed Mar 19 10:14:42 2014
@@ -747,6 +747,12 @@ sal_Bool SwTxtInputFldPortion::Format( S
         }
         else
         {
+            const xub_StrLen nFormerLineStart = rInf.GetLineStart();
+            if ( !mbContainsInputFieldStart )
+            {
+                rInf.SetLineStart( 0 );
+            }
+
             bRet = SwTxtPortion::Format( rInf );
 
             if ( mbContainsInputFieldEnd )
@@ -763,6 +769,10 @@ sal_Bool SwTxtInputFldPortion::Format( S
                 // adjust portion length accordingly
                 SetLen( GetLen() + 1 );
             }
+            else
+            {
+                rInf.SetLineStart( nFormerLineStart );
+            }
         }
     }
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/atrfld.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/atrfld.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/atrfld.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/atrfld.cxx Wed Mar 19 10:14:42 2014
@@ -457,6 +457,7 @@ SwTxtInputFld::SwTxtInputFld(
 
     : SwTxtFld( rAttr, nStart )
     , m_nEnd( nEnd )
+    , m_bLockNotifyContentChange( false )
 {
     SetHasDummyChar( false );
     SetHasContent( true );
@@ -477,11 +478,30 @@ xub_StrLen* SwTxtInputFld::GetEnd()
     return &m_nEnd;
 }
 
+
+void SwTxtInputFld::LockNotifyContentChange()
+{
+    m_bLockNotifyContentChange = true;
+}
+
+
+void SwTxtInputFld::UnlockNotifyContentChange()
+{
+    m_bLockNotifyContentChange = false;
+}
+
+
 void SwTxtInputFld::NotifyContentChange( SwFmtFld& rFmtFld )
 {
-    SwTxtFld::NotifyContentChange( rFmtFld );
+    if ( !m_bLockNotifyContentChange )
+    {
+        LockNotifyContentChange();
+
+        SwTxtFld::NotifyContentChange( rFmtFld );
+        UpdateTextNodeContent( GetFieldContent() );
 
-    UpdateTextNodeContent( GetFieldContent() );
+        UnlockNotifyContentChange();
+    }
 }
 
 const String SwTxtInputFld::GetFieldContent() const

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/fmtatr2.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/fmtatr2.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/fmtatr2.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/fmtatr2.cxx Wed Mar 19 10:14:42 2014
@@ -24,7 +24,8 @@
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_sw.hxx"
 
-#include "hintids.hxx"
+#include <hintids.hxx>
+#include <poolfmt.hxx>
 #include "unomid.h"
 
 #include <basic/sbxvar.hxx>
@@ -194,43 +195,53 @@ sal_Bool SwFmtAutoFmt::PutValue( const u
 *************************************************************************/
 
 SwFmtINetFmt::SwFmtINetFmt()
-	: SfxPoolItem( RES_TXTATR_INETFMT ),
-    pMacroTbl( 0 ),
-    pTxtAttr( 0 ),
-    nINetId( 0 ),
-	nVisitedId( 0 )
+	: SfxPoolItem( RES_TXTATR_INETFMT )
+    , msURL()
+    , msTargetFrame()
+    , msINetFmtName()
+    , msVisitedFmtName()
+    , msHyperlinkName()
+    , mpMacroTbl( 0 )
+    , mpTxtAttr( 0 )
+    , mnINetFmtId( 0 )
+    , mnVisitedFmtId( 0 )
 {}
 
 SwFmtINetFmt::SwFmtINetFmt( const XubString& rURL, const XubString& rTarget )
-	: SfxPoolItem( RES_TXTATR_INETFMT ),
-	aURL( rURL ),
-	aTargetFrame( rTarget ),
-    pMacroTbl( 0 ),
-    pTxtAttr( 0 ),
-    nINetId( 0 ),
-	nVisitedId( 0 )
+    : SfxPoolItem( RES_TXTATR_INETFMT )
+    , msURL( rURL )
+    , msTargetFrame( rTarget )
+    , msINetFmtName()
+    , msVisitedFmtName()
+    , msHyperlinkName()
+    , mpMacroTbl( 0 )
+    , mpTxtAttr( 0 )
+    , mnINetFmtId( RES_POOLCHR_INET_NORMAL )
+    , mnVisitedFmtId( RES_POOLCHR_INET_VISIT )
 {
+    SwStyleNameMapper::FillUIName( mnINetFmtId, msINetFmtName );
+    SwStyleNameMapper::FillUIName( mnVisitedFmtId, msVisitedFmtName );
 }
 
 SwFmtINetFmt::SwFmtINetFmt( const SwFmtINetFmt& rAttr )
-	: SfxPoolItem( RES_TXTATR_INETFMT ),
-	aURL( rAttr.GetValue() ),
-    aTargetFrame( rAttr.aTargetFrame ),
-    aINetFmt( rAttr.aINetFmt ),
-    aVisitedFmt( rAttr.aVisitedFmt ),
-    aName( rAttr.aName ),
-    pMacroTbl( 0 ),
-    pTxtAttr( 0 ),
-    nINetId( rAttr.nINetId ),
-	nVisitedId( rAttr.nVisitedId )
+	: SfxPoolItem( RES_TXTATR_INETFMT )
+    , msURL( rAttr.GetValue() )
+    , msTargetFrame( rAttr.msTargetFrame )
+    , msINetFmtName( rAttr.msINetFmtName )
+    , msVisitedFmtName( rAttr.msVisitedFmtName )
+    , msHyperlinkName( rAttr.msHyperlinkName )
+    , mpMacroTbl( 0 )
+    , mpTxtAttr( 0 )
+    , mnINetFmtId( rAttr.mnINetFmtId )
+    , mnVisitedFmtId( rAttr.mnVisitedFmtId )
 {
-	if( rAttr.GetMacroTbl() )
-		pMacroTbl = new SvxMacroTableDtor( *rAttr.GetMacroTbl() );
+    if ( rAttr.GetMacroTbl() )
+        mpMacroTbl = new SvxMacroTableDtor( *rAttr.GetMacroTbl() );
 }
 
 SwFmtINetFmt::~SwFmtINetFmt()
 {
-	delete pMacroTbl;
+	delete mpMacroTbl;
 }
 
 
@@ -239,24 +250,24 @@ int SwFmtINetFmt::operator==( const SfxP
 {
 	ASSERT( SfxPoolItem::operator==( rAttr ), "keine gleichen Attribute" );
 	sal_Bool bRet = SfxPoolItem::operator==( (SfxPoolItem&) rAttr )
-				&& aURL == ((SwFmtINetFmt&)rAttr).aURL
-				&& aName == ((SwFmtINetFmt&)rAttr).aName
-				&& aTargetFrame == ((SwFmtINetFmt&)rAttr).aTargetFrame
-				&& aINetFmt == ((SwFmtINetFmt&)rAttr).aINetFmt
-				&& aVisitedFmt == ((SwFmtINetFmt&)rAttr).aVisitedFmt
-				&& nINetId == ((SwFmtINetFmt&)rAttr).nINetId
-				&& nVisitedId == ((SwFmtINetFmt&)rAttr).nVisitedId;
+				&& msURL == ((SwFmtINetFmt&)rAttr).msURL
+				&& msHyperlinkName == ((SwFmtINetFmt&)rAttr).msHyperlinkName
+				&& msTargetFrame == ((SwFmtINetFmt&)rAttr).msTargetFrame
+				&& msINetFmtName == ((SwFmtINetFmt&)rAttr).msINetFmtName
+				&& msVisitedFmtName == ((SwFmtINetFmt&)rAttr).msVisitedFmtName
+				&& mnINetFmtId == ((SwFmtINetFmt&)rAttr).mnINetFmtId
+				&& mnVisitedFmtId == ((SwFmtINetFmt&)rAttr).mnVisitedFmtId;
 
 	if( !bRet )
 		return sal_False;
 
-	const SvxMacroTableDtor* pOther = ((SwFmtINetFmt&)rAttr).pMacroTbl;
-	if( !pMacroTbl )
+	const SvxMacroTableDtor* pOther = ((SwFmtINetFmt&)rAttr).mpMacroTbl;
+	if( !mpMacroTbl )
 		return ( !pOther || !pOther->Count() );
 	if( !pOther )
-		return 0 == pMacroTbl->Count();
+		return 0 == mpMacroTbl->Count();
 
-	const SvxMacroTableDtor& rOwn = *pMacroTbl;
+	const SvxMacroTableDtor& rOwn = *mpMacroTbl;
 	const SvxMacroTableDtor& rOther = *pOther;
 
 	// Anzahl unterschiedlich => auf jeden Fall ungleich
@@ -289,30 +300,30 @@ void SwFmtINetFmt::SetMacroTbl( const Sv
 {
 	if( pNewTbl )
 	{
-		if( pMacroTbl )
-			*pMacroTbl = *pNewTbl;
+		if( mpMacroTbl )
+			*mpMacroTbl = *pNewTbl;
 		else
-			pMacroTbl = new SvxMacroTableDtor( *pNewTbl );
+			mpMacroTbl = new SvxMacroTableDtor( *pNewTbl );
 	}
-	else if( pMacroTbl )
-		delete pMacroTbl, pMacroTbl = 0;
+	else if( mpMacroTbl )
+		delete mpMacroTbl, mpMacroTbl = 0;
 }
 
 
 
 void SwFmtINetFmt::SetMacro( sal_uInt16 nEvent, const SvxMacro& rMacro )
 {
-	if( !pMacroTbl )
-		pMacroTbl = new SvxMacroTableDtor;
+	if( !mpMacroTbl )
+		mpMacroTbl = new SvxMacroTableDtor;
 
 	SvxMacro *pOldMacro;
-	if( 0 != ( pOldMacro = pMacroTbl->Get( nEvent )) )
+	if( 0 != ( pOldMacro = mpMacroTbl->Get( nEvent )) )
 	{
 		delete pOldMacro;
-		pMacroTbl->Replace( nEvent, new SvxMacro( rMacro ) );
+		mpMacroTbl->Replace( nEvent, new SvxMacro( rMacro ) );
 	}
 	else
-		pMacroTbl->Insert( nEvent, new SvxMacro( rMacro ) );
+		mpMacroTbl->Insert( nEvent, new SvxMacro( rMacro ) );
 }
 
 
@@ -320,8 +331,8 @@ void SwFmtINetFmt::SetMacro( sal_uInt16 
 const SvxMacro* SwFmtINetFmt::GetMacro( sal_uInt16 nEvent ) const
 {
 	const SvxMacro* pRet = 0;
-	if( pMacroTbl && pMacroTbl->IsKeyValid( nEvent ) )
-		pRet = pMacroTbl->Get( nEvent );
+	if( mpMacroTbl && mpMacroTbl->IsKeyValid( nEvent ) )
+		pRet = mpMacroTbl->Get( nEvent );
 	return pRet;
 }
 
@@ -335,25 +346,25 @@ sal_Bool SwFmtINetFmt::QueryValue( uno::
 	switch(nMemberId)
 	{
 		case MID_URL_URL:
-			sVal = aURL;
+			sVal = msURL;
 		break;
 		case MID_URL_TARGET:
-			sVal = aTargetFrame;
+			sVal = msTargetFrame;
 		break;
 		case MID_URL_HYPERLINKNAME:
-			sVal = aName;
+			sVal = msHyperlinkName;
 		break;
 		case MID_URL_VISITED_FMT:
-			sVal = aVisitedFmt;
-			if( !sVal.Len() && nVisitedId != 0 )
-				SwStyleNameMapper::FillUIName( nVisitedId, sVal );
+			sVal = msVisitedFmtName;
+			if( !sVal.Len() && mnVisitedFmtId != 0 )
+				SwStyleNameMapper::FillUIName( mnVisitedFmtId, sVal );
 			if( sVal.Len() )
 				SwStyleNameMapper::FillProgName( sVal, sVal, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT, sal_True );
 		break;
 		case MID_URL_UNVISITED_FMT:
-			sVal = aINetFmt;
-			if( !sVal.Len() && nINetId != 0 )
-				SwStyleNameMapper::FillUIName( nINetId, sVal );
+			sVal = msINetFmtName;
+			if( !sVal.Len() && mnINetFmtId != 0 )
+				SwStyleNameMapper::FillUIName( mnINetFmtId, sVal );
 			if( sVal.Len() )
 				SwStyleNameMapper::FillProgName( sVal, sVal, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT, sal_True );
 		break;
@@ -411,20 +422,20 @@ sal_Bool SwFmtINetFmt::PutValue( const u
 		switch(nMemberId)
 		{
 			case MID_URL_URL:
-				aURL = sVal;
+				msURL = sVal;
 				break;
 			case MID_URL_TARGET:
-				aTargetFrame = sVal;
+				msTargetFrame = sVal;
 				break;
 			case MID_URL_HYPERLINKNAME:
-				aName = sVal;
+				msHyperlinkName = sVal;
 				break;
 			case MID_URL_VISITED_FMT:
 			{
 				String aString;
 				SwStyleNameMapper::FillUIName( sVal, aString, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT, sal_True );
-				aVisitedFmt = OUString ( aString );
-				nVisitedId = SwStyleNameMapper::GetPoolIdFromUIName( aVisitedFmt,
+				msVisitedFmtName = OUString ( aString );
+				mnVisitedFmtId = SwStyleNameMapper::GetPoolIdFromUIName( msVisitedFmtName,
 											   nsSwGetPoolIdFromName::GET_POOLID_CHRFMT );
 			}
 			break;
@@ -432,8 +443,8 @@ sal_Bool SwFmtINetFmt::PutValue( const u
 			{
 				String aString;
 				SwStyleNameMapper::FillUIName( sVal, aString, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT, sal_True );
-				aINetFmt = OUString ( aString );
-				nINetId = SwStyleNameMapper::GetPoolIdFromUIName( aINetFmt,	nsSwGetPoolIdFromName::GET_POOLID_CHRFMT );
+				msINetFmtName = OUString ( aString );
+				mnINetFmtId = SwStyleNameMapper::GetPoolIdFromUIName( msINetFmtName,	nsSwGetPoolIdFromName::GET_POOLID_CHRFMT );
 			}
 			break;
 			default:

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/ndtxt.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/ndtxt.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/ndtxt.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/ndtxt.cxx Wed Mar 19 10:14:42 2014
@@ -1028,6 +1028,7 @@ void SwTxtNode::Update(
         }
     }
 
+    bool bSortMarks = false;
     SwIndexReg aTmpIdxReg;
     if ( !bNegative && !bDelete )
     {
@@ -1086,6 +1087,7 @@ void SwTxtNode::Update(
                     rPos.GetIndex() == rIdx.GetIndex() )
                 {
                     rIdx.Assign( &aTmpIdxReg, rIdx.GetIndex() );
+                    bSortMarks = true;
                 }
             }
         }
@@ -1104,6 +1106,10 @@ void SwTxtNode::Update(
     }
 
     aTmpIdxReg.MoveTo( *this );
+    if ( bSortMarks )
+    {
+        getIDocumentMarkAccess()->assureSortedMarkContainers();
+    }
 }
 
 void SwTxtNode::_ChgTxtCollUpdateNum( const SwTxtFmtColl *pOldColl,

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/txtatr2.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/txtatr2.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/txtatr2.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/txtnode/txtatr2.cxx Wed Mar 19 10:14:42 2014
@@ -123,7 +123,7 @@ SwTxtINetFmt::SwTxtINetFmt( SwFmtINetFmt
     , m_bVisited( false )
     , m_bVisitedValid( false )
 {
-    rAttr.pTxtAttr  = this;
+    rAttr.mpTxtAttr  = this;
     SetCharFmtAttr( true );
 }
 
@@ -133,52 +133,52 @@ SwTxtINetFmt::~SwTxtINetFmt( )
 
 SwCharFmt* SwTxtINetFmt::GetCharFmt()
 {
-	const SwFmtINetFmt& rFmt = SwTxtAttrEnd::GetINetFmt();
-	SwCharFmt* pRet = NULL;
+    const SwFmtINetFmt& rFmt = SwTxtAttrEnd::GetINetFmt();
+    SwCharFmt* pRet = NULL;
 
-	if( rFmt.GetValue().Len() )
-	{
-		const SwDoc* pDoc = GetTxtNode().GetDoc();
+    if ( rFmt.GetValue().Len() )
+    {
+        const SwDoc* pDoc = GetTxtNode().GetDoc();
         if( !IsVisitedValid() )
         {
-			SetVisited( pDoc->IsVisitedURL( rFmt.GetValue() ) );
+            SetVisited( pDoc->IsVisitedURL( rFmt.GetValue() ) );
             SetVisitedValid( true );
         }
-		sal_uInt16 nId;
-		const String& rStr = IsVisited() ? rFmt.GetVisitedFmt()
-										   : rFmt.GetINetFmt();
-		if( rStr.Len() )
-			nId = IsVisited() ? rFmt.GetVisitedFmtId() : rFmt.GetINetFmtId();
-		else
-			nId = static_cast<sal_uInt16>(IsVisited() ? RES_POOLCHR_INET_VISIT : RES_POOLCHR_INET_NORMAL);
 
-		// JP 10.02.2000, Bug 72806: dont modify the doc for getting the
-		//		correct charstyle.
-		sal_Bool bResetMod = !pDoc->IsModified();
-		Link aOle2Lnk;
-		if( bResetMod )
-		{
-			aOle2Lnk = pDoc->GetOle2Link();
-			((SwDoc*)pDoc)->SetOle2Link( Link() );
-		}
+        const sal_uInt16 nId = IsVisited() ? rFmt.GetVisitedFmtId() : rFmt.GetINetFmtId();
+        const String& rStr = IsVisited() ? rFmt.GetVisitedFmt() : rFmt.GetINetFmt();
+        if ( rStr.Len() == 0 )
+        {
+            ASSERT( false, "<SwTxtINetFmt::GetCharFmt()> - missing character format at hyperlink attribute");
+        }
 
-		pRet = IsPoolUserFmt( nId )
-				? ((SwDoc*)pDoc)->FindCharFmtByName( rStr )
-				: ((SwDoc*)pDoc)->GetCharFmtFromPool( nId );
+        // JP 10.02.2000, Bug 72806: dont modify the doc for getting the
+        //		correct charstyle.
+        sal_Bool bResetMod = !pDoc->IsModified();
+        Link aOle2Lnk;
+        if ( bResetMod )
+        {
+            aOle2Lnk = pDoc->GetOle2Link();
+            ( (SwDoc*) pDoc )->SetOle2Link( Link() );
+        }
 
-		if( bResetMod )
-		{
-			((SwDoc*)pDoc)->ResetModified();
-			((SwDoc*)pDoc)->SetOle2Link( aOle2Lnk );
-		}
-	}
+        pRet = IsPoolUserFmt( nId )
+               ? ( (SwDoc*) pDoc )->FindCharFmtByName( rStr )
+               : ( (SwDoc*) pDoc )->GetCharFmtFromPool( nId );
 
-	if( pRet )
-		pRet->Add( this );
-	else if( GetRegisteredIn() )
-		GetRegisteredInNonConst()->Remove( this );
+        if ( bResetMod )
+        {
+            ( (SwDoc*) pDoc )->ResetModified();
+            ( (SwDoc*) pDoc )->SetOle2Link( aOle2Lnk );
+        }
+    }
 
-	return pRet;
+    if ( pRet )
+        pRet->Add( this );
+    else if ( GetRegisteredIn() )
+        GetRegisteredInNonConst()->Remove( this );
+
+    return pRet;
 }
 
 void SwTxtINetFmt::Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew )

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/undo/undobj.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/undo/undobj.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/undo/undobj.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/undo/undobj.cxx Wed Mar 19 10:14:42 2014
@@ -47,17 +47,24 @@
 #include <comcore.hrc>
 #include <docsh.hxx>
 
-class SwRedlineSaveData : public SwUndRng, public SwRedlineData,
-						  private SwUndoSaveSection
+class SwRedlineSaveData: public SwUndRng, public SwRedlineData, private SwUndoSaveSection
 {
 public:
-	SwRedlineSaveData( SwComparePosition eCmpPos,
-						const SwPosition& rSttPos, const SwPosition& rEndPos,
-						SwRedline& rRedl, sal_Bool bCopyNext );
-	~SwRedlineSaveData();
-	void RedlineToDoc( SwPaM& rPam );
-	SwNodeIndex* GetMvSttIdx() const
-		{ return SwUndoSaveSection::GetMvSttIdx(); }
+    SwRedlineSaveData(
+        SwComparePosition eCmpPos,
+        const SwPosition& rSttPos,
+        const SwPosition& rEndPos,
+        SwRedline& rRedl,
+        sal_Bool bCopyNext );
+
+    ~SwRedlineSaveData();
+
+    void RedlineToDoc( SwPaM& rPam );
+
+    SwNodeIndex* GetMvSttIdx() const
+    {
+        return SwUndoSaveSection::GetMvSttIdx();
+    }
 
 #ifdef DBG_UTIL
     sal_uInt16 nRedlineCount;
@@ -246,7 +253,7 @@ void SwUndo::UndoWithContext(SfxUndoCont
             dynamic_cast< ::sw::UndoRedoContext * >(& rContext));
     OSL_ASSERT(pContext);
     if (!pContext) { return; }
-    UndoRedoRedlineGuard(*pContext, *this);
+    const UndoRedoRedlineGuard aUndoRedoRedlineGuard(*pContext, *this);
     UndoImpl(*pContext);
 }
 
@@ -256,7 +263,7 @@ void SwUndo::RedoWithContext(SfxUndoCont
             dynamic_cast< ::sw::UndoRedoContext * >(& rContext));
     OSL_ASSERT(pContext);
     if (!pContext) { return; }
-    UndoRedoRedlineGuard(*pContext, *this);
+    const UndoRedoRedlineGuard aUndoRedoRedlineGuard(*pContext, *this);
     RedoImpl(*pContext);
 }
 
@@ -907,12 +914,21 @@ void SwUndoSaveSection::SaveSection( SwD
 }
 
 
-void SwUndoSaveSection::SaveSection( SwDoc* , const SwNodeRange& rRange )
+void SwUndoSaveSection::SaveSection(
+    SwDoc* pDoc,
+    const SwNodeRange& rRange )
 {
-	SwPaM aPam( rRange.aStart, rRange.aEnd );
+    SwPaM aPam( rRange.aStart, rRange.aEnd );
 
-	// loesche alle Fussnoten / FlyFrames / Bookmarks / Verzeichnisse
-	DelCntntIndex( *aPam.GetMark(), *aPam.GetPoint() );
+    // delete all footnotes, fly frames, bookmarks and indexes
+    DelCntntIndex( *aPam.GetMark(), *aPam.GetPoint() );
+    {
+        // move certain indexes out of deleted range
+        SwNodeIndex aSttIdx( aPam.Start()->nNode.GetNode() );
+        SwNodeIndex aEndIdx( aPam.End()->nNode.GetNode() );
+        SwNodeIndex aMvStt( aEndIdx, 1 );
+        pDoc->CorrAbs( aSttIdx, aEndIdx, SwPosition( aMvStt ), sal_True );
+    }
 
 	pRedlSaveData = new SwRedlineSaveDatas;
 	if( !SwUndo::FillSaveData( aPam, *pRedlSaveData, sal_True, sal_True ))
@@ -981,50 +997,51 @@ void SwUndoSaveSection::RestoreSection( 
 
 		// sicher und setze die RedlineDaten
 
-SwRedlineSaveData::SwRedlineSaveData( SwComparePosition eCmpPos,
-										const SwPosition& rSttPos,
-										const SwPosition& rEndPos,
-										SwRedline& rRedl,
-										sal_Bool bCopyNext )
-	: SwUndRng( rRedl ),
-	SwRedlineData( rRedl.GetRedlineData(), bCopyNext )
+SwRedlineSaveData::SwRedlineSaveData(
+    SwComparePosition eCmpPos,
+    const SwPosition& rSttPos,
+    const SwPosition& rEndPos,
+    SwRedline& rRedl,
+    sal_Bool bCopyNext )
+    : SwUndRng( rRedl )
+    , SwRedlineData( rRedl.GetRedlineData(), bCopyNext )
 {
-	ASSERT( POS_OUTSIDE == eCmpPos ||
-			!rRedl.GetContentIdx(), "Redline mit Content" );
+    ASSERT( POS_OUTSIDE == eCmpPos || !rRedl.GetContentIdx(), "Redline mit Content" );
 
-	switch( eCmpPos )
-	{
-	case POS_OVERLAP_BEFORE:		// Pos1 ueberlappt Pos2 am Anfang
-		nEndNode = rEndPos.nNode.GetIndex();
-		nEndCntnt = rEndPos.nContent.GetIndex();
-		break;
-	case POS_OVERLAP_BEHIND: 		// Pos1 ueberlappt Pos2 am Ende
-		nSttNode = rSttPos.nNode.GetIndex();
-		nSttCntnt = rSttPos.nContent.GetIndex();
-		break;
-
-	case POS_INSIDE:				// Pos1 liegt vollstaendig in Pos2
-		nSttNode = rSttPos.nNode.GetIndex();
-		nSttCntnt = rSttPos.nContent.GetIndex();
-		nEndNode = rEndPos.nNode.GetIndex();
-		nEndCntnt = rEndPos.nContent.GetIndex();
-		break;
+    switch (eCmpPos)
+    {
+    case POS_OVERLAP_BEFORE:		// Pos1 ueberlappt Pos2 am Anfang
+        nEndNode = rEndPos.nNode.GetIndex();
+        nEndCntnt = rEndPos.nContent.GetIndex();
+        break;
 
-	case POS_OUTSIDE:				// Pos2 liegt vollstaendig in Pos1
-		if( rRedl.GetContentIdx() )
-		{
-			// dann den Bereich ins UndoArray verschieben und merken
-			SaveSection( rRedl.GetDoc(), *rRedl.GetContentIdx() );
-			rRedl.SetContentIdx( 0 );
-		}
-		break;
+    case POS_OVERLAP_BEHIND: 		// Pos1 ueberlappt Pos2 am Ende
+        nSttNode = rSttPos.nNode.GetIndex();
+        nSttCntnt = rSttPos.nContent.GetIndex();
+        break;
 
-	case POS_EQUAL:					// Pos1 ist genauso gross wie Pos2
-		break;
+    case POS_INSIDE:				// Pos1 liegt vollstaendig in Pos2
+        nSttNode = rSttPos.nNode.GetIndex();
+        nSttCntnt = rSttPos.nContent.GetIndex();
+        nEndNode = rEndPos.nNode.GetIndex();
+        nEndCntnt = rEndPos.nContent.GetIndex();
+        break;
 
-	default:
-		ASSERT( !this, "keine gueltigen Daten!" )
-	}
+    case POS_OUTSIDE:				// Pos2 liegt vollstaendig in Pos1
+        if ( rRedl.GetContentIdx() )
+        {
+            // dann den Bereich ins UndoArray verschieben und merken
+            SaveSection( rRedl.GetDoc(), *rRedl.GetContentIdx() );
+            rRedl.SetContentIdx( 0 );
+        }
+        break;
+
+    case POS_EQUAL:					// Pos1 ist genauso gross wie Pos2
+        break;
+
+    default:
+        ASSERT( !this, "keine gueltigen Daten!" )
+    }
 
 #ifdef DBG_UTIL
     nRedlineCount = rSttPos.nNode.GetNode().GetDoc()->GetRedlineTbl().Count();
@@ -1069,68 +1086,82 @@ void SwRedlineSaveData::RedlineToDoc( Sw
 	rDoc.SetRedlineMode_intern( eOld );
 }
 
-sal_Bool SwUndo::FillSaveData( const SwPaM& rRange, SwRedlineSaveDatas& rSData,
-							sal_Bool bDelRange, sal_Bool bCopyNext )
+
+sal_Bool SwUndo::FillSaveData(
+    const SwPaM& rRange,
+    SwRedlineSaveDatas& rSData,
+    sal_Bool bDelRange,
+    sal_Bool bCopyNext )
 {
-	if( rSData.Count() )
-		rSData.DeleteAndDestroy( 0, rSData.Count() );
+    if ( rSData.Count() )
+    {
+        rSData.DeleteAndDestroy( 0, rSData.Count() );
+    }
 
-	SwRedlineSaveData* pNewData;
-	const SwPosition *pStt = rRange.Start(), *pEnd = rRange.End();
-	const SwRedlineTbl& rTbl = rRange.GetDoc()->GetRedlineTbl();
-	sal_uInt16 n = 0;
-	rRange.GetDoc()->GetRedline( *pStt, &n );
-	for( ; n < rTbl.Count(); ++n )
-	{
-		SwRedline* pRedl = rTbl[ n ];
-		const SwPosition *pRStt = pRedl->Start(), *pREnd = pRedl->End();
+    SwRedlineSaveData* pNewData;
+    const SwPosition* pStt = rRange.Start();
+    const SwPosition* pEnd = rRange.End();
+    const SwRedlineTbl& rTbl = rRange.GetDoc()->GetRedlineTbl();
+    sal_uInt16 n = 0;
+    rRange.GetDoc()->GetRedline( *pStt, &n );
+    for ( ; n < rTbl.Count(); ++n )
+    {
+        SwRedline* pRedl = rTbl[n];
 
-		SwComparePosition eCmpPos = ComparePosition( *pStt, *pEnd, *pRStt, *pREnd );
-		if( POS_BEFORE != eCmpPos && POS_BEHIND != eCmpPos &&
-			POS_COLLIDE_END != eCmpPos && POS_COLLIDE_START != eCmpPos )
-		{
-			pNewData = new SwRedlineSaveData( eCmpPos, *pStt, *pEnd,
-												*pRedl, bCopyNext );
-			rSData.Insert( pNewData, rSData.Count() );
-		}
-	}
-	if( rSData.Count() && bDelRange )
+        const SwComparePosition eCmpPos =
+            ComparePosition( *pStt, *pEnd, *pRedl->Start(), *pRedl->End() );
+        if ( eCmpPos != POS_BEFORE
+             && eCmpPos != POS_BEHIND
+             && eCmpPos != POS_COLLIDE_END
+             && eCmpPos != POS_COLLIDE_START )
+        {
+            pNewData = new SwRedlineSaveData( eCmpPos, *pStt, *pEnd, *pRedl, bCopyNext );
+            rSData.Insert( pNewData, rSData.Count() );
+        }
+    }
+    if ( rSData.Count() && bDelRange )
+    {
         rRange.GetDoc()->DeleteRedline( rRange, false, USHRT_MAX );
-	return 0 != rSData.Count();
+    }
+    return 0 != rSData.Count();
 }
 
-sal_Bool SwUndo::FillSaveDataForFmt( const SwPaM& rRange, SwRedlineSaveDatas& rSData )
-{
-	if( rSData.Count() )
-		rSData.DeleteAndDestroy( 0, rSData.Count() );
 
-	SwRedlineSaveData* pNewData;
-	const SwPosition *pStt = rRange.Start(), *pEnd = rRange.End();
-	const SwRedlineTbl& rTbl = rRange.GetDoc()->GetRedlineTbl();
-	sal_uInt16 n = 0;
-	rRange.GetDoc()->GetRedline( *pStt, &n );
-	for( ; n < rTbl.Count(); ++n )
-	{
-		SwRedline* pRedl = rTbl[ n ];
-        if( nsRedlineType_t::REDLINE_FORMAT == pRedl->GetType() )
-		{
-			const SwPosition *pRStt = pRedl->Start(), *pREnd = pRedl->End();
-
-			SwComparePosition eCmpPos = ComparePosition( *pStt, *pEnd, *pRStt, *pREnd );
-			if( POS_BEFORE != eCmpPos && POS_BEHIND != eCmpPos &&
-				POS_COLLIDE_END != eCmpPos && POS_COLLIDE_START != eCmpPos )
-			{
-				pNewData = new SwRedlineSaveData( eCmpPos, *pStt, *pEnd,
-													*pRedl, sal_True );
-				rSData.Insert( pNewData, rSData.Count() );
-			}
+sal_Bool SwUndo::FillSaveDataForFmt(
+    const SwPaM& rRange,
+    SwRedlineSaveDatas& rSData )
+{
+    if ( rSData.Count() )
+    {
+        rSData.DeleteAndDestroy( 0, rSData.Count() );
+    }
 
+    SwRedlineSaveData* pNewData;
+    const SwPosition *pStt = rRange.Start(), *pEnd = rRange.End();
+    const SwRedlineTbl& rTbl = rRange.GetDoc()->GetRedlineTbl();
+    sal_uInt16 n = 0;
+    rRange.GetDoc()->GetRedline( *pStt, &n );
+    for ( ; n < rTbl.Count(); ++n )
+    {
+        SwRedline* pRedl = rTbl[n];
+        if ( nsRedlineType_t::REDLINE_FORMAT == pRedl->GetType() )
+        {
+            const SwComparePosition eCmpPos = ComparePosition( *pStt, *pEnd, *pRedl->Start(), *pRedl->End() );
+            if ( eCmpPos != POS_BEFORE
+                 && eCmpPos != POS_BEHIND
+                 && eCmpPos != POS_COLLIDE_END
+                 && eCmpPos != POS_COLLIDE_START )
+            {
+                pNewData = new SwRedlineSaveData( eCmpPos, *pStt, *pEnd, *pRedl, sal_True );
+                rSData.Insert( pNewData, rSData.Count() );
+            }
 
-		}
-	}
-	return 0 != rSData.Count();
+        }
+    }
+    return 0 != rSData.Count();
 }
 
+
 void SwUndo::SetSaveData( SwDoc& rDoc, const SwRedlineSaveDatas& rSData )
 {
     RedlineMode_t eOld = rDoc.GetRedlineMode();

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/undo/unnum.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/undo/unnum.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/undo/unnum.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/undo/unnum.cxx Wed Mar 19 10:14:42 2014
@@ -136,22 +136,18 @@ void SwUndoInsNum::RedoImpl(::sw::UndoRe
 {
     SwDoc & rDoc = rContext.GetDoc();
 
-	if( pOldNumRule )
-		rDoc.ChgNumRuleFmts( aNumRule );
-	else if( pHistory )
+    if ( pOldNumRule )
+        rDoc.ChgNumRuleFmts( aNumRule );
+    else if ( pHistory )
     {
-        SwPaM & rPam( AddUndoRedoPaM(rContext) );
-		if( sReplaceRule.Len() )
+        SwPaM & rPam( AddUndoRedoPaM( rContext ) );
+        if ( sReplaceRule.Len() )
         {
-            rDoc.ReplaceNumRule(*rPam.GetPoint(),
-								sReplaceRule, aNumRule.GetName() );
+            rDoc.ReplaceNumRule( *rPam.GetPoint(), sReplaceRule, aNumRule.GetName() );
         }
-		else
+        else
         {
-            // --> OD 2005-02-25 #i42921# - adapt to changed signature
-            // --> OD 2008-03-18 #refactorlists#
-            rDoc.SetNumRule(rPam, aNumRule, false);
-            // <--
+            rDoc.SetNumRule( rPam, aNumRule, false );
         }
     }
 }
@@ -164,18 +160,15 @@ void SwUndoInsNum::SetLRSpaceEndPos()
 
 void SwUndoInsNum::RepeatImpl(::sw::RepeatContext & rContext)
 {
-    SwDoc & rDoc(rContext.GetDoc());
-	if( nSttNode )
-	{
-		if( !sReplaceRule.Len() )
+    SwDoc & rDoc( rContext.GetDoc() );
+    if ( nSttNode )
+    {
+        if ( !sReplaceRule.Len() )
         {
-            // --> OD 2005-02-25 #i42921# - adapt to changed signature
-            // --> OD 2008-03-18 #refactorlists#
-            rDoc.SetNumRule(rContext.GetRepeatPaM(), aNumRule, false);
-            // <--
+            rDoc.SetNumRule( rContext.GetRepeatPaM(), aNumRule, false );
         }
-	}
-	else
+    }
+    else
     {
         rDoc.ChgNumRuleFmts( aNumRule );
     }

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/undo/unredln.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/undo/unredln.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/undo/unredln.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/undo/unredln.cxx Wed Mar 19 10:14:42 2014
@@ -46,18 +46,18 @@ extern void lcl_GetJoinFlags( SwPaM& rPa
 
 SwUndoRedline::SwUndoRedline( SwUndoId nUsrId, const SwPaM& rRange )
 	: SwUndo( UNDO_REDLINE ), SwUndRng( rRange ),
-	pRedlData( 0 ), pRedlSaveData( 0 ), nUserId( nUsrId ),
-	bHiddenRedlines( sal_False )
+	mpRedlData( 0 ), mpRedlSaveData( 0 ), mnUserId( nUsrId ),
+	mbHiddenRedlines( sal_False )
 {
 	// Redline beachten
 	SwDoc& rDoc = *rRange.GetDoc();
 	if( rDoc.IsRedlineOn() )
 	{
-		switch( nUserId )
+		switch( mnUserId )
 		{
 		case UNDO_DELETE:
 		case UNDO_REPLACE:
-			pRedlData = new SwRedlineData( nsRedlineType_t::REDLINE_DELETE, rDoc.GetRedlineAuthor() );
+			mpRedlData = new SwRedlineData( nsRedlineType_t::REDLINE_DELETE, rDoc.GetRedlineAuthor() );
 			break;
         default:
             ;
@@ -67,14 +67,14 @@ SwUndoRedline::SwUndoRedline( SwUndoId n
 
 	sal_uLong nEndExtra = rDoc.GetNodes().GetEndOfExtras().GetIndex();
 
-	pRedlSaveData = new SwRedlineSaveDatas;
-	if( !FillSaveData( rRange, *pRedlSaveData, sal_False,
-						UNDO_REJECT_REDLINE != nUserId ))
-		delete pRedlSaveData, pRedlSaveData = 0;
+	mpRedlSaveData = new SwRedlineSaveDatas;
+	if( !FillSaveData( rRange, *mpRedlSaveData, sal_False,
+						UNDO_REJECT_REDLINE != mnUserId ))
+		delete mpRedlSaveData, mpRedlSaveData = 0;
 	else
 	{
-		bHiddenRedlines = HasHiddenRedlines( *pRedlSaveData );
-		if( bHiddenRedlines ) 			// dann muessen die NodeIndizies
+		mbHiddenRedlines = HasHiddenRedlines( *mpRedlSaveData );
+		if( mbHiddenRedlines ) 			// dann muessen die NodeIndizies
 		{   							// vom SwUndRng korrigiert werden
 			nEndExtra -= rDoc.GetNodes().GetEndOfExtras().GetIndex();
 			nSttNode -= nEndExtra;
@@ -85,13 +85,13 @@ SwUndoRedline::SwUndoRedline( SwUndoId n
 
 SwUndoRedline::~SwUndoRedline()
 {
-	delete pRedlData;
-	delete pRedlSaveData;
+	delete mpRedlData;
+	delete mpRedlSaveData;
 }
 
 sal_uInt16 SwUndoRedline::GetRedlSaveCount() const
 {
-    return pRedlSaveData ? pRedlSaveData->Count() : 0;
+    return mpRedlSaveData ? mpRedlSaveData->Count() : 0;
 }
 
 
@@ -102,13 +102,13 @@ void SwUndoRedline::UndoImpl(::sw::UndoR
 
     UndoRedlineImpl(*pDoc, rPam);
 
-	if( pRedlSaveData )
+	if( mpRedlSaveData )
 	{
 		sal_uLong nEndExtra = pDoc->GetNodes().GetEndOfExtras().GetIndex();
-		SetSaveData( *pDoc, *pRedlSaveData );
-		if( bHiddenRedlines )
+		SetSaveData( *pDoc, *mpRedlSaveData );
+		if( mbHiddenRedlines )
 		{
-			pRedlSaveData->DeleteAndDestroy( 0, pRedlSaveData->Count() );
+			mpRedlSaveData->DeleteAndDestroy( 0, mpRedlSaveData->Count() );
 
 			nEndExtra = pDoc->GetNodes().GetEndOfExtras().GetIndex() - nEndExtra;
 			nSttNode += nEndExtra;
@@ -126,11 +126,11 @@ void SwUndoRedline::RedoImpl(::sw::UndoR
 	pDoc->SetRedlineMode_intern((RedlineMode_t)(( eOld & ~nsRedlineMode_t::REDLINE_IGNORE) | nsRedlineMode_t::REDLINE_ON ));
 
     SwPaM & rPam( AddUndoRedoPaM(rContext) );
-	if( pRedlSaveData && bHiddenRedlines )
+	if( mpRedlSaveData && mbHiddenRedlines )
 	{
 		sal_uLong nEndExtra = pDoc->GetNodes().GetEndOfExtras().GetIndex();
-        FillSaveData(rPam, *pRedlSaveData, sal_False,
-						UNDO_REJECT_REDLINE != nUserId );
+        FillSaveData(rPam, *mpRedlSaveData, sal_False,
+						UNDO_REJECT_REDLINE != mnUserId );
 
 		nEndExtra -= pDoc->GetNodes().GetEndOfExtras().GetIndex();
 		nSttNode -= nEndExtra;
@@ -161,7 +161,7 @@ SwUndoRedlineDelete::SwUndoRedlineDelete
 	bCanGroup( sal_False ), bIsDelim( sal_False ), bIsBackspace( sal_False )
 {
 	const SwTxtNode* pTNd;
-	if( UNDO_DELETE == nUserId &&
+	if( UNDO_DELETE == mnUserId &&
 		nSttNode == nEndNode && nSttCntnt + 1 == nEndCntnt &&
 		0 != (pTNd = rRange.GetNode()->GetTxtNode()) )
 	{
@@ -187,14 +187,14 @@ void SwUndoRedlineDelete::RedoRedlineImp
 {
     if (rPam.GetPoint() != rPam.GetMark())
     {
-        rDoc.AppendRedline( new SwRedline(*pRedlData, rPam), sal_False );
+        rDoc.AppendRedline( new SwRedline(*mpRedlData, rPam), sal_False );
     }
 }
 
 sal_Bool SwUndoRedlineDelete::CanGrouping( const SwUndoRedlineDelete& rNext )
 {
 	sal_Bool bRet = sal_False;
-	if( UNDO_DELETE == nUserId && nUserId == rNext.nUserId &&
+	if( UNDO_DELETE == mnUserId && mnUserId == rNext.mnUserId &&
 		bCanGroup == rNext.bCanGroup &&
 		bIsDelim == rNext.bIsDelim &&
 		bIsBackspace == rNext.bIsBackspace &&
@@ -209,10 +209,10 @@ sal_Bool SwUndoRedlineDelete::CanGroupin
 			bIsEnd = -1;
 
 		if( bIsEnd &&
-			(( !pRedlSaveData && !rNext.pRedlSaveData ) ||
-			 ( pRedlSaveData && rNext.pRedlSaveData &&
-				SwUndo::CanRedlineGroup( *pRedlSaveData,
-							*rNext.pRedlSaveData, 1 != bIsEnd )
+			(( !mpRedlSaveData && !rNext.mpRedlSaveData ) ||
+			 ( mpRedlSaveData && rNext.mpRedlSaveData &&
+				SwUndo::CanRedlineGroup( *mpRedlSaveData,
+							*rNext.mpRedlSaveData, 1 != bIsEnd )
 			 )))
 		{
 			if( 1 == bIsEnd )

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unocrsrhelper.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unocrsrhelper.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unocrsrhelper.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unocrsrhelper.cxx Wed Mar 19 10:14:42 2014
@@ -307,7 +307,7 @@ sal_Bool getCrsrPropertyValue(
                 getNumberingProperty(rPam, eNewState, pAny);
             else
             {
-                if( !rPam.GetDoc()->GetCurrNumRule( *rPam.GetPoint() ) )
+                if( !rPam.GetDoc()->GetNumRuleAtPos( *rPam.GetPoint() ) )
                     eNewState = PropertyState_DEFAULT_VALUE;
             }
             break;
@@ -686,55 +686,42 @@ void setNumberingProperty(const Any& rVa
 				}
                 UnoActionContext aAction(pDoc);
 
-                if( rPam.GetNext() != &rPam )           // Mehrfachselektion ?
-				{
+                if ( rPam.GetNext() != &rPam )           // Mehrfachselektion ?
+                {
                     pDoc->GetIDocumentUndoRedo().StartUndo( UNDO_START, NULL );
-					SwPamRanges aRangeArr( rPam );
-					SwPaM aPam( *rPam.GetPoint() );
-					for( sal_uInt16 n = 0; n < aRangeArr.Count(); ++n )
+                    SwPamRanges aRangeArr( rPam );
+                    SwPaM aPam( *rPam.GetPoint() );
+                    for ( sal_uInt16 n = 0; n < aRangeArr.Count(); ++n )
                     {
-                        // --> OD 2008-03-17 #refactorlists#
-                        // no start of a new list
                         pDoc->SetNumRule( aRangeArr.SetPam( n, aPam ), aRule, false );
-                        // <--
                     }
                     pDoc->GetIDocumentUndoRedo().EndUndo( UNDO_END, NULL );
                 }
                 else
                 {
-                    // --> OD 2008-03-17 #refactorlists#
-                    // no start of a new list
                     pDoc->SetNumRule( rPam, aRule, false );
-                    // <--
                 }
-
-
-			}
-			else if(pSwNum->GetCreatedNumRuleName().Len())
-			{
-				UnoActionContext aAction(pDoc);
-				SwNumRule* pRule = pDoc->FindNumRulePtr( pSwNum->GetCreatedNumRuleName() );
-				if(!pRule)
-					throw RuntimeException();
-                // --> OD 2008-03-17 #refactorlists#
-                // no start of a new list
+            }
+            else if ( pSwNum->GetCreatedNumRuleName().Len() )
+            {
+                UnoActionContext aAction( pDoc );
+                SwNumRule* pRule = pDoc->FindNumRulePtr( pSwNum->GetCreatedNumRuleName() );
+                if ( !pRule )
+                    throw RuntimeException();
                 pDoc->SetNumRule( rPam, *pRule, false );
-                // <--
-			}
-            // --> OD 2009-08-18 #i103817#
-            // outline numbering
+            }
             else
             {
+                // outline numbering
                 UnoActionContext aAction(pDoc);
                 SwNumRule* pRule = pDoc->GetOutlineNumRule();
                 if(!pRule)
                     throw RuntimeException();
                 pDoc->SetNumRule( rPam, *pRule, false );
             }
-            // <--
-		}
-	}
-    else if(rValue.getValueType() == ::getVoidCppuType())
+        }
+    }
+    else if ( rValue.getValueType() == ::getVoidCppuType() )
     {
         rPam.GetDoc()->DelNumRules(rPam);
     }
@@ -746,7 +733,7 @@ void setNumberingProperty(const Any& rVa
  * --------------------------------------------------*/
 void  getNumberingProperty(SwPaM& rPam, PropertyState& eState, Any * pAny )
 {
-	const SwNumRule* pNumRule = rPam.GetDoc()->GetCurrNumRule( *rPam.GetPoint() );
+	const SwNumRule* pNumRule = rPam.GetDoc()->GetNumRuleAtPos( *rPam.GetPoint() );
 	if(pNumRule)
 	{
 		uno::Reference< XIndexReplace >  xNum = new SwXNumberingRules(*pNumRule);

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unodraw.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unodraw.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unodraw.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unodraw.cxx Wed Mar 19 10:14:42 2014
@@ -759,7 +759,7 @@ void SwXDrawPage::add(const uno::Referen
 	if ( !pTemp )
 		pTemp = pPam;
 	UnoActionContext aAction(pDoc);
-	pDoc->Insert( *pTemp, *pObj, &aSet, NULL );
+	pDoc->InsertDrawObj( *pTemp, *pObj, aSet );
 	SwFrmFmt* pFmt = ::FindFrmFmt( pObj );
 	if(pFmt)
 		pFmt->Add(pShape);

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoobj.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoobj.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoobj.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoobj.cxx Wed Mar 19 10:14:42 2014
@@ -1300,22 +1300,6 @@ throw (uno::RuntimeException)
         throw uno::RuntimeException();
     }
 
-    SwStartNodeType eSearchNodeType = SwNormalStartNode;
-    switch (m_pImpl->m_eType)
-    {
-        case CURSOR_FRAME:      eSearchNodeType = SwFlyStartNode;       break;
-        case CURSOR_TBLTEXT:    eSearchNodeType = SwTableBoxStartNode;  break;
-        case CURSOR_FOOTNOTE:   eSearchNodeType = SwFootnoteStartNode;  break;
-        case CURSOR_HEADER:     eSearchNodeType = SwHeaderStartNode;    break;
-        case CURSOR_FOOTER:     eSearchNodeType = SwFooterStartNode;    break;
-        //case CURSOR_INVALID:
-        //case CURSOR_BODY:
-        default:
-            ;
-    }
-    const SwStartNode* pOwnStartNode =
-        rOwnCursor.GetNode()->FindSttNodeByType(eSearchNodeType);
-
     SwPaM aPam(GetDoc()->GetNodes());
     const SwPaM * pPam(0);
     if (pCursor)
@@ -1334,21 +1318,51 @@ throw (uno::RuntimeException)
     {
         throw uno::RuntimeException();
     }
-    const SwStartNode* pTmp =
-        pPam->GetNode()->FindSttNodeByType(eSearchNodeType);
 
-    //SectionNodes ueberspringen
-    while(pTmp && pTmp->IsSectionNode())
     {
-        pTmp = pTmp->StartOfSectionNode();
-    }
-    while(pOwnStartNode && pOwnStartNode->IsSectionNode())
-    {
-        pOwnStartNode = pOwnStartNode->StartOfSectionNode();
-    }
-    if(pOwnStartNode != pTmp)
-    {
-        throw uno::RuntimeException();
+        SwStartNodeType eSearchNodeType = SwNormalStartNode;
+        switch (m_pImpl->m_eType)
+        {
+        case CURSOR_FRAME:      eSearchNodeType = SwFlyStartNode;       break;
+        case CURSOR_TBLTEXT:    eSearchNodeType = SwTableBoxStartNode;  break;
+        case CURSOR_FOOTNOTE:   eSearchNodeType = SwFootnoteStartNode;  break;
+        case CURSOR_HEADER:     eSearchNodeType = SwHeaderStartNode;    break;
+        case CURSOR_FOOTER:     eSearchNodeType = SwFooterStartNode;    break;
+            //case CURSOR_INVALID:
+            //case CURSOR_BODY:
+        default:
+            ;
+        }
+
+        const SwStartNode* pOwnStartNode = rOwnCursor.GetNode()->FindSttNodeByType(eSearchNodeType);
+        while ( pOwnStartNode != NULL
+                && pOwnStartNode->IsSectionNode())
+        {
+            pOwnStartNode = pOwnStartNode->StartOfSectionNode();
+        }
+
+        const SwStartNode* pTmp =
+            pPam->GetNode()->FindSttNodeByType(eSearchNodeType);
+        while ( pTmp != NULL
+                && pTmp->IsSectionNode() )
+        {
+            pTmp = pTmp->StartOfSectionNode();
+        }
+
+        if ( eSearchNodeType == SwTableBoxStartNode )
+        {
+            if ( pOwnStartNode->FindTableNode() != pTmp->FindTableNode() )
+            {
+                throw uno::RuntimeException();
+            }
+        }
+        else
+        {
+            if ( pOwnStartNode != pTmp )
+            {
+                throw uno::RuntimeException();
+            }
+        }
     }
 
     if (CURSOR_META == m_pImpl->m_eType)
@@ -2684,7 +2698,7 @@ throw (beans::UnknownPropertyException, 
 	return aRet;
 }
 
-void SAL_CALL SwXTextCursor::invalidateMarkings(::sal_Int32 nType) 
+void SAL_CALL SwXTextCursor::invalidateMarkings(::sal_Int32 nType)
 throw (uno::RuntimeException)
 {
     vos::OGuard aGuard(Application::GetSolarMutex());

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoportenum.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoportenum.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoportenum.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/unocore/unoportenum.cxx Wed Mar 19 10:14:42 2014
@@ -892,7 +892,7 @@ lcl_ExportHints(
                     {
 
                         pUnoCrsr->Right(
-                            pAttr->GetFmtFld().GetField()->GetPar1().Len() + 2,
+                            pAttr->GetFmtFld().GetField()->ExpandField( true ).Len() + 2,
                             CRSR_SKIP_CHARS,
                             sal_False,
                             sal_False );

Modified: openoffice/branches/alg_writerframes/main/sw/source/core/view/viewsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/core/view/viewsh.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/core/view/viewsh.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/core/view/viewsh.cxx Wed Mar 19 10:14:42 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/branches/alg_writerframes/main/sw/source/filter/html/htmldraw.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/html/htmldraw.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/html/htmldraw.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/html/htmldraw.cxx Wed Mar 19 10:14:42 2014
@@ -220,7 +220,7 @@ void SwHTMLParser::InsertDrawObject( Sdr
     }
 	aFrmSet.Put( aAnchor );
 
-	pDoc->Insert( *pPam, *pNewDrawObj, &aFrmSet, NULL );
+	pDoc->InsertDrawObj( *pPam, *pNewDrawObj, aFrmSet );
 }
 
 /*  */

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/rtf/swparrtf.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/rtf/swparrtf.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/rtf/swparrtf.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/rtf/swparrtf.cxx Wed Mar 19 10:14:42 2014
@@ -1311,7 +1311,7 @@ void SwRTFParser::ReadDrawingObject()
 
         pStroke->SetSnapRect(aRect);
 
-        /* SwFrmFmt* pRetFrmFmt = */pDoc->Insert(*pPam, *pStroke, &aFlySet, NULL);
+        /* SwFrmFmt* pRetFrmFmt = */pDoc->InsertDrawObj(*pPam, *pStroke, aFlySet );
     }
 }
 
@@ -1343,7 +1343,7 @@ void SwRTFParser::InsertShpObject(SdrObj
         SdrPage* pDrawPg = pDrawModel->GetPage(0);
         pDrawPg->InsertObject(pStroke);
         pDrawPg->SetObjectOrdNum(pStroke->GetOrdNum(), _nZOrder);
-        /* SwFrmFmt* pRetFrmFmt = */pDoc->Insert(*pPam, *pStroke, &aFlySet, NULL);
+        /* SwFrmFmt* pRetFrmFmt = */pDoc->InsertDrawObj(*pPam, *pStroke, aFlySet );
 }
 
 ::basegfx::B2DPoint rotate(const ::basegfx::B2DPoint& rStart, const ::basegfx::B2DPoint& rEnd)

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww1/fltshell.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww1/fltshell.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww1/fltshell.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww1/fltshell.cxx Wed Mar 19 10:14:42 2014
@@ -520,36 +520,33 @@ void SwFltControlStack::SetAttrInDoc(con
     case RES_TXTATR_TOXMARK:
         break;
 
-	case RES_FLTR_NUMRULE:			// Numrule 'reinsetzen
-		{
-			const String& rNumNm = ((SfxStringItem*)pEntry->pAttr)->GetValue();
-			SwNumRule* pRul = pDoc->FindNumRulePtr( rNumNm );
-			if( pRul )
-			{
-				if( pEntry->MakeRegion(pDoc, aRegion, sal_True))
-				{
-					SwNodeIndex aTmpStart( aRegion.Start()->nNode );
-					SwNodeIndex aTmpEnd( aTmpStart );
-					SwNodeIndex& rRegEndNd = aRegion.End()->nNode;
-					while( IterateNumrulePiece( rRegEndNd,
-												aTmpStart, aTmpEnd ) )
-					{
-						SwPaM aTmpPam( aTmpStart, aTmpEnd );
-                        // --> OD 2008-03-17 #refactorlists#
-                        // no start of a new list
-                        pDoc->SetNumRule( aTmpPam, *pRul, false );
-                        // <--
+    case RES_FLTR_NUMRULE:			// Numrule 'reinsetzen
+    {
+        const String& rNumNm = ( (SfxStringItem*) pEntry->pAttr )->GetValue();
+        SwNumRule* pNumRule = pDoc->FindNumRulePtr( rNumNm );
+        if ( pNumRule )
+        {
+            if ( pEntry->MakeRegion( pDoc, aRegion, sal_True ) )
+            {
+                SwNodeIndex aTmpStart( aRegion.Start()->nNode );
+                SwNodeIndex aTmpEnd( aTmpStart );
+                SwNodeIndex& rRegEndNd = aRegion.End()->nNode;
+                while (IterateNumrulePiece( rRegEndNd, aTmpStart, aTmpEnd ))
+                {
+                    SwPaM aTmpPam( aTmpStart, aTmpEnd );
+                    pDoc->SetNumRule( aTmpPam, *pNumRule, false );
 
-						aTmpStart = aTmpEnd;    // Start fuer naechstes Teilstueck
-						aTmpStart++;
-					}
-				}
-				else
-					pDoc->DelNumRule( rNumNm );
-			}
-		}
-		break;
-    case RES_FLTR_NUMRULE_NUM:
+                    aTmpStart = aTmpEnd;    // Start fuer naechstes Teilstueck
+                    aTmpStart++;
+                }
+            }
+            else
+                pDoc->DelNumRule( rNumNm );
+        }
+    }
+        break;
+
+	case RES_FLTR_NUMRULE_NUM:
         break;
     case RES_FLTR_BOOKMARK:
         {

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/WW8TableInfo.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/WW8TableInfo.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/WW8TableInfo.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/WW8TableInfo.cxx Wed Mar 19 10:14:42 2014
@@ -1341,7 +1341,7 @@ string WW8TableCellGrid::toString()
 
         WW8TableCellGridRow::Pointer_t pRow = getRow(*aTopsIt);
         WidthsPtr pWidths = pRow->getWidths();
-        if (pWidths != NULL)
+        if( bool(pWidths))
         {
             sResult += "<widths>";
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/rtfattributeoutput.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/rtfattributeoutput.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/rtfattributeoutput.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/rtfattributeoutput.cxx Wed Mar 19 10:14:42 2014
@@ -3629,6 +3629,19 @@ void RtfAttributeOutput::FlyFrameGraphic
         pGraphicAry = aGraphicLink.GetData();
         switch (aGraphicLink.GetType())
         {
+            // #15508# trying to add BMP type for better exports, need to check if this works 
+            // checked, does not work. Also need to reset pGraphicAry to NULL to force conversion
+            // to PNG, else the BMP array will be used.
+            // It may work using direct DIB data, but that needs to be checked eventually
+            //
+            // #15508# before GFX_LINK_TYPE_NATIVE_BMP was added the graphic data
+            // (to be hold in pGraphicAry) was not available; thus for now to stay 
+            // compatible, keep it that way by assigning NULL value to pGraphicAry
+            case GFX_LINK_TYPE_NATIVE_BMP:
+            //    pBLIPType = OOO_STRING_SVTOOLS_RTF_WBITMAP;
+                pGraphicAry = 0;
+                break;
+
             case GFX_LINK_TYPE_NATIVE_JPG:
                 pBLIPType = OOO_STRING_SVTOOLS_RTF_JPEGBLIP;
                 break;

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtw8sty.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtw8sty.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtw8sty.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtw8sty.cxx Wed Mar 19 10:14:42 2014
@@ -1799,7 +1799,7 @@ void WW8_WrPlcSepx::WriteSepx( SvStream&
     for (size_t i = 0; i < m_SectionAttributes.size(); i++) // all sections
     {
         WW8_PdAttrDesc *const pA = m_SectionAttributes[i].get();
-        if (pA->m_nLen && pA->m_pData != NULL)
+        if (pA->m_nLen && bool(pA->m_pData))
         {
             SVBT16 nL;
             pA->m_nSepxFcPos = rStrm.Tell();

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtww8.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtww8.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtww8.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/wrtww8.cxx Wed Mar 19 10:14:42 2014
@@ -122,9 +122,11 @@
 #include "WW8Sttbf.hxx"
 #include <editeng/charrotateitem.hxx>
 #include "WW8FibData.hxx"
-#ifndef _NUMRULE_HXX
-#include "numrule.hxx"//For i120928
-#endif
+#include "numrule.hxx"
+
+#include <boost/scoped_ptr.hpp>
+
+
 using namespace sw::util;
 using namespace sw::types;
 
@@ -2097,8 +2099,8 @@ void WW8AttributeOutput::TableVerticalCe
     const SwTableLine * pTabLine = pTabBox->GetUpper();    
     const SwTableBoxes & rTblBoxes = pTabLine->GetTabBoxes();
     
-    sal_uInt8 nBoxes = rTblBoxes.Count();
-    for ( sal_uInt8 n = 0; n < nBoxes; n++ )
+    const sal_uInt16 nBoxes = rTblBoxes.Count();
+    for ( sal_uInt16 n = 0; n < nBoxes; n++ )
     {
         const SwTableBox * pTabBox1 = rTblBoxes[n];
         const SwFrmFmt * pFrmFmt = pTabBox1->GetFrmFmt();
@@ -2289,16 +2291,16 @@ void WW8AttributeOutput::TableDefinition
         m_rWW8Export.pO->Insert( 1, m_rWW8Export.pO->Count() );
     }
 
-    ww8::TableBoxVectorPtr pTableBoxes = 
-        pTableTextNodeInfoInner->getTableBoxesOfRow();
+    ww8::TableBoxVectorPtr pTableBoxes = pTableTextNodeInfoInner->getTableBoxesOfRow();
     // number of cell written
-    sal_uInt32 nBoxes = pTableBoxes->size();
-    if (nBoxes > ww8::MAXTABLECELLS)
-        nBoxes = ww8::MAXTABLECELLS;
+    const sal_uInt16 nBoxes =
+            pTableBoxes->size() > ww8::MAXTABLECELLS
+            ? ww8::MAXTABLECELLS
+            : static_cast< sal_uInt16 >(pTableBoxes->size());
     
     // sprm header
     m_rWW8Export.InsUInt16( NS_sprm::LN_TDefTable );
-    sal_uInt16 nSprmSize = 2 + (nBoxes + 1) * 2 + nBoxes * 20;
+    const sal_uInt16 nSprmSize = 2 + (nBoxes + 1) * 2 + nBoxes * 20;
     m_rWW8Export.InsUInt16( nSprmSize ); // length
 
     // number of boxes
@@ -2338,9 +2340,9 @@ void WW8AttributeOutput::TableDefinition
                 break;
 
             default:
-                nTblOffset = rHori.GetPos();
+                nTblOffset = static_cast< sal_uInt16 >(rHori.GetPos());
                 const SvxLRSpaceItem& rLRSp = pFmt->GetLRSpace();
-                nTblOffset += rLRSp.GetLeft();
+                nTblOffset += static_cast< sal_uInt16 >(rLRSp.GetLeft());
                 break;
         }
     }
@@ -2510,7 +2512,7 @@ void WW8AttributeOutput::TableBackground
     const SwTableLine * pTabLine = pTabBox->GetUpper();
     const SwTableBoxes & rTabBoxes = pTabLine->GetTabBoxes();
 
-    sal_uInt8 nBoxes = rTabBoxes.Count();
+    const sal_uInt16 nBoxes = rTabBoxes.Count();
     if ( m_rWW8Export.bWrtWW8 )
         m_rWW8Export.InsUInt16( NS_sprm::LN_TDefTableShd );
     else
@@ -2538,18 +2540,19 @@ void WW8AttributeOutput::TableBackground
 
     if ( m_rWW8Export.bWrtWW8 )
     {
-		sal_uInt32 aSprmIds[] = {NS_sprm::LN_TCellShd, NS_sprm::LN_TCellShadow};
-        sal_uInt8 nBoxes0 = rTabBoxes.Count();
+        const sal_uInt16 aSprmIds[] = { NS_sprm::LN_TCellShd, NS_sprm::LN_TCellShadow };
+        sal_uInt16 nBoxes0 = rTabBoxes.Count();
         if (nBoxes0 > 21)
             nBoxes0 = 21;
         
-		for (sal_uInt32 m = 0; m < 2; m++)
-		{
-			m_rWW8Export.InsUInt16( aSprmIds[m] );
-			m_rWW8Export.pO->Insert( static_cast<sal_uInt8>(nBoxes0 * 10), 
-									 m_rWW8Export.pO->Count() );
+		for ( sal_uInt32 m = 0; m < 2; m++ )
+        {
+            m_rWW8Export.InsUInt16( aSprmIds[m] );
+            m_rWW8Export.pO->Insert(
+                static_cast< sal_uInt8 >( nBoxes0 * 10 ),
+                m_rWW8Export.pO->Count() );
         
-        for ( sal_uInt8 n = 0; n < nBoxes0; n++ )
+        for ( sal_uInt16 n = 0; n < nBoxes0; n++ )
         {
             const SwTableBox * pBox1 = rTabBoxes[n];
             const SwFrmFmt * pFrmFmt = pBox1->GetFrmFmt();
@@ -3107,9 +3110,6 @@ void MSWordExportBase::ExportDocument( b
     pFlyOffset = 0;
     eNewAnchorType = FLY_AT_PAGE;
     nTxtTyp = TXT_MAINTEXT;
-    // --> OD 2007-04-19 #i43447# - removed
-//    nFlyWidth = nFlyHeight = 0;
-    // <--
     nStyleBeforeFly = nLastFmtId = 0;
     pStyAttr = 0;
     pCurrentStyle = NULL;
@@ -3119,6 +3119,22 @@ void MSWordExportBase::ExportDocument( b
     if ( aTOXArr.Count() )
         aTOXArr.Remove( 0, aTOXArr.Count() );
 
+    // update layout as it is needed for the export - e.g. for the export of tables
+    boost::scoped_ptr< ViewShell > pTemporaryViewShell( 0 );
+    {
+        ViewShell* pViewShell = NULL;
+        pDoc->GetEditShell( &pViewShell );
+        if ( pViewShell == NULL )
+        {
+            pTemporaryViewShell.reset( new ViewShell( *pDoc, 0 ) );
+            pViewShell = pTemporaryViewShell.get();
+        }
+        if ( pViewShell != NULL )
+        {
+            pViewShell->CalcLayout();
+        }
+    }
+
     if ( !pOLEExp )
     {
         sal_uInt32 nSvxMSDffOLEConvFlags = 0;
@@ -3141,10 +3157,8 @@ void MSWordExportBase::ExportDocument( b
     if ( !pOCXExp )
         pOCXExp = new SwMSConvertControls( pDoc->GetDocShell(), pCurPam );
 
-    // --> OD 2007-10-08 #i81405#
     // Collect anchored objects before changing the redline mode.
     maFrames = GetFrames( *pDoc, bWriteAll? NULL : pOrigPam );
-    // <--
 
     mnRedlineMode = pDoc->GetRedlineMode();
     if ( pDoc->GetRedlineTbl().Count() )
@@ -3509,12 +3523,6 @@ void WW8Export::PrepareStorage()
 
 sal_uLong SwWW8Writer::WriteStorage()
 {
-    // #i34818# #120099# - update layout (if present), for SwWriteTable
-    ViewShell* pViewShell = NULL;
-    pDoc->GetEditShell( &pViewShell );
-    if( pViewShell != NULL )
-        pViewShell->CalcLayout();
-
     long nMaxNode = pDoc->GetNodes().Count();
     ::StartProgress( STR_STATSTR_W4WWRITE, 0, nMaxNode, pDoc->GetDocShell() );
 
@@ -3575,9 +3583,12 @@ MSWordExportBase::~MSWordExportBase()
     delete pOleMap;
 }
 
-WW8Export::WW8Export( SwWW8Writer *pWriter,
-        SwDoc *pDocument, SwPaM *pCurrentPam, SwPaM *pOriginalPam,
-        bool bIsWW8 )
+WW8Export::WW8Export(
+    SwWW8Writer *pWriter,
+    SwDoc *pDocument,
+    SwPaM *pCurrentPam,
+    SwPaM *pOriginalPam,
+    bool bIsWW8 )
     : MSWordExportBase( pDocument, pCurrentPam, pOriginalPam ),
       pO( NULL ),
       mpTableAt( NULL ),

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8atr.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8atr.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8atr.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8atr.cxx Wed Mar 19 10:14:42 2014
@@ -1680,12 +1680,12 @@ void WW8AttributeOutput::TextINetFormat(
 {
     if ( rINet.GetValue().Len() )
     {
-        sal_uInt16 nId;
+        const sal_uInt16 nId = rINet.GetINetFmtId();
         const String& rStr = rINet.GetINetFmt();
-        if ( rStr.Len() )
-            nId = rINet.GetINetFmtId();
-        else
-            nId = RES_POOLCHR_INET_NORMAL;
+        if ( rStr.Len() == 0 )
+        {
+            ASSERT( false, "WW8AttributeOutput::TextINetFormat(..) - missing unvisited character format at hyperlink attribute" );
+        }
 
         const SwCharFmt* pFmt = IsPoolUserFmt( nId )
                         ? m_rWW8Export.pDoc->FindCharFmtByName( rStr )

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf.cxx Wed Mar 19 10:14:42 2014
@@ -1409,7 +1409,7 @@ void SwWW8ImplReader::ReadGrafLayer1( WW
         if (SdrObject *pObject = ReadGrafPrimitive( nLeft, &aDo, aSet ))
         {
             pWWZOrder->InsertDrawingObject(pObject, SVBT16ToShort(aDo.dhgt));
-            SwFrmFmt *pFrm = rDoc.Insert( *pPaM, *pObject, &aSet, NULL);
+            SwFrmFmt *pFrm = rDoc.InsertDrawObj( *pPaM, *pObject, aSet );
             pObject->SetMergedItemSet(aSet);
             pAnchorStck->AddAnchor(*pPaM->GetPoint(), pFrm);
         }
@@ -2839,7 +2839,7 @@ SwFrmFmt* SwWW8ImplReader::Read_GrafLaye
                 pWWZOrder->InsertTextLayerObject(pObject);
             }
 
-            pRetFrmFmt = rDoc.Insert(*pPaM, *pObject, &aFlySet, NULL);
+            pRetFrmFmt = rDoc.InsertDrawObj(*pPaM, *pObject, aFlySet );
 
             ASSERT(pRetFrmFmt->GetAnchor().GetAnchorId() ==
                 eAnchor, "Not the anchor type requested!");

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf2.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf2.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf2.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8graf2.cxx Wed Mar 19 10:14:42 2014
@@ -696,7 +696,7 @@ SwFrmFmt* SwWW8ImplReader::ImportGraf(Sd
                             }
                         }
                         else
-                            pRet = rDoc.Insert(*pPaM, *pObject, &aAttrSet, NULL);
+                            pRet = rDoc.InsertDrawObj(*pPaM, *pObject, aAttrSet );
                     }
                 }
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par4.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par4.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par4.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par4.cxx Wed Mar 19 10:14:42 2014
@@ -310,7 +310,7 @@ SwFrmFmt* SwWW8ImplReader::ImportOle(con
             SdrObject::Free( pRet );        // das brauchen wir nicht mehr
         }
         else
-            pFmt = rDoc.Insert(*pPaM, *pRet, pFlySet, NULL);
+            pFmt = rDoc.InsertDrawObj(*pPaM, *pRet, *pFlySet );
     }
     else if (
                 GRAPHIC_GDIMETAFILE == aGraph.GetType() ||

Modified: openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par5.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par5.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par5.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/filter/ww8/ww8par5.cxx Wed Mar 19 10:14:42 2014
@@ -2195,13 +2195,11 @@ eF_ResT SwWW8ImplReader::Read_F_PgRef( W
             sURL += sBookmarkName;
             const String sTarget;
             SwFmtINetFmt aURL( sURL, sTarget );
-            String sLinkStyle = String::CreateFromAscii("Index Link");
-            sal_uInt16 nPoolId =
+            const String sLinkStyle = String::CreateFromAscii("Index Link");
+            const sal_uInt16 nPoolId =
                 SwStyleNameMapper::GetPoolIdFromUIName( sLinkStyle, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT );
-            aURL.SetVisitedFmt(sLinkStyle);
-            aURL.SetINetFmt(sLinkStyle);
-            aURL.SetVisitedFmtId(nPoolId);
-            aURL.SetINetFmtId(nPoolId);
+            aURL.SetVisitedFmtAndId( sLinkStyle, nPoolId);
+            aURL.SetINetFmtAndId( sLinkStyle, nPoolId );
             pCtrlStck->NewAttr( *pPaM->GetPoint(), aURL );
         }
         return FLD_TEXT;
@@ -3659,10 +3657,8 @@ eF_ResT SwWW8ImplReader::Read_F_Hyperlin
         String sLinkStyle = String::CreateFromAscii("Index Link");
         sal_uInt16 nPoolId =
             SwStyleNameMapper::GetPoolIdFromUIName( sLinkStyle, nsSwGetPoolIdFromName::GET_POOLID_CHRFMT );
-        aURL.SetVisitedFmt(sLinkStyle);
-        aURL.SetINetFmt(sLinkStyle);
-        aURL.SetVisitedFmtId(nPoolId);
-        aURL.SetINetFmtId(nPoolId);
+        aURL.SetVisitedFmtAndId( sLinkStyle, nPoolId );
+        aURL.SetINetFmtAndId( sLinkStyle, nPoolId );
     }
 
     //As an attribute this needs to be closed, and that'll happen from

Modified: openoffice/branches/alg_writerframes/main/sw/source/ui/app/appenv.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/ui/app/appenv.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/ui/app/appenv.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/ui/app/appenv.cxx Wed Mar 19 10:14:42 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/branches/alg_writerframes/main/sw/source/ui/app/applab.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/ui/app/applab.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/ui/app/applab.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/ui/app/applab.cxx Wed Mar 19 10:14:42 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/branches/alg_writerframes/main/sw/source/ui/app/appopt.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/ui/app/appopt.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/ui/app/appopt.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/ui/app/appopt.cxx Wed Mar 19 10:14:42 2014
@@ -298,7 +298,7 @@ void SwModule::ApplyItemSet( sal_uInt16 
     {
         // the text dialog mustn't apply data to the web view and vice versa
         sal_Bool bWebView = 0 != PTR_CAST(SwWebView, pAppView);
-        if( (bWebView == bTextDialog))
+        if( bWebView == bTextDialog)
             pAppView = 0; //
     }
 

Modified: openoffice/branches/alg_writerframes/main/sw/source/ui/app/docsh.cxx
URL: http://svn.apache.org/viewvc/openoffice/branches/alg_writerframes/main/sw/source/ui/app/docsh.cxx?rev=1579184&r1=1579183&r2=1579184&view=diff
==============================================================================
--- openoffice/branches/alg_writerframes/main/sw/source/ui/app/docsh.cxx (original)
+++ openoffice/branches/alg_writerframes/main/sw/source/ui/app/docsh.cxx Wed Mar 19 10:14:42 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 );



Mime
View raw message