diff options
author | Eike Rathke <erack@redhat.com> | 2016-02-25 20:06:23 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-02-26 01:41:49 +0100 |
commit | 8555034abf9e53190fa559c1a705868766a5677f (patch) | |
tree | efa5d7ff742aba7399152ccefe26260e372617f0 | |
parent | ced11176337a1b37ed32ca9ea2aa3af0b2459b02 (diff) |
handle SearchWildcard API option
Change-Id: I5350167638a5831e1f125728397fecfc637ee004
-rw-r--r-- | sc/inc/unonames.hxx | 1 | ||||
-rw-r--r-- | sc/source/ui/unoobj/srchuno.cxx | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/sc/inc/unonames.hxx b/sc/inc/unonames.hxx index c03178943fe7..415399e1caef 100644 --- a/sc/inc/unonames.hxx +++ b/sc/inc/unonames.hxx @@ -368,6 +368,7 @@ #define SC_UNO_SRCHBYROW "SearchByRow" #define SC_UNO_SRCHCASE "SearchCaseSensitive" #define SC_UNO_SRCHREGEXP "SearchRegularExpression" +#define SC_UNO_SRCHWILDCARD "SearchWildcard" #define SC_UNO_SRCHSIM "SearchSimilarity" #define SC_UNO_SRCHSIMADD "SearchSimilarityAdd" #define SC_UNO_SRCHSIMEX "SearchSimilarityExchange" diff --git a/sc/source/ui/unoobj/srchuno.cxx b/sc/source/ui/unoobj/srchuno.cxx index edc4809ed342..1ad31eb41f5e 100644 --- a/sc/source/ui/unoobj/srchuno.cxx +++ b/sc/source/ui/unoobj/srchuno.cxx @@ -46,6 +46,7 @@ static const SfxItemPropertyMapEntry* lcl_GetSearchPropertyMap() {OUString(SC_UNO_SRCHBYROW), 0, cppu::UnoType<bool>::get(), 0, 0}, {OUString(SC_UNO_SRCHCASE), 0, cppu::UnoType<bool>::get(), 0, 0}, {OUString(SC_UNO_SRCHREGEXP), 0, cppu::UnoType<bool>::get(), 0, 0}, + {OUString(SC_UNO_SRCHWILDCARD), 0, cppu::UnoType<bool>::get(), 0, 0}, {OUString(SC_UNO_SRCHSIM), 0, cppu::UnoType<bool>::get(), 0, 0}, {OUString(SC_UNO_SRCHSIMADD), 0, cppu::UnoType<sal_Int16>::get(), 0, 0}, {OUString(SC_UNO_SRCHSIMEX), 0, cppu::UnoType<sal_Int16>::get(), 0, 0}, @@ -74,6 +75,7 @@ ScCellSearchObj::ScCellSearchObj() : pSearchItem->SetBackward(false); pSearchItem->SetSelection(false); pSearchItem->SetRegExp(false); + pSearchItem->SetWildcard(false); pSearchItem->SetPattern(false); pSearchItem->SetLevenshtein(false); pSearchItem->SetLEVRelaxed(false); @@ -146,6 +148,7 @@ void SAL_CALL ScCellSearchObj::setPropertyValue( else if (aString == SC_UNO_SRCHBYROW) pSearchItem->SetRowDirection( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); else if (aString == SC_UNO_SRCHCASE) pSearchItem->SetExact( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); else if (aString == SC_UNO_SRCHREGEXP) pSearchItem->SetRegExp( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); + else if (aString == SC_UNO_SRCHWILDCARD) pSearchItem->SetWildcard( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); else if (aString == SC_UNO_SRCHSIM) pSearchItem->SetLevenshtein( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); else if (aString == SC_UNO_SRCHSIMREL) pSearchItem->SetLEVRelaxed( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); else if (aString == SC_UNO_SRCHSTYLES) pSearchItem->SetPattern( ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); @@ -170,6 +173,7 @@ uno::Any SAL_CALL ScCellSearchObj::getPropertyValue( const OUString& aPropertyNa else if (aString == SC_UNO_SRCHBYROW) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->GetRowDirection() ); else if (aString == SC_UNO_SRCHCASE) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->GetExact() ); else if (aString == SC_UNO_SRCHREGEXP) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->GetRegExp() ); + else if (aString == SC_UNO_SRCHWILDCARD) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->GetWildcard() ); else if (aString == SC_UNO_SRCHSIM) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->IsLevenshtein() ); else if (aString == SC_UNO_SRCHSIMREL) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->IsLEVRelaxed() ); else if (aString == SC_UNO_SRCHSTYLES) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->GetPattern() ); |