[Libreoffice-commits] core.git: Branch 'feature/refactor-god-objects' - sw/source
Michael Stahl
mstahl at redhat.com
Mon Jun 2 07:36:18 PDT 2014
sw/source/core/doc/DocumentDeviceManager.cxx | 2 +-
sw/source/core/undo/unattr.cxx | 3 ++-
sw/source/filter/html/htmldrawwriter.cxx | 4 +++-
3 files changed, 6 insertions(+), 3 deletions(-)
New commits:
commit 815e6f8b1119280518e937d8f7248d433c207ae6
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 2 16:31:40 2014 +0200
sw: fix some assertions that still use removed SwDoc methods
Change-Id: Ia33dff51cdb58030ec11ec499ee5c518fba31641
diff --git a/sw/source/core/doc/DocumentDeviceManager.cxx b/sw/source/core/doc/DocumentDeviceManager.cxx
index 392654f..aabfd96 100644
--- a/sw/source/core/doc/DocumentDeviceManager.cxx
+++ b/sw/source/core/doc/DocumentDeviceManager.cxx
@@ -297,7 +297,7 @@ void DocumentDeviceManager::PrtDataChanged()
// If you change this, also modify InJobSetup in Sw3io if appropriate.
// #i41075#
- OSL_ENSURE( m_rSwdoc.get(IDocumentSettingAccess::USE_VIRTUAL_DEVICE) ||
+ OSL_ENSURE( m_rSwdoc.getIDocumentSettingAccess().get(IDocumentSettingAccess::USE_VIRTUAL_DEVICE) ||
0 != getPrinter( false ), "PrtDataChanged will be called recursively!" );
SwRootFrm* pTmpRoot = m_rSwdoc.GetCurrentLayout();
boost::scoped_ptr<SwWait> pWait;
diff --git a/sw/source/core/undo/unattr.cxx b/sw/source/core/undo/unattr.cxx
index c454ac9..5401023 100644
--- a/sw/source/core/undo/unattr.cxx
+++ b/sw/source/core/undo/unattr.cxx
@@ -552,7 +552,8 @@ bool SwUndoFmtAttr::RestoreFlyAnchor(::sw::UndoRedoContext & rContext)
if( pCont->GetAnchorFrm() && !pObj->IsInserted() )
{
- OSL_ENSURE( pDoc->GetDrawModel(), "RestoreFlyAnchor without DrawModel" );
+ OSL_ENSURE( pDoc->getIDocumentDrawModelAccess().GetDrawModel(),
+ "RestoreFlyAnchor without DrawModel" );
pDoc->getIDocumentDrawModelAccess().GetDrawModel()->GetPage( 0 )->InsertObject( pObj );
}
pObj->SetRelativePos( aDrawSavePt );
diff --git a/sw/source/filter/html/htmldrawwriter.cxx b/sw/source/filter/html/htmldrawwriter.cxx
index 49baf60..27d0775 100644
--- a/sw/source/filter/html/htmldrawwriter.cxx
+++ b/sw/source/filter/html/htmldrawwriter.cxx
@@ -40,6 +40,7 @@
#include <rtl/strbuf.hxx>
+#include <IDocumentDrawModelAccess.hxx>
#include "charatr.hxx"
#include <frmfmt.hxx>
#include <fmtanchr.hxx>
@@ -134,7 +135,8 @@ Writer& OutHTML_DrawFrmFmtAsMarquee( Writer& rWrt,
{
SwHTMLWriter & rHTMLWrt = (SwHTMLWriter&)rWrt;
- OSL_ENSURE( rWrt.pDoc->GetDrawModel(), "Da gibt's ein Draw-Obj ohne ein Draw-Model zu haben?" );
+ OSL_ENSURE( rWrt.pDoc->getIDocumentDrawModelAccess().GetDrawModel(),
+ "There is a Draw-Obj with no Draw-Model?" );
const SdrTextObj *pTextObj = (const SdrTextObj *)&rSdrObject;
// Gibt es ueberhaupt auszugebenden Text
More information about the Libreoffice-commits
mailing list