diff options
author | Tor Lillqvist <tml@iki.fi> | 2013-03-27 11:35:40 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2013-03-27 11:36:03 +0200 |
commit | a8c3c673eaec987e9fe47123f60e5f9d34a4e93f (patch) | |
tree | addc0a07ffb5430f6a2c74e4cb599bd1f3de41dd /sfx2 | |
parent | 556fe2c6128a32233b411a85c54177e1d5be1e0d (diff) |
Use <config_features.h> instead of -DLIBO_FEATURE_*
Change-Id: Idc198beb6d759dbe3bad6ea58d896c1555b4cc0f
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/inc/sfx2/objsh.hxx | 4 | ||||
-rw-r--r-- | sfx2/source/doc/docfile.cxx | 10 | ||||
-rw-r--r-- | sfx2/source/doc/objmisc.cxx | 3 | ||||
-rw-r--r-- | sfx2/source/doc/objstor.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/doc/objxtor.cxx | 3 | ||||
-rw-r--r-- | sfx2/source/doc/sfxbasemodel.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/view/viewfrm.cxx | 5 |
7 files changed, 22 insertions, 11 deletions
diff --git a/sfx2/inc/sfx2/objsh.hxx b/sfx2/inc/sfx2/objsh.hxx index caaf4e3d0907..2070f6b12f4c 100644 --- a/sfx2/inc/sfx2/objsh.hxx +++ b/sfx2/inc/sfx2/objsh.hxx @@ -19,6 +19,8 @@ #ifndef _SFX_OBJSH_HXX #define _SFX_OBJSH_HXX +#include <config_features.h> + #include "sal/config.h" #include "tools/solar.h" @@ -271,7 +273,7 @@ public: virtual sal_Bool AcceptStateUpdate() const; sal_Bool IsHelpDocument() const; -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT sal_Bool IsDocShared() const; ::rtl::OUString GetSharedFileURL() const; sal_Bool SwitchToShared( sal_Bool bShared, sal_Bool bSave ); diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx index 18b1d3d7c7e9..5afe39cbd9df 100644 --- a/sfx2/source/doc/docfile.cxx +++ b/sfx2/source/doc/docfile.cxx @@ -17,6 +17,8 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> + #include <sfx2/docfile.hxx> #include "sfx2/signaturestate.hxx" @@ -135,7 +137,7 @@ static const sal_Int8 LOCK_UI_NOLOCK = 0; static const sal_Int8 LOCK_UI_SUCCEEDED = 1; static const sal_Int8 LOCK_UI_TRY = 2; -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT bool IsSystemFileLockingUsed() { @@ -984,7 +986,7 @@ sal_Int8 SfxMedium::ShowLockedDocumentDialog( const uno::Sequence< ::rtl::OUStri namespace { -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT bool isSuitableProtocolForLocking(const String & rLogicName) { INetURLObject aUrl( rLogicName ); @@ -999,7 +1001,7 @@ namespace // if user cancel the loading the ERROR_ABORT is set bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI ) { -#ifndef LIBO_FEATURE_DESKTOP +#if !HAVE_FEATURE_MULTIUSER_ENVIRONMENT (void) bLoading; (void) bNoUI; return true; @@ -2682,7 +2684,7 @@ void SfxMedium::CloseAndRelease() void SfxMedium::UnlockFile( sal_Bool bReleaseLockStream ) { -#ifndef LIBO_FEATURE_DESKTOP +#if !HAVE_FEATURE_MULTIUSER_ENVIRONMENT (void) bReleaseLockStream; #else if ( pImp->m_xLockingStream.is() ) diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx index 2ac11f047424..853eddb2b034 100644 --- a/sfx2/source/doc/objmisc.cxx +++ b/sfx2/source/doc/objmisc.cxx @@ -17,6 +17,7 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> #include <svl/inetmsg.hxx> #include <tools/diagnose_ex.h> @@ -495,7 +496,7 @@ void SfxObjectShell::SetModalMode_Impl( sal_Bool bModal ) } } -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT sal_Bool SfxObjectShell::SwitchToShared( sal_Bool bShared, sal_Bool bSave ) { diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx index e06de136da06..250a640817d9 100644 --- a/sfx2/source/doc/objstor.cxx +++ b/sfx2/source/doc/objstor.cxx @@ -17,6 +17,8 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> + #include "sal/config.h" #include <cassert> @@ -2687,7 +2689,7 @@ sal_Bool SfxObjectShell::CommonSaveAs_Impl if ( pFilterOptItem ) pSet->Put( *pFilterOptItem ); -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT if ( IsDocShared() && !aTempFileURL.isEmpty() ) { // this is a shared document that has to be disconnected from the old location diff --git a/sfx2/source/doc/objxtor.cxx b/sfx2/source/doc/objxtor.cxx index 44d4ae3f3511..b0a021330609 100644 --- a/sfx2/source/doc/objxtor.cxx +++ b/sfx2/source/doc/objxtor.cxx @@ -17,6 +17,7 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> #include "arrdecl.hxx" #include <map> @@ -390,7 +391,7 @@ SfxObjectShell::~SfxObjectShell() { pMedium->CloseAndReleaseStreams_Impl(); -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT if ( IsDocShared() ) FreeSharedFile(); #endif diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx index 170ae60774c2..232e04f2b781 100644 --- a/sfx2/source/doc/sfxbasemodel.cxx +++ b/sfx2/source/doc/sfxbasemodel.cxx @@ -17,6 +17,8 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> + #include <sfx2/sfxbasemodel.hxx> #include <com/sun/star/task/XInteractionHandler.hpp> @@ -2952,7 +2954,7 @@ void SfxBaseModel::impl_store( const ::rtl::OUString& sURL } catch( const lang::IllegalArgumentException& ) { -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT // some additional arguments do not allow to use saving, SaveAs should be done // but only for normal documents, the shared documents would be overwritten in this case // that would mean an information loss diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index bac1cd41b86b..c4cfce55e076 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -17,6 +17,7 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <config_features.h> #include <stdio.h> @@ -673,7 +674,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq ) pNewSet->ClearItem( SID_DOC_SALVAGE ); } -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT // TODO/LATER: Temporary solution, the SfxMedium must know the original URL as aLogicName // SfxMedium::Transfer_Impl() will be forbidden then. if ( xOldObj->IsDocShared() ) @@ -790,7 +791,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq ) xNewObj->SetReadOnlyUI( !bForEdit ); } -#ifdef LIBO_FEATURE_DESKTOP +#if HAVE_FEATURE_MULTIUSER_ENVIRONMENT if ( xNewObj->IsDocShared() ) { // the file is shared but the closing can change the sharing control file |