summaryrefslogtreecommitdiff
path: root/extensions/source
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-04-02 15:58:06 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-04-02 16:30:34 +0200
commit44b3e56bb4a4df59f53447c4ca4d8e02fe926206 (patch)
tree71a9efde3a6a2a00688e8feb8e3086cb32eceb4f /extensions/source
parent0b4965bcd7ec911951e7ca3a4cd48062843b2634 (diff)
Change INetProtocol to scoped enumeration
...and fix o3tl::enumarray::operator [] const overload Change-Id: I749b1b9d68686b03a97074253478d9d2d9d32b0b
Diffstat (limited to 'extensions/source')
-rw-r--r--extensions/source/abpilot/abpfinalpage.cxx4
-rw-r--r--extensions/source/bibliography/general.cxx2
-rw-r--r--extensions/source/dbpilots/controlwizard.cxx2
-rw-r--r--extensions/source/plugin/base/context.cxx2
-rw-r--r--extensions/source/plugin/base/xplugin.cxx2
-rw-r--r--extensions/source/propctrlr/formcomponenthandler.cxx6
-rw-r--r--extensions/source/propctrlr/pcrcommon.cxx4
7 files changed, 11 insertions, 11 deletions
diff --git a/extensions/source/abpilot/abpfinalpage.cxx b/extensions/source/abpilot/abpfinalpage.cxx
index 337b7329fbc6..55da306eac9d 100644
--- a/extensions/source/abpilot/abpfinalpage.cxx
+++ b/extensions/source/abpilot/abpfinalpage.cxx
@@ -87,7 +87,7 @@ namespace abp
AddressSettings& rSettings = getSettings();
INetURLObject aURL( rSettings.sDataSourceName );
- if( aURL.GetProtocol() == INET_PROT_NOT_VALID )
+ if( aURL.GetProtocol() == INetProtocol::NOT_VALID )
{
OUString sPath = SvtPathOptions().GetWorkPath();
sPath += "/";
@@ -102,7 +102,7 @@ namespace abp
aURL.SetURL(sPath);
}
- OSL_ENSURE( aURL.GetProtocol() != INET_PROT_NOT_VALID ,"No valid file name!");
+ OSL_ENSURE( aURL.GetProtocol() != INetProtocol::NOT_VALID ,"No valid file name!");
rSettings.sDataSourceName = aURL.GetMainURL( INetURLObject::NO_DECODE );
m_pLocationController->setURL( rSettings.sDataSourceName );
OUString sName = aURL.getName( );
diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx
index f6cbfee4023a..736bba151f28 100644
--- a/extensions/source/bibliography/general.cxx
+++ b/extensions/source/bibliography/general.cxx
@@ -448,7 +448,7 @@ uno::Reference< awt::XControlModel > BibGeneralPage::AddXControl(
if(xPropInfo->hasPropertyByName(uProp))
{
OUString sId( INET_HID_SCHEME );
- DBG_ASSERT( INetURLObject( OStringToOUString( sHelpId, RTL_TEXTENCODING_UTF8 ) ).GetProtocol() == INET_PROT_NOT_VALID, "Wrong HelpId!" );
+ DBG_ASSERT( INetURLObject( OStringToOUString( sHelpId, RTL_TEXTENCODING_UTF8 ) ).GetProtocol() == INetProtocol::NOT_VALID, "Wrong HelpId!" );
sId += OStringToOUString( sHelpId, RTL_TEXTENCODING_UTF8 );
xPropSet->setPropertyValue( uProp, makeAny( sId ) );
}
diff --git a/extensions/source/dbpilots/controlwizard.cxx b/extensions/source/dbpilots/controlwizard.cxx
index 061f7659db41..4aa7b278479f 100644
--- a/extensions/source/dbpilots/controlwizard.cxx
+++ b/extensions/source/dbpilots/controlwizard.cxx
@@ -202,7 +202,7 @@ namespace dbp
}
INetURLObject aURL( sDataSource );
- if( aURL.GetProtocol() != INET_PROT_NOT_VALID )
+ if( aURL.GetProtocol() != INetProtocol::NOT_VALID )
sDataSource = aURL.GetName(INetURLObject::DECODE_WITH_CHARSET);
m_pFormDatasource->SetText(sDataSource);
m_pFormTable->SetText(sCommand);
diff --git a/extensions/source/plugin/base/context.cxx b/extensions/source/plugin/base/context.cxx
index 31250b59996b..c4007ab8d30a 100644
--- a/extensions/source/plugin/base/context.cxx
+++ b/extensions/source/plugin/base/context.cxx
@@ -131,7 +131,7 @@ void XPluginContext_Impl::getURL(const Reference< ::com::sun::star::plugin::XPlu
if( target.isEmpty() )
{
INetURLObject aURL;
- aURL.SetSmartProtocol( INET_PROT_FILE );
+ aURL.SetSmartProtocol( INetProtocol::FILE );
aURL.SetSmartURL( url );
OUString aUrl = aURL.GetMainURL(INetURLObject::DECODE_TO_IURI);
diff --git a/extensions/source/plugin/base/xplugin.cxx b/extensions/source/plugin/base/xplugin.cxx
index cef5e4be347c..41feb4e86f26 100644
--- a/extensions/source/plugin/base/xplugin.cxx
+++ b/extensions/source/plugin/base/xplugin.cxx
@@ -1051,7 +1051,7 @@ void PluginInputStream::load()
Guard< Mutex > aGuard( m_pPlugin->getMutex() );
INetURLObject aUrl;
- aUrl.SetSmartProtocol( INET_PROT_FILE );
+ aUrl.SetSmartProtocol( INetProtocol::FILE );
aUrl.SetSmartURL(
OUString( getStream().url,
strlen( getStream().url ),
diff --git a/extensions/source/propctrlr/formcomponenthandler.cxx b/extensions/source/propctrlr/formcomponenthandler.cxx
index ae7a46c86dec..b0077113d932 100644
--- a/extensions/source/propctrlr/formcomponenthandler.cxx
+++ b/extensions/source/propctrlr/formcomponenthandler.cxx
@@ -2432,7 +2432,7 @@ namespace pcr
}
// additional info about what happened
INetURLObject aParser( sDataSourceName );
- if ( aParser.GetProtocol() != INET_PROT_NOT_VALID )
+ if ( aParser.GetProtocol() != INetProtocol::NOT_VALID )
sDataSourceName = aParser.getBase( INetURLObject::LAST_SEGMENT, true, INetURLObject::DECODE_WITH_CHARSET );
OUString sInfo(PcrRes(RID_STR_UNABLETOCONNECT).toString().replaceAll("$name$", sDataSourceName));
SQLContext aContext;
@@ -2845,7 +2845,7 @@ namespace pcr
OUString sURL;
OSL_VERIFY( impl_getPropertyValue_throw( PROPERTY_TARGET_URL ) >>= sURL );
INetURLObject aParser( sURL );
- if ( INET_PROT_FILE == aParser.GetProtocol() )
+ if ( INetProtocol::FILE == aParser.GetProtocol() )
// set the initial directory only for file-URLs. Everything else
// is considered to be potentially expensive
aFileDlg.SetDisplayDirectory( sURL );
@@ -2900,7 +2900,7 @@ namespace pcr
OUString sDataSource;
OSL_VERIFY( impl_getPropertyValue_throw( PROPERTY_DATASOURCE ) >>= sDataSource );
INetURLObject aParser( sDataSource );
- if ( INET_PROT_FILE == aParser.GetProtocol() )
+ if ( INetProtocol::FILE == aParser.GetProtocol() )
// set the initial directory only for file-URLs. Everything else
// is considered to be potentially expensive
aFileDlg.SetDisplayDirectory( sDataSource );
diff --git a/extensions/source/propctrlr/pcrcommon.cxx b/extensions/source/propctrlr/pcrcommon.cxx
index 9292a029a4e8..25bed3f418fd 100644
--- a/extensions/source/propctrlr/pcrcommon.cxx
+++ b/extensions/source/propctrlr/pcrcommon.cxx
@@ -39,7 +39,7 @@ namespace pcr
OString HelpIdUrl::getHelpId( const OUString& _rHelpURL )
{
INetURLObject aHID( _rHelpURL );
- if ( aHID.GetProtocol() == INET_PROT_HID )
+ if ( aHID.GetProtocol() == INetProtocol::HID )
return OUStringToOString( aHID.GetURLPath(), RTL_TEXTENCODING_UTF8 );
else
return OUStringToOString( _rHelpURL, RTL_TEXTENCODING_UTF8 );
@@ -51,7 +51,7 @@ namespace pcr
OUStringBuffer aBuffer;
OUString aTmp( OStringToOUString(sHelpId, RTL_TEXTENCODING_UTF8) );
INetURLObject aHID( aTmp );
- if ( aHID.GetProtocol() == INET_PROT_NOT_VALID )
+ if ( aHID.GetProtocol() == INetProtocol::NOT_VALID )
aBuffer.appendAscii( INET_HID_SCHEME );
aBuffer.append( aTmp.getStr() );
return aBuffer.makeStringAndClear();