summaryrefslogtreecommitdiff
path: root/dbaccess/source/ui/control/FieldDescControl.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'dbaccess/source/ui/control/FieldDescControl.cxx')
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx15
1 files changed, 12 insertions, 3 deletions
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index 972d6c92c355..735e8264840c 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -1375,6 +1375,14 @@ void OFieldDescControl::DisplayData(OFieldDescription* pFieldDescr )
ActivateAggregate( tpFormat );
break;
case DataType::BIT:
+ if ( pFieldType->aCreateParams.getLength() )
+ {
+ DeactivateAggregate( tpFormat );
+ DeactivateAggregate( tpTextLen );
+ DeactivateAggregate( tpBoolDefault );
+ break;
+ }
+ // run through
case DataType::BOOLEAN:
DeactivateAggregate( tpTextLen );
DeactivateAggregate( tpFormat );
@@ -1473,7 +1481,9 @@ void OFieldDescControl::DisplayData(OFieldDescription* pFieldDescr )
if( pBoolDefault )
{
// wenn pRequired auf sal_True gesetzt ist, dann darf das sal_Bool Feld nicht den Eintrag <<keiner>> besitzen
- String sDef = BoolStringUI(::comphelper::getString(pFieldDescr->GetControlDefault()));
+ ::rtl::OUString sValue;
+ pFieldDescr->GetControlDefault() >>= sValue;
+ String sDef = BoolStringUI(sValue);
// sicher stellen das <<keiner>> nur vorhanden ist, wenn das Feld NULL sein darf
if ( ( pFieldType.get() && !pFieldType->bNullable ) || !pFieldDescr->IsNullable() )
@@ -1667,8 +1677,7 @@ void OFieldDescControl::SaveData( OFieldDescription* pFieldDescr )
::rtl::OUString sDefault;
if (pDefault)
{
- if ( pDefault->GetSavedValue() != pDefault->GetText() )
- sDefault = pDefault->GetText();
+ sDefault = pDefault->GetText();
}
else if (pBoolDefault)
{