summaryrefslogtreecommitdiff
path: root/forms/source/component/refvaluecomponent.cxx
diff options
context:
space:
mode:
authorVladimir Glazounov <vg@openoffice.org>2006-03-15 08:23:51 +0000
committerVladimir Glazounov <vg@openoffice.org>2006-03-15 08:23:51 +0000
commitad0adcdb90c9a11eb95c2da5b9fd45c7aa21f7fc (patch)
tree2bc5734578972f1f9bfdaa8c8b445f29b02b12d0 /forms/source/component/refvaluecomponent.cxx
parent62c45cfd13e8ebdce7151bc10293648206ed5d80 (diff)
INTEGRATION: CWS jsc3 (1.4.64); FILE MERGED
2006/02/22 15:23:34 fs 1.4.64.1: #i62418# correct translateControlValueToValidatableValue
Diffstat (limited to 'forms/source/component/refvaluecomponent.cxx')
-rw-r--r--forms/source/component/refvaluecomponent.cxx27
1 files changed, 25 insertions, 2 deletions
diff --git a/forms/source/component/refvaluecomponent.cxx b/forms/source/component/refvaluecomponent.cxx
index 3b340693d66e..f8193575c28b 100644
--- a/forms/source/component/refvaluecomponent.cxx
+++ b/forms/source/component/refvaluecomponent.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: refvaluecomponent.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: rt $ $Date: 2005-09-08 22:51:35 $
+ * last change: $Author: vg $ $Date: 2006-03-15 09:23:51 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -306,6 +306,29 @@ namespace frm
return aExternalValue;
}
+ //-----------------------------------------------------------------------------
+ Any OReferenceValueComponent::translateControlValueToValidatableValue( ) const
+ {
+ if ( !m_xAggregateSet.is() )
+ return Any();
+
+ Any aControlValue( m_xAggregateSet->getPropertyValue( PROPERTY_STATE ) );
+ sal_Int16 nControlValue = STATE_DONTKNOW;
+ aControlValue >>= nControlValue;
+
+ Any aValidatableValue;
+ switch ( nControlValue )
+ {
+ case STATE_CHECK:
+ aValidatableValue <<= (sal_Bool)sal_True;
+ break;
+ case STATE_NOCHECK:
+ aValidatableValue <<= (sal_Bool)sal_False;
+ break;
+ }
+ return aValidatableValue;
+ }
+
//........................................................................
} // namespace frm
//........................................................................