summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorJochen Nitschke <j.nitschke+logerrit@ok.de>2016-08-27 10:18:06 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-08-27 12:06:15 +0000
commit33b38082ca63813f7c478945be198cc504efde4b (patch)
tree030eb240e231d855e477d985c3edc36304dd2914 /sw
parent81a7aeb0806298c7a8571a46e09f485f3cf5ea13 (diff)
put StreamMode masks in scope of enum class
Change-Id: I77682f7e289a59b986bb84edf014029a20266470 Reviewed-on: https://gerrit.libreoffice.org/28420 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/core/filters-test.cxx4
-rw-r--r--sw/qa/core/uwriter.cxx2
-rw-r--r--sw/source/core/doc/docglbl.cxx2
-rw-r--r--sw/source/core/doc/tblafmt.cxx4
-rw-r--r--sw/source/core/edit/edtox.cxx2
-rw-r--r--sw/source/core/swg/SwXMLTextBlocks.cxx2
-rw-r--r--sw/source/filter/basflt/iodetect.cxx4
-rw-r--r--sw/source/filter/ww8/wrtww8.cxx10
-rw-r--r--sw/source/filter/ww8/ww8glsy.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par.cxx10
-rw-r--r--sw/source/filter/ww8/ww8par4.cxx6
-rw-r--r--sw/source/ui/dbui/createaddresslistdialog.cxx2
-rw-r--r--sw/source/ui/dialog/uiregionsw.cxx2
-rw-r--r--sw/source/ui/index/cnttab.cxx2
-rw-r--r--sw/source/uibase/app/docsh2.cxx2
-rw-r--r--sw/source/uibase/config/uinums.cxx2
-rw-r--r--sw/source/uibase/dbui/dbmgr.cxx4
-rw-r--r--sw/source/uibase/dbui/mailmergehelper.cxx2
-rw-r--r--sw/source/uibase/dochdl/swdtflvr.cxx2
-rw-r--r--sw/source/uibase/sidebar/StylePresetsPanel.cxx2
-rw-r--r--sw/source/uibase/uiview/srcview.cxx2
21 files changed, 35 insertions, 35 deletions
diff --git a/sw/qa/core/filters-test.cxx b/sw/qa/core/filters-test.cxx
index e8ddc2a0ab90..b8cb7c506ac6 100644
--- a/sw/qa/core/filters-test.cxx
+++ b/sw/qa/core/filters-test.cxx
@@ -87,7 +87,7 @@ bool SwFiltersTest::filter(const OUString &rFilter, const OUString &rURL,
const_cast<SfxFilter*>(pFilter.get())->SetVersion(nFilterVersion);
SwDocShellRef xDocShRef = new SwDocShell;
- SfxMedium* pSrcMed = new SfxMedium(rURL, STREAM_STD_READ);
+ SfxMedium* pSrcMed = new SfxMedium(rURL, StreamMode::STD_READ);
std::shared_ptr<const SfxFilter> pImportFilter;
std::shared_ptr<const SfxFilter> pExportFilter;
@@ -121,7 +121,7 @@ bool SwFiltersTest::filter(const OUString &rFilter, const OUString &rURL,
utl::TempFile aTempFile;
aTempFile.EnableKillingFile();
- SfxMedium aDstMed(aTempFile.GetURL(), STREAM_STD_WRITE);
+ SfxMedium aDstMed(aTempFile.GetURL(), StreamMode::STD_WRITE);
aDstMed.SetFilter(pExportFilter);
bool bSaved = xDocShRef->DoSaveAs(aDstMed);
if (xDocShRef.Is())
diff --git a/sw/qa/core/uwriter.cxx b/sw/qa/core/uwriter.cxx
index aa830210fab6..2469e981351c 100644
--- a/sw/qa/core/uwriter.cxx
+++ b/sw/qa/core/uwriter.cxx
@@ -187,7 +187,7 @@ void SwDocTest::testFileNameFields()
INetURLObject aTempFileURL(aTempFile.GetURL());
OUString sFileURL = aTempFileURL.GetMainURL(INetURLObject::NO_DECODE);
- SfxMedium aDstMed(sFileURL, STREAM_STD_READWRITE);
+ SfxMedium aDstMed(sFileURL, StreamMode::STD_READWRITE);
std::shared_ptr<SfxFilter> pFilter(new SfxFilter(
OUString("Text"),
diff --git a/sw/source/core/doc/docglbl.cxx b/sw/source/core/doc/docglbl.cxx
index edc1aaf8e300..eec97754fe3b 100644
--- a/sw/source/core/doc/docglbl.cxx
+++ b/sw/source/core/doc/docglbl.cxx
@@ -319,7 +319,7 @@ bool SwDoc::SplitDoc( sal_uInt16 eDocType, const OUString& rPath, bool bOutline,
utl::TempFile aTempFile2(sLeading, true, &sExt, &sPath);
sFileName = aTempFile2.GetURL();
SfxMedium* pTmpMed = new SfxMedium( sFileName,
- STREAM_STD_READWRITE );
+ StreamMode::STD_READWRITE );
pTmpMed->SetFilter( pFilter );
// We need to have a Layout for the HTMLFilter, so that
diff --git a/sw/source/core/doc/tblafmt.cxx b/sw/source/core/doc/tblafmt.cxx
index d44ebcba9527..38824b29456f 100644
--- a/sw/source/core/doc/tblafmt.cxx
+++ b/sw/source/core/doc/tblafmt.cxx
@@ -1291,7 +1291,7 @@ bool SwTableAutoFormatTable::Load()
SvtPathOptions aOpt;
if( aOpt.SearchFile( sNm ))
{
- SfxMedium aStream( sNm, STREAM_STD_READ );
+ SfxMedium aStream( sNm, StreamMode::STD_READ );
bRet = Load( *aStream.GetInStream() );
}
else
@@ -1303,7 +1303,7 @@ bool SwTableAutoFormatTable::Save() const
{
SvtPathOptions aPathOpt;
const OUString sNm( aPathOpt.GetUserConfigPath() + "/" AUTOTABLE_FORMAT_NAME );
- SfxMedium aStream(sNm, STREAM_STD_WRITE );
+ SfxMedium aStream(sNm, StreamMode::STD_WRITE );
return Save( *aStream.GetOutStream() ) && aStream.Commit();
}
diff --git a/sw/source/core/edit/edtox.cxx b/sw/source/core/edit/edtox.cxx
index fcb9ec294831..eb006419dae2 100644
--- a/sw/source/core/edit/edtox.cxx
+++ b/sw/source/core/edit/edtox.cxx
@@ -302,7 +302,7 @@ void SwEditShell::ApplyAutoMark()
}
//2.
- SfxMedium aMedium( sAutoMarkURL, STREAM_STD_READ );
+ SfxMedium aMedium( sAutoMarkURL, StreamMode::STD_READ );
SvStream& rStrm = *aMedium.GetInStream();
Push();
rtl_TextEncoding eChrSet = ::osl_getThreadTextEncoding();
diff --git a/sw/source/core/swg/SwXMLTextBlocks.cxx b/sw/source/core/swg/SwXMLTextBlocks.cxx
index 1ecf8d381b09..ef2181437ee5 100644
--- a/sw/source/core/swg/SwXMLTextBlocks.cxx
+++ b/sw/source/core/swg/SwXMLTextBlocks.cxx
@@ -515,7 +515,7 @@ bool SwXMLTextBlocks::IsFileUCBStorage( const OUString & rFileName)
aName = aObj.GetMainURL( INetURLObject::NO_DECODE );
}
- SvStream * pStm = ::utl::UcbStreamHelper::CreateStream( aName, STREAM_STD_READ );
+ SvStream * pStm = ::utl::UcbStreamHelper::CreateStream( aName, StreamMode::STD_READ );
bool bRet = UCBStorage::IsStorageFile( pStm );
delete pStm;
return bRet;
diff --git a/sw/source/filter/basflt/iodetect.cxx b/sw/source/filter/basflt/iodetect.cxx
index 8de8f0d195a0..55a62390ab86 100644
--- a/sw/source/filter/basflt/iodetect.cxx
+++ b/sw/source/filter/basflt/iodetect.cxx
@@ -127,7 +127,7 @@ bool SwIoSystem::IsValidStgFilter(SotStorage& rStg, const SfxFilter& rFilter)
{
tools::SvRef<SotStorageStream> xRef =
rStg.OpenSotStream("WordDocument",
- STREAM_STD_READ );
+ StreamMode::STD_READ );
xRef->Seek(10);
sal_uInt8 nByte;
xRef->ReadUChar( nByte );
@@ -160,7 +160,7 @@ std::shared_ptr<const SfxFilter> SwIoSystem::GetFileFilter(const OUString& rFile
INetURLObject aObj;
aObj.SetSmartProtocol( INetProtocol::File );
aObj.SetSmartURL( rFileName );
- SfxMedium aMedium(aObj.GetMainURL(INetURLObject::NO_DECODE), STREAM_STD_READ);
+ SfxMedium aMedium(aObj.GetMainURL(INetURLObject::NO_DECODE), StreamMode::STD_READ);
// templates should not get precedence over "normal" filters (#i35508, #i33168)
std::shared_ptr<const SfxFilter> pTemplateFilter;
diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index 843f45c532d7..3b23221a07f6 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -3216,9 +3216,9 @@ void WW8Export::ExportDocument_Impl()
pFib->fWhichTableStm = true;
xTableStrm = GetWriter().GetStorage().OpenSotStream(OUString(SL::a1Table),
- STREAM_STD_WRITE );
+ StreamMode::STD_WRITE );
xDataStrm = GetWriter().GetStorage().OpenSotStream(OUString(SL::aData),
- STREAM_STD_WRITE );
+ StreamMode::STD_WRITE );
xDataStrm->SetBufferSize( 32768 ); // for graphics
xTableStrm->SetBufferSize( 16384 ); // for the Font-/Style-Table, etc.
@@ -3244,11 +3244,11 @@ void WW8Export::ExportDocument_Impl()
if ( bEncrypt )
{
GetWriter().SetStream(
- aTempMain.GetStream( STREAM_READWRITE | StreamMode::SHARE_DENYWRITE ) );
+ aTempMain.GetStream( StreamMode::READWRITE | StreamMode::SHARE_DENYWRITE ) );
- pTableStrm = aTempTable.GetStream( STREAM_READWRITE | StreamMode::SHARE_DENYWRITE );
+ pTableStrm = aTempTable.GetStream( StreamMode::READWRITE | StreamMode::SHARE_DENYWRITE );
- pDataStrm = aTempData.GetStream( STREAM_READWRITE | StreamMode::SHARE_DENYWRITE );
+ pDataStrm = aTempData.GetStream( StreamMode::READWRITE | StreamMode::SHARE_DENYWRITE );
sal_uInt8 aRC4EncryptionHeader[ 52 ] = {0};
pTableStrm->WriteBytes(aRC4EncryptionHeader, 52);
diff --git a/sw/source/filter/ww8/ww8glsy.cxx b/sw/source/filter/ww8/ww8glsy.cxx
index cb89dfbc0aa1..1df65d0e58d2 100644
--- a/sw/source/filter/ww8/ww8glsy.cxx
+++ b/sw/source/filter/ww8/ww8glsy.cxx
@@ -43,7 +43,7 @@ WW8Glossary::WW8Glossary(tools::SvRef<SotStorageStream> &refStrm, sal_uInt8 nVer
if (aWwFib.nFibBack >= 0x6A) //Word97
{
xTableStream = pStg->OpenSotStream(OUString::createFromAscii(
- aWwFib.fWhichTableStm ? SL::a1Table : SL::a0Table), STREAM_STD_READ);
+ aWwFib.fWhichTableStm ? SL::a1Table : SL::a0Table), StreamMode::STD_READ);
if (xTableStream.Is() && SVSTREAM_OK == xTableStream->GetError())
{
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 32f40bac90ed..0c95f2227827 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -4887,7 +4887,7 @@ void SwWW8ImplReader::ReadGlobalTemplateSettings( const OUString& sCreatedFrom,
if ( !aURL.endsWithIgnoreAsciiCase( ".dot" ) || ( !sCreatedFrom.isEmpty() && sCreatedFrom.equals( aURL ) ) )
continue; // don't try and read the same document as ourselves
- tools::SvRef<SotStorage> rRoot = new SotStorage( aURL, STREAM_STD_READWRITE );
+ tools::SvRef<SotStorage> rRoot = new SotStorage( aURL, StreamMode::STD_READWRITE );
BasicProjImportHelper aBasicImporter( *m_pDocShell );
// Import vba via oox filter
@@ -4897,7 +4897,7 @@ void SwWW8ImplReader::ReadGlobalTemplateSettings( const OUString& sCreatedFrom,
tools::SvRef<SotStorageStream> refMainStream = rRoot->OpenSotStream( "WordDocument");
refMainStream->SetEndian(SvStreamEndian::LITTLE);
WW8Fib aWwFib( *refMainStream, 8 );
- tools::SvRef<SotStorageStream> xTableStream = rRoot->OpenSotStream(OUString::createFromAscii( aWwFib.fWhichTableStm ? SL::a1Table : SL::a0Table), STREAM_STD_READ);
+ tools::SvRef<SotStorageStream> xTableStream = rRoot->OpenSotStream(OUString::createFromAscii( aWwFib.fWhichTableStm ? SL::a1Table : SL::a0Table), StreamMode::STD_READ);
if (xTableStream.Is() && SVSTREAM_OK == xTableStream->GetError())
{
@@ -5438,13 +5438,13 @@ sal_uLong SwWW8ImplReader::SetSubStreams(tools::SvRef<SotStorageStream> &rTableS
rTableStream = m_pStg->OpenSotStream( OUString::createFromAscii(
m_pWwFib->fWhichTableStm ? SL::a1Table : SL::a0Table),
- STREAM_STD_READ);
+ StreamMode::STD_READ);
m_pTableStream = &rTableStream;
m_pTableStream->SetEndian( SvStreamEndian::LITTLE );
rDataStream = m_pStg->OpenSotStream(OUString(SL::aData),
- STREAM_STD_READ );
+ StreamMode::STD_READ );
if (rDataStream.Is() && SVSTREAM_OK == rDataStream->GetError())
{
@@ -5469,7 +5469,7 @@ namespace
{
utl::TempFile *pT = new utl::TempFile;
pT->EnableKillingFile();
- rSt.Open(pT->GetFileName(), STREAM_READWRITE | StreamMode::SHARE_DENYWRITE);
+ rSt.Open(pT->GetFileName(), StreamMode::READWRITE | StreamMode::SHARE_DENYWRITE);
return pT;
}
diff --git a/sw/source/filter/ww8/ww8par4.cxx b/sw/source/filter/ww8/ww8par4.cxx
index 867ea7ad54d2..4b68065876c6 100644
--- a/sw/source/filter/ww8/ww8par4.cxx
+++ b/sw/source/filter/ww8/ww8par4.cxx
@@ -83,7 +83,7 @@ static bool SwWw8ReadScaling(long& rX, long& rY, tools::SvRef<SotStorage>& rSrc1
// 0x34, 0x38, 0x3c, 0x40 Crop Left, Top, Right, Bot in tw
tools::SvRef<SotStorageStream> xSrc3 = rSrc1->OpenSotStream( "\3PIC",
- STREAM_STD_READ );
+ StreamMode::STD_READ );
SotStorageStream* pS = xSrc3;
pS->SetEndian( SvStreamEndian::LITTLE );
pS->Seek( STREAM_SEEK_TO_END );
@@ -128,7 +128,7 @@ static bool SwWw6ReadMetaStream(GDIMetaFile& rWMF, OLE_MFP* pMfp,
tools::SvRef<SotStorage>& rSrc1)
{
tools::SvRef<SotStorageStream> xSrc2 = rSrc1->OpenSotStream( "\3META",
- STREAM_STD_READ );
+ StreamMode::STD_READ );
SotStorageStream* pSt = xSrc2;
pSt->SetEndian( SvStreamEndian::LITTLE );
size_t const nRead = pSt->ReadBytes(pMfp, sizeof(*pMfp));
@@ -424,7 +424,7 @@ SdrObject* SwWW8ImplReader::ImportOleBase( Graphic& rGraph,
{
tools::SvRef<SotStorageStream> xObjInfoSrc = xSrc1->OpenSotStream("\3ObjInfo",
- STREAM_STD_READ );
+ StreamMode::STD_READ );
if ( xObjInfoSrc.Is() && !xObjInfoSrc->GetError() )
{
sal_uInt8 nByte = 0;
diff --git a/sw/source/ui/dbui/createaddresslistdialog.cxx b/sw/source/ui/dbui/createaddresslistdialog.cxx
index c677afc681ce..a615eead2b72 100644
--- a/sw/source/ui/dbui/createaddresslistdialog.cxx
+++ b/sw/source/ui/dbui/createaddresslistdialog.cxx
@@ -641,7 +641,7 @@ IMPL_LINK_NOARG_TYPED(SwCreateAddressListDialog, OkHdl_Impl, Button*, void)
}
if(!m_sURL.isEmpty())
{
- SfxMedium aMedium( m_sURL, STREAM_READWRITE|StreamMode::TRUNC );
+ SfxMedium aMedium( m_sURL, StreamMode::READWRITE|StreamMode::TRUNC );
SvStream* pStream = aMedium.GetOutStream();
pStream->SetLineDelimiter( LINEEND_LF );
pStream->SetStreamCharSet(RTL_TEXTENCODING_UTF8);
diff --git a/sw/source/ui/dialog/uiregionsw.cxx b/sw/source/ui/dialog/uiregionsw.cxx
index 60e0dd250bc7..ccdf15ef7f95 100644
--- a/sw/source/ui/dialog/uiregionsw.cxx
+++ b/sw/source/ui/dialog/uiregionsw.cxx
@@ -1357,7 +1357,7 @@ IMPL_LINK_TYPED( SwEditRegionDlg, SubRegionEventHdl, VclWindowEvent&, rEvent, vo
aAbs, sFileName, URIHelper::GetMaybeFileHdl() );
//load file and set the shell
- SfxMedium aMedium( sFileName, STREAM_STD_READ );
+ SfxMedium aMedium( sFileName, StreamMode::STD_READ );
sFileName = aMedium.GetURLObject().GetMainURL( INetURLObject::NO_DECODE );
::lcl_ReadSections(aMedium, *m_pSubRegionED);
}
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index 096fc3f4f85a..6049e5d86767 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -4167,7 +4167,7 @@ SwAutoMarkDlg_Impl::SwAutoMarkDlg_Impl(vcl::Window* pParent, const OUString& rAu
m_pEntriesBB->RowInserted(0);
else
{
- SfxMedium aMed( sAutoMarkURL, STREAM_STD_READ );
+ SfxMedium aMed( sAutoMarkURL, StreamMode::STD_READ );
if( aMed.GetInStream() && !aMed.GetInStream()->GetError() )
m_pEntriesBB->ReadEntries( *aMed.GetInStream() );
else
diff --git a/sw/source/uibase/app/docsh2.cxx b/sw/source/uibase/app/docsh2.cxx
index 6f2249dfc9aa..6554b2689b51 100644
--- a/sw/source/uibase/app/docsh2.cxx
+++ b/sw/source/uibase/app/docsh2.cxx
@@ -1413,7 +1413,7 @@ sal_uLong SwDocShell::LoadStylesFromFile( const OUString& rURL,
SfxFilterMatcher aMatcher( sFactory );
// search for filter in WebDocShell, too
- SfxMedium aMed( rURL, STREAM_STD_READ );
+ SfxMedium aMed( rURL, StreamMode::STD_READ );
std::shared_ptr<const SfxFilter> pFlt;
aMatcher.DetectFilter( aMed, pFlt );
if(!pFlt)
diff --git a/sw/source/uibase/config/uinums.cxx b/sw/source/uibase/config/uinums.cxx
index fcb10e9a1705..ede3be4d7a6e 100644
--- a/sw/source/uibase/config/uinums.cxx
+++ b/sw/source/uibase/config/uinums.cxx
@@ -86,7 +86,7 @@ void SwChapterNumRules::Init()
SvtPathOptions aOpt;
if( aOpt.SearchFile( sNm ))
{
- SfxMedium aStrm( sNm, STREAM_STD_READ );
+ SfxMedium aStrm( sNm, StreamMode::STD_READ );
sw::ImportStoredChapterNumberingRules(*this, *aStrm.GetInStream(),
CHAPTER_FILENAME);
}
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index d7d6c151f0ae..33d497a456da 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -874,7 +874,7 @@ static void lcl_SaveDebugDoc( SfxObjectShell *xTargetDocShell,
INetURLObject aTempFileURL( aTempFile.GetURL() );
SfxMedium* pDstMed = new SfxMedium(
aTempFileURL.GetMainURL( INetURLObject::NO_DECODE ),
- STREAM_STD_READWRITE );
+ StreamMode::STD_READWRITE );
bool bAnyError = !xTargetDocShell->DoSaveAs( *pDstMed );
// xObjectShell->DoSaveCompleted crashes the mail merge unit tests, so skip it
bAnyError |= (0 != xTargetDocShell->GetError());
@@ -899,7 +899,7 @@ static bool lcl_SaveDoc(
if( decodedURL )
(*decodedURL) = url;
- SfxMedium* pDstMed = new SfxMedium( url, STREAM_STD_READWRITE );
+ SfxMedium* pDstMed = new SfxMedium( url, StreamMode::STD_READWRITE );
pDstMed->SetFilter( pStoreToFilter );
if( pDstMed->GetItemSet() )
{
diff --git a/sw/source/uibase/dbui/mailmergehelper.cxx b/sw/source/uibase/dbui/mailmergehelper.cxx
index 06f0a092d16b..f83659b7a3d0 100644
--- a/sw/source/uibase/dbui/mailmergehelper.cxx
+++ b/sw/source/uibase/dbui/mailmergehelper.cxx
@@ -707,7 +707,7 @@ uno::Any SwMailTransferable::getTransferData( const datatransfer::DataFlavor& /*
else
{
Sequence<sal_Int8> aData;
- SfxMedium aMedium( m_aURL, STREAM_STD_READ );
+ SfxMedium aMedium( m_aURL, StreamMode::STD_READ );
SvStream* pStream = aMedium.GetInStream();
if ( aMedium.GetErrorCode() == ERRCODE_NONE && pStream)
{
diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx
index dc75047a9158..8341af327452 100644
--- a/sw/source/uibase/dochdl/swdtflvr.cxx
+++ b/sw/source/uibase/dochdl/swdtflvr.cxx
@@ -2429,7 +2429,7 @@ bool SwTransferable::PasteGrf( TransferableDataHelper& rData, SwWrtShell& rSh,
// or should the file be an ImageMap-File?
ImageMap aMap;
SfxMedium aMed( INetURLObject(aBkmk.GetURL()).GetFull(),
- STREAM_STD_READ );
+ StreamMode::STD_READ );
SvStream* pStream = aMed.GetInStream();
if( pStream != nullptr &&
!pStream->GetError() &&
diff --git a/sw/source/uibase/sidebar/StylePresetsPanel.cxx b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
index 2dc12033bd12..863fe2cf3b2b 100644
--- a/sw/source/uibase/sidebar/StylePresetsPanel.cxx
+++ b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
@@ -131,7 +131,7 @@ BitmapEx GenerateStylePreview(SfxObjectShell& rSource, OUString& aName)
BitmapEx CreatePreview(OUString& aUrl, OUString& aName)
{
- SfxMedium aMedium(aUrl, STREAM_STD_READWRITE);
+ SfxMedium aMedium(aUrl, StreamMode::STD_READWRITE);
SfxObjectShell* pObjectShell = SfxObjectShell::Current();
SfxObjectShellLock xTemplDoc = SfxObjectShell::CreateObjectByFactoryName(pObjectShell->GetFactory().GetFactoryName(), SfxObjectCreateMode::ORGANIZER);
xTemplDoc->DoInitNew();
diff --git a/sw/source/uibase/uiview/srcview.cxx b/sw/source/uibase/uiview/srcview.cxx
index 07ba09615e36..0735970b5bd8 100644
--- a/sw/source/uibase/uiview/srcview.cxx
+++ b/sw/source/uibase/uiview/srcview.cxx
@@ -826,7 +826,7 @@ void SwSrcView::Load(SwDocShell* pDocShell)
SvtSaveOptions aOpt;
{
- SfxMedium aMedium( sFileURL,STREAM_READWRITE );
+ SfxMedium aMedium( sFileURL,StreamMode::READWRITE );
SwWriter aWriter( aMedium, *pDocShell->GetDoc() );
WriterRef xWriter;
::GetHTMLWriter(OUString(), aMedium.GetBaseURL( true ), xWriter);