Kaydet (Commit) 66ccfcd2 authored tarafından Jochen Nitschke's avatar Jochen Nitschke Kaydeden (comit) Stephan Bergmann

remove use of tryPropertyValue Any specialisation

change return value of getCurrentMultiValue from Any<Sequence<Any> >
to Sequence<Any>.
return value of getCurrentSingleValue (Any of connectivity::ORowSetValue)
can't be changed to use tryPropertyValue.
inline functionality

Change-Id: I3180cf5b9e63a3da9257b03ba02967a2d5402ec3
Reviewed-on: https://gerrit.libreoffice.org/30091Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
üst 728c9a0d
......@@ -271,7 +271,7 @@ namespace frm
break;
case PROPERTY_ID_SELECT_VALUE_SEQ:
_rValue = getCurrentMultiValue();
_rValue <<= getCurrentMultiValue();
break;
case PROPERTY_ID_SELECT_VALUE:
......@@ -416,9 +416,17 @@ namespace frm
break;
case PROPERTY_ID_SELECT_VALUE :
bModified = tryPropertyValue(_rConvertedValue, _rOldValue, _rValue, getCurrentSingleValue());
{
// Any from connectivity::ORowSetValue
Any _rCurrentValue = getCurrentSingleValue();
if (_rCurrentValue != _rValue)
{
_rOldValue = _rValue;
_rConvertedValue = _rCurrentValue;
bModified = true;
}
break;
}
case PROPERTY_ID_DEFAULT_SELECT_SEQ :
bModified = tryPropertyValue(_rConvertedValue, _rOldValue, _rValue, m_aDefaultSelectSeq);
break;
......@@ -1517,7 +1525,7 @@ namespace frm
}
Any lcl_getMultiSelectedEntriesAny( const Sequence< sal_Int16 >& _rSelectSequence, const ValueList& _rStringList )
Sequence< Any > lcl_getMultiSelectedEntriesAny( const Sequence< sal_Int16 >& _rSelectSequence, const ValueList& _rStringList )
{
Sequence< Any > aSelectedEntriesValues( _rSelectSequence.getLength() );
::std::transform(
......@@ -1526,7 +1534,7 @@ namespace frm
aSelectedEntriesValues.getArray(),
ExtractAnyFromValueList_Safe( _rStringList )
);
return makeAny( aSelectedEntriesValues );
return aSelectedEntriesValues;
}
}
......@@ -1542,7 +1550,7 @@ namespace frm
switch ( lcl_getCurrentExchangeType( getExternalValueType() ) )
{
case eValueList:
aReturn = getCurrentMultiValue();
aReturn <<= getCurrentMultiValue();
break;
case eValue:
......@@ -1613,9 +1621,9 @@ namespace frm
return aCurrentValue;
}
Any OListBoxModel::getCurrentMultiValue() const
Sequence< Any > OListBoxModel::getCurrentMultiValue() const
{
Any aCurrentValue;
Sequence< Any > aCurrentValue;
try
{
......@@ -1648,7 +1656,7 @@ namespace frm
OSL_VERIFY( const_cast< OListBoxModel* >( this )->getPropertyValue( PROPERTY_MULTISELECTION ) >>= bMultiSelection );
if ( bMultiSelection )
aCurrentValue = getCurrentMultiValue();
aCurrentValue <<= getCurrentMultiValue();
else
aCurrentValue = getCurrentSingleValue();
}
......
......@@ -209,7 +209,7 @@ protected:
void init();
css::uno::Any getCurrentSingleValue() const;
css::uno::Any getCurrentMultiValue() const;
css::uno::Sequence<css::uno::Any> getCurrentMultiValue() const;
css::uno::Sequence< sal_Int16 > translateBindingValuesToControlValue(
const css::uno::Sequence< const css::uno::Any > &i_aValues)
const;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment