diff options
Diffstat (limited to 'svtools/source/control/inettbc.cxx')
-rwxr-xr-x[-rw-r--r--] | svtools/source/control/inettbc.cxx | 33 |
1 files changed, 11 insertions, 22 deletions
diff --git a/svtools/source/control/inettbc.cxx b/svtools/source/control/inettbc.cxx index 02a578629039..574f2bde4e1e 100644..100755 --- a/svtools/source/control/inettbc.cxx +++ b/svtools/source/control/inettbc.cxx @@ -33,7 +33,6 @@ #include <sys/types.h> #endif - #include <svtools/inettbc.hxx> #include <com/sun/star/uno/Any.hxx> #include <com/sun/star/uno/Reference.hxx> @@ -41,27 +40,16 @@ #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/sdbc/XResultSet.hpp> #include <com/sun/star/sdbc/XRow.hpp> - -#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HDL_ -#include <com/sun/star/task/XInteractionHandler.hdl> -#endif +#include <com/sun/star/task/XInteractionHandler.hpp> #include <com/sun/star/ucb/NumberedSortingInfo.hpp> #include <com/sun/star/ucb/XAnyCompareFactory.hpp> #include <com/sun/star/ucb/XProgressHandler.hpp> #include <com/sun/star/ucb/XContentAccess.hpp> #include <com/sun/star/ucb/XSortedDynamicResultSetFactory.hpp> - -#ifndef _UNOTOOLS_PROCESSFACTORY_HXX #include <comphelper/processfactory.hxx> -#endif - #include <vcl/toolbox.hxx> -#ifndef _VOS_THREAD_HXX //autogen #include <vos/thread.hxx> -#endif -#ifndef _VOS_MUTEX_HXX //autogen #include <vos/mutex.hxx> -#endif #include <vcl/svapp.hxx> #include <unotools/historyoptions.hxx> #include <svl/eitem.hxx> @@ -76,9 +64,8 @@ #include <ucbhelper/content.hxx> #include <unotools/localfilehelper.hxx> #include <unotools/ucbhelper.hxx> - #include "iodlg.hrc" -#include <asynclink.hxx> +#include <svtools/asynclink.hxx> #include <svl/urlfilter.hxx> #include <vector> @@ -165,7 +152,7 @@ SvtMatchContext_Impl::SvtMatchContext_Impl( SvtURLBox* pBoxP, const String& rText ) : aLink( STATIC_LINK( this, SvtMatchContext_Impl, Select_Impl ) ) , aBaseURL( pBoxP->aBaseURL ) - , aText( rText ) + , aText( rText ) , pBox( pBoxP ) , bStop( FALSE ) , bOnlyDirectories( pBoxP->bOnlyDirectories ) @@ -426,7 +413,7 @@ void SvtMatchContext_Impl::ReadFolder( const String& rURL, uno::Reference< XDynamicResultSet > xDynResultSet; ResultSetInclude eInclude = INCLUDE_FOLDERS_AND_DOCUMENTS; if ( bOnlyDirectories ) - eInclude = INCLUDE_FOLDERS_ONLY; + eInclude = INCLUDE_FOLDERS_ONLY; xDynResultSet = aCnt.createDynamicCursor( aProps, eInclude ); @@ -654,7 +641,7 @@ void SvtMatchContext_Impl::run() { // if text input is a directory, it must be part of the match list! Until then it is scanned if ( UCBContentHelper::IsFolder( aMainURL ) && aURLObject.hasFinalSlash() ) - Insert( aText, aMatch ); + Insert( aText, aMatch ); else // otherwise the parent folder will be taken aURLObject.removeSegment(); @@ -684,6 +671,7 @@ void SvtMatchContext_Impl::run() aCurObj.SetURL( *aPickList.GetObject( nPos ) ); aCurObj.SetSmartURL( aCurObj.GetURLNoPass()); aCurMainURL = aCurObj.GetMainURL( INetURLObject::NO_DECODE ); + if( eProt != INET_PROT_NOT_VALID && aCurObj.GetProtocol() != eProt ) continue; @@ -708,7 +696,7 @@ void SvtMatchContext_Impl::run() { // try if text matches the scheme String aScheme( INetURLObject::GetScheme( aCurObj.GetProtocol() ) ); - if ( aText.CompareTo( aScheme, aText.Len() ) == COMPARE_EQUAL && aText.Len() < aScheme.Len() ) + if ( aText.CompareIgnoreCaseToAscii( aScheme, aText.Len() ) == COMPARE_EQUAL && aText.Len() < aScheme.Len() ) { if( bFull ) aMatch = aCurObj.GetMainURL( INetURLObject::NO_DECODE ); @@ -727,7 +715,7 @@ void SvtMatchContext_Impl::run() aCurString.Erase( 0, aScheme.Len() ); } - if( aText.CompareTo( aCurString, aText.Len() )== COMPARE_EQUAL ) + if( aText.CompareIgnoreCaseToAscii( aCurString, aText.Len() )== COMPARE_EQUAL ) { if( bFull ) aMatch = aCurObj.GetMainURL( INetURLObject::NO_DECODE ); @@ -858,7 +846,8 @@ SvtURLBox::SvtURLBox( Window* pParent, const ResId& _rResId, INetProtocol eSmart void SvtURLBox::ImplInit() { pImp = new SvtURLBox_Impl(); - SetHelpId( SID_OPENURL ); + + SetHelpId( ".uno:OpenURL" ); EnableAutocomplete( FALSE ); SetText( String() ); @@ -1314,7 +1303,7 @@ sal_Bool SvtURLBox_Impl::TildeParsing( return sal_False; // no such user #else pPasswd = getpwnam( OUStringToOString( OUString( aUserName ), RTL_TEXTENCODING_ASCII_US ).getStr() ); - if( pPasswd ) + if( pPasswd ) aParseTilde = String::CreateFromAscii( pPasswd->pw_dir ); else return sal_False; // no such user |