diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2007-05-25 11:12:32 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2007-05-25 11:12:32 +0000 |
commit | 36dd6e9a3c7b4e8788116103571c97291fafe690 (patch) | |
tree | a21d202aa6a8f5d499ffe432256e7ffe6332e9c5 /starmath/source/document.cxx | |
parent | 848d8319e150d094045cfdd1153a90aa2bc36460 (diff) |
INTEGRATION: CWS tl32 (1.85.18); FILE MERGED
2006/12/01 12:07:49 tl 1.85.18.4: RESYNC: (1.85-1.86); FILE MERGED
2006/11/02 15:13:54 tl 1.85.18.3: #i69286# make starmath warning-free for unxsols4(.pro)
2006/11/01 13:10:06 tl 1.85.18.2: #i69286# make starmath warning-free for unxlngi6(.pro)
2006/10/30 10:35:09 tl 1.85.18.1: #i69286# make starmath warning-free
Diffstat (limited to 'starmath/source/document.cxx')
-rw-r--r-- | starmath/source/document.cxx | 84 |
1 files changed, 39 insertions, 45 deletions
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx index b651cc9f90e0..33c44b5ce6ce 100644 --- a/starmath/source/document.cxx +++ b/starmath/source/document.cxx @@ -4,9 +4,9 @@ * * $RCSfile: document.cxx,v $ * - * $Revision: 1.87 $ + * $Revision: 1.88 $ * - * last change: $Author: kz $ $Date: 2007-05-10 15:08:42 $ + * last change: $Author: vg $ $Date: 2007-05-25 12:12:32 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -278,15 +278,6 @@ void SmDocShell::LoadSymbols() } -const String &SmDocShell::GetTitle() const -{ - RTL_LOGFILE_CONTEXT( aLog, "starmath: SmDocShell::GetTitle" ); - - return ((SmDocShell *) this)->GetDocInfo().GetTitle(); -} - - - const String &SmDocShell::GetComment() const { RTL_LOGFILE_CONTEXT( aLog, "starmath: SmDocShell::GetComment" ); @@ -295,7 +286,6 @@ const String &SmDocShell::GetComment() const } - void SmDocShell::SetText(const String& rBuffer) { RTL_LOGFILE_CONTEXT( aLog, "starmath: SmDocShell::SetText" ); @@ -327,7 +317,7 @@ void SmDocShell::SetText(const String& rBuffer) SetModified(TRUE); // launch accessible event if necessary - SmGraphicAccessible *pAcc = pViewSh ? pViewSh->GetGraphicWindow().GetAccessible() : 0; + SmGraphicAccessible *pAcc = pViewSh ? pViewSh->GetGraphicWindow().GetAccessible_Impl() : 0; if (pAcc) { Any aOldValue, aNewValue; @@ -396,7 +386,11 @@ void SmDocShell::ArrangeFormula() OutputDevice* pOutDev = aPrtAcc.GetRefDev(); if (!pOutDev) + { +#if OSL_DEBUG_LEVEL > 1 DBG_ERROR("!! SmDocShell::ArrangeFormula: reference device missing !!"); +#endif + } // falls ntig ein anderes OutputDevice holen fr das formatiert wird if (!pOutDev) @@ -436,7 +430,7 @@ void SmDocShell::ArrangeFormula() void SetEditEngineDefaultFonts( - EditEngine &rEditEngine, + EditEngine &/*rEditEngine*/, SfxItemPool &rEditEngineItemPool ) { // @@ -811,10 +805,10 @@ void SmDocShell::Repaint() SmDocShell::SmDocShell(SfxObjectCreateMode eMode) : SfxObjectShell(eMode), pTree ( 0 ), - pPrinter ( 0 ), - pTmpPrinter ( 0 ), pEditEngineItemPool ( 0 ), pEditEngine ( 0 ), + pPrinter ( 0 ), + pTmpPrinter ( 0 ), nModifyCount ( 0 ), bIsFormulaArranged ( FALSE ) { @@ -892,7 +886,7 @@ BOOL SmDocShell::ConvertFrom(SfxMedium &rMedium) { // is this a MathType Storage? MathType aEquation( aText ); - if ( bSuccess = ( 1 == aEquation.Parse( aStorage ) ) ) + if ( TRUE == (bSuccess = (1 == aEquation.Parse( aStorage )) )) Parse(); } } @@ -1081,9 +1075,9 @@ void SmDocShell::Execute(SfxRequest& rReq) SmFormat aNewFormat( aOldFormat ); aNewFormat.SetTextmode(!aOldFormat.IsTextmode()); - SfxUndoManager *pUndoMgr = GetUndoManager(); - if (pUndoMgr) - pUndoMgr->AddUndoAction( + SfxUndoManager *pTmpUndoMgr = GetUndoManager(); + if (pTmpUndoMgr) + pTmpUndoMgr->AddUndoAction( new SmFormatAction(this, aOldFormat, aNewFormat)); SetFormat( aNewFormat ); @@ -1124,9 +1118,9 @@ void SmDocShell::Execute(SfxRequest& rReq) SmFormat aNewFormat( aOldFormat ); pFontTypeDialog->WriteTo(aNewFormat); - SfxUndoManager *pUndoMgr = GetUndoManager(); - if (pUndoMgr) - pUndoMgr->AddUndoAction( + SfxUndoManager *pTmpUndoMgr = GetUndoManager(); + if (pTmpUndoMgr) + pTmpUndoMgr->AddUndoAction( new SmFormatAction(this, aOldFormat, aNewFormat)); SetFormat( aNewFormat ); @@ -1148,9 +1142,9 @@ void SmDocShell::Execute(SfxRequest& rReq) pFontSizeDialog->WriteTo(aNewFormat); - SfxUndoManager *pUndoMgr = GetUndoManager(); - if (pUndoMgr) - pUndoMgr->AddUndoAction( + SfxUndoManager *pTmpUndoMgr = GetUndoManager(); + if (pTmpUndoMgr) + pTmpUndoMgr->AddUndoAction( new SmFormatAction(this, aOldFormat, aNewFormat)); SetFormat( aNewFormat ); @@ -1172,9 +1166,9 @@ void SmDocShell::Execute(SfxRequest& rReq) pDistanceDialog->WriteTo(aNewFormat); - SfxUndoManager *pUndoMgr = GetUndoManager(); - if (pUndoMgr) - pUndoMgr->AddUndoAction( + SfxUndoManager *pTmpUndoMgr = GetUndoManager(); + if (pTmpUndoMgr) + pTmpUndoMgr->AddUndoAction( new SmFormatAction(this, aOldFormat, aNewFormat)); SetFormat( aNewFormat ); @@ -1201,9 +1195,9 @@ void SmDocShell::Execute(SfxRequest& rReq) pAlignDialog->WriteTo( aFmt ); pp->GetConfig()->SetStandardFormat( aFmt ); - SfxUndoManager *pUndoMgr = GetUndoManager(); - if (pUndoMgr) - pUndoMgr->AddUndoAction( + SfxUndoManager *pTmpUndoMgr = GetUndoManager(); + if (pTmpUndoMgr) + pTmpUndoMgr->AddUndoAction( new SmFormatAction(this, aOldFormat, aNewFormat)); SetFormat( aNewFormat ); @@ -1228,8 +1222,8 @@ void SmDocShell::Execute(SfxRequest& rReq) case SID_UNDO: case SID_REDO: { - SfxUndoManager* pUndoMgr = GetUndoManager(); - if( pUndoMgr ) + SfxUndoManager* pTmpUndoMgr = GetUndoManager(); + if( pTmpUndoMgr ) { USHORT nId = rReq.GetSlot(), nCnt = 1; const SfxItemSet* pArgs = rReq.GetArgs(); @@ -1242,17 +1236,17 @@ void SmDocShell::Execute(SfxRequest& rReq) sal_uInt16 nCount; if( SID_UNDO == rReq.GetSlot() ) { - nCount = pUndoMgr->GetUndoActionCount(); + nCount = pTmpUndoMgr->GetUndoActionCount(); fnDo = &SfxUndoManager::Undo; } else { - nCount = pUndoMgr->GetRedoActionCount(); + nCount = pTmpUndoMgr->GetRedoActionCount(); fnDo = &SfxUndoManager::Redo; } for( ; nCnt && nCount; --nCnt, --nCount ) - (pUndoMgr->*fnDo)( 0 ); + (pTmpUndoMgr->*fnDo)( 0 ); } Repaint(); } @@ -1319,27 +1313,27 @@ void SmDocShell::GetState(SfxItemSet &rSet) case SID_GETUNDOSTRINGS: case SID_GETREDOSTRINGS: { - SfxUndoManager* pUndoMgr = GetUndoManager(); - if( pUndoMgr ) + SfxUndoManager* pTmpUndoMgr = GetUndoManager(); + if( pTmpUndoMgr ) { UniString(SfxUndoManager:: *fnGetComment)( USHORT ) const; sal_uInt16 nCount; if( SID_GETUNDOSTRINGS == nWh ) { - nCount = pUndoMgr->GetUndoActionCount(); + nCount = pTmpUndoMgr->GetUndoActionCount(); fnGetComment = &SfxUndoManager::GetUndoActionComment; } else { - nCount = pUndoMgr->GetRedoActionCount(); + nCount = pTmpUndoMgr->GetRedoActionCount(); fnGetComment = &SfxUndoManager::GetRedoActionComment; } if( nCount ) { String sList; for( sal_uInt16 n = 0; n < nCount; ++n ) - ( sList += (pUndoMgr->*fnGetComment)( n ) ) + ( sList += (pTmpUndoMgr->*fnGetComment)( n ) ) += '\n'; SfxStringListItem aItem( nWh ); @@ -1377,7 +1371,7 @@ void SmDocShell::SaveSymbols() void SmDocShell::Draw(OutputDevice *pDevice, const JobSetup &, - USHORT nAspect) + USHORT /*nAspect*/) { RTL_LOGFILE_CONTEXT( aLog, "starmath: SmDocShell::Draw" ); @@ -1386,7 +1380,7 @@ void SmDocShell::Draw(OutputDevice *pDevice, Draw(*pDevice, atmppoint); } -SfxItemPool& SmDocShell::GetPool() +SfxItemPool& SmDocShell::GetPool() const { return SFX_APP()->GetPool(); } @@ -1430,7 +1424,7 @@ void SmDocShell::SetVisArea(const Rectangle & rVisArea) void SmDocShell::FillClass(SvGlobalName* pClassName, sal_uInt32* pFormat, - String* pAppName, + String* /*pAppName*/, String* pFullTypeName, String* pShortTypeName, sal_Int32 nFileFormat ) const |