summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorValentin Kettner <vakevk+libreoffice@gmail.com>2014-05-20 21:35:48 +0200
committerValentin Kettner <vakevk+libreoffice@gmail.com>2014-06-03 19:12:00 +0200
commitcf8a3e700f18763b2aaaf1df0bcc53565e59e0c0 (patch)
tree9724956b39a4a2e6851275af1dce4d60cab633a3 /sw/source
parent50682e7205166bea55a935a984a49bb95e4ca094 (diff)
Cleaning up of IDocumentDeviceAccess methods in SwDoc.
Moved all SwDoc::getReferenceDevice and SwDoc::setReferenceDevice calls to their appropriate interface methods (SwDoc::getIDocumentDeviceAccess::"). Change-Id: I2a1b488500fa4f0bfbb7ebadccde2c94b70efd85
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/doc/doc.cxx10
-rw-r--r--sw/source/core/doc/docdraw.cxx2
-rw-r--r--sw/source/core/view/viewsh.cxx2
-rw-r--r--sw/source/uibase/app/docsh.cxx2
-rw-r--r--sw/source/uibase/app/docshini.cxx2
-rw-r--r--sw/source/uibase/uno/SwXDocumentSettings.cxx2
6 files changed, 5 insertions, 15 deletions
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index 08e548d66173..a018c7173b96 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -254,16 +254,6 @@ IDocumentDeviceAccess* SwDoc::getIDocumentDeviceAccess()
return m_DeviceAccess.get();
}
-OutputDevice* SwDoc::getReferenceDevice(/*[in]*/ bool bCreate ) const
-{
- return getIDocumentDeviceAccessConst()->getReferenceDevice( bCreate );
-}
-
-void SwDoc::setReferenceDeviceType(/*[in]*/ bool bNewVirtual,/*[in]*/ bool bNewHiRes )
-{
- getIDocumentDeviceAccess()->setReferenceDeviceType( bNewVirtual, bNewHiRes );
-}
-
const JobSetup* SwDoc::getJobsetup() const
{
return getIDocumentDeviceAccessConst()->getJobsetup();
diff --git a/sw/source/core/doc/docdraw.cxx b/sw/source/core/doc/docdraw.cxx
index 9e48240d7334..c3e7ee6f76af 100644
--- a/sw/source/core/doc/docdraw.cxx
+++ b/sw/source/core/doc/docdraw.cxx
@@ -596,7 +596,7 @@ void SwDoc::InitDrawModel()
mpDrawModel->SetLinkManager( &GetLinkManager() );
mpDrawModel->SetAddExtLeading( get(IDocumentSettingAccess::ADD_EXT_LEADING) );
- OutputDevice* pRefDev = getReferenceDevice( false );
+ OutputDevice* pRefDev = getIDocumentDeviceAccessConst()->getReferenceDevice( false );
if ( pRefDev )
mpDrawModel->SetRefDevice( pRefDev );
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 03a1dd000f25..f5d2e0c810cb 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -1999,7 +1999,7 @@ OutputDevice& SwViewShell::GetRefDev() const
else if ( 0 != mpTmpRef )
pTmpOut = mpTmpRef;
else
- pTmpOut = GetDoc()->getReferenceDevice( true );
+ pTmpOut = GetDoc()->getIDocumentDeviceAccessConst()->getReferenceDevice( true );
return *pTmpOut;
}
diff --git a/sw/source/uibase/app/docsh.cxx b/sw/source/uibase/app/docsh.cxx
index 53a0f6d13e42..0962badc05b9 100644
--- a/sw/source/uibase/app/docsh.cxx
+++ b/sw/source/uibase/app/docsh.cxx
@@ -876,7 +876,7 @@ Printer *SwDocShell::GetDocumentPrinter()
OutputDevice* SwDocShell::GetDocumentRefDev()
{
- return pDoc->getReferenceDevice( false );
+ return pDoc->getIDocumentDeviceAccessConst()->getReferenceDevice( false );
}
void SwDocShell::OnDocumentPrinterChanged( Printer * pNewPrinter )
diff --git a/sw/source/uibase/app/docshini.cxx b/sw/source/uibase/app/docshini.cxx
index c74ac698c984..5a2603dbf13a 100644
--- a/sw/source/uibase/app/docshini.cxx
+++ b/sw/source/uibase/app/docshini.cxx
@@ -423,7 +423,7 @@ void SwDocShell::UpdateFontList()
if( pDoc )
{
delete pFontList;
- pFontList = new FontList( pDoc->getReferenceDevice( true ) );
+ pFontList = new FontList( pDoc->getIDocumentDeviceAccessConst()->getReferenceDevice( true ) );
PutItem( SvxFontListItem( pFontList, SID_ATTR_CHAR_FONTLIST ) );
}
bInUpdateFontList = false;
diff --git a/sw/source/uibase/uno/SwXDocumentSettings.cxx b/sw/source/uibase/uno/SwXDocumentSettings.cxx
index 2125448de4fe..ff8d78ce1dfc 100644
--- a/sw/source/uibase/uno/SwXDocumentSettings.cxx
+++ b/sw/source/uibase/uno/SwXDocumentSettings.cxx
@@ -520,7 +520,7 @@ void SwXDocumentSettings::_setSingleValue( const comphelper::PropertyInfo & rInf
else if ( nTmp != document::PrinterIndependentLayout::HIGH_RESOLUTION )
throw IllegalArgumentException();
- mpDoc->setReferenceDeviceType( bUseVirDev, bHiResVirDev );
+ mpDoc->getIDocumentDeviceAccess()->setReferenceDeviceType( bUseVirDev, bHiResVirDev );
}
break;
case HANDLE_IS_LABEL_DOC :