Removing EXTENDED_DATE. There is really no such thing.

This can be safely substituted by the normal DATE.

Change-Id: I I6b4ccfa342a8d7b638b013cdce64a0b7ff477ec0
This commit is contained in:
Kohei Yoshida
2012-05-11 13:03:07 -04:00
parent 02a89fdb0e
commit ee5fc5d25f
7 changed files with 4 additions and 20 deletions

View File

@@ -63,7 +63,6 @@ SvxFieldData* SvxFieldData::Create(const uno::Reference<text::XTextContent>& xTe
case text::textfield::Type::TIME: case text::textfield::Type::TIME:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::EXTENDED_DATE:
{ {
sal_Bool bIsDate = false; sal_Bool bIsDate = false;
xPropSet->getPropertyValue(UNO_TC_PROP_IS_DATE) >>= bIsDate; xPropSet->getPropertyValue(UNO_TC_PROP_IS_DATE) >>= bIsDate;

View File

@@ -146,7 +146,6 @@ const SfxItemPropertySet* ImplGetFieldItemPropertySet( sal_Int32 mnId )
switch( mnId ) switch( mnId )
{ {
case text::textfield::Type::EXTENDED_DATE:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
return &aExDateTimeFieldPropertySet_Impl; return &aExDateTimeFieldPropertySet_Impl;
@@ -266,7 +265,6 @@ SvxUnoTextField::SvxUnoTextField( sal_Int32 nServiceId ) throw()
switch( nServiceId ) switch( nServiceId )
{ {
case text::textfield::Type::EXTENDED_DATE:
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
mpImpl->mbBoolean2 = sal_True; mpImpl->mbBoolean2 = sal_True;
mpImpl->mnInt32 = SVXDATEFORMAT_STDSMALL; mpImpl->mnInt32 = SVXDATEFORMAT_STDSMALL;
@@ -329,7 +327,6 @@ SvxUnoTextField::SvxUnoTextField( uno::Reference< text::XTextRange > xAnchor, co
switch( mnServiceId ) switch( mnServiceId )
{ {
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::EXTENDED_DATE:
{ {
mpImpl->mbBoolean2 = sal_True; mpImpl->mbBoolean2 = sal_True;
// #i35416# for variable date field, don't use invalid "0000-00-00" date, // #i35416# for variable date field, don't use invalid "0000-00-00" date,
@@ -403,7 +400,6 @@ SvxFieldData* SvxUnoTextField::CreateFieldData() const throw()
case text::textfield::Type::TIME: case text::textfield::Type::TIME:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::EXTENDED_DATE:
{ {
if( mpImpl->mbBoolean2 ) // IsDate? if( mpImpl->mbBoolean2 ) // IsDate?
{ {
@@ -630,8 +626,6 @@ OUString SAL_CALL SvxUnoTextField::getPresentation( sal_Bool bShowCommand )
return OUString("Footer"); return OUString("Footer");
case text::textfield::Type::PRESENTATION_DATE_TIME: case text::textfield::Type::PRESENTATION_DATE_TIME:
return OUString("DateTime"); return OUString("DateTime");
case text::textfield::Type::EXTENDED_DATE:
return OUString("ExtDate");
default: default:
return OUString("Unknown"); return OUString("Unknown");
} }
@@ -879,10 +873,6 @@ uno::Sequence< OUString > SAL_CALL SvxUnoTextField::getSupportedServiceNames()
pServices[2] = "com.sun.star.presentation.TextField.DateTime"; pServices[2] = "com.sun.star.presentation.TextField.DateTime";
pServices[3] = "com.sun.star.presentation.textfield.DateTime"; pServices[3] = "com.sun.star.presentation.textfield.DateTime";
break; break;
case text::textfield::Type::EXTENDED_DATE:
pServices[2] = "com.sun.star.text.TextField.DateTime";
pServices[3] = "com.sun.star.text.textfield.DateTime";
break;
default: default:
aSeq.realloc(0); aSeq.realloc(0);
} }

View File

@@ -245,7 +245,7 @@ uno::Reference< uno::XInterface > SAL_CALL SvxSimpleUnoModel::createInstance( co
RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime"))) RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime")))
) )
{ {
return (::cppu::OWeakObject * )new SvxUnoTextField( text::textfield::Type::EXTENDED_DATE ); return (::cppu::OWeakObject * )new SvxUnoTextField( text::textfield::Type::DATE );
} }
return SvxUnoTextCreateTextField( aServiceSpecifier ); return SvxUnoTextCreateTextField( aServiceSpecifier );

View File

@@ -60,8 +60,6 @@ constants Type
const long PRESENTATION_HEADER = 11; const long PRESENTATION_HEADER = 11;
const long PRESENTATION_FOOTER = 12; const long PRESENTATION_FOOTER = 12;
const long PRESENTATION_DATE_TIME = 13; const long PRESENTATION_DATE_TIME = 13;
const long EXTENDED_DATE = 14;
}; };
}; }; }; }; }; }; }; }; }; };

View File

@@ -1166,7 +1166,6 @@ ScEditFieldObj::ScEditFieldObj(
pPropSet = lcl_GetURLPropertySet(); pPropSet = lcl_GetURLPropertySet();
break; break;
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::EXTENDED_DATE:
case text::textfield::Type::TIME: case text::textfield::Type::TIME:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
pPropSet = getDateTimePropertySet(); pPropSet = getDateTimePropertySet();
@@ -1175,7 +1174,7 @@ ScEditFieldObj::ScEditFieldObj(
pPropSet = lcl_GetHeaderFieldPropertySet(); pPropSet = lcl_GetHeaderFieldPropertySet();
} }
if (meType == text::textfield::Type::DATE || meType == text::textfield::Type::EXTENDED_DATE) if (meType == text::textfield::Type::DATE)
mbIsDate = true; mbIsDate = true;
} }
@@ -1343,7 +1342,6 @@ void SAL_CALL ScEditFieldObj::setPropertyValue(
setPropertyValueFile(aPropertyName, aValue); setPropertyValueFile(aPropertyName, aValue);
break; break;
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::EXTENDED_DATE:
case text::textfield::Type::TIME: case text::textfield::Type::TIME:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
setPropertyValueDateTime(aPropertyName, aValue); setPropertyValueDateTime(aPropertyName, aValue);
@@ -1397,7 +1395,6 @@ uno::Any SAL_CALL ScEditFieldObj::getPropertyValue( const rtl::OUString& aProper
return getPropertyValueFile(aPropertyName); return getPropertyValueFile(aPropertyName);
case text::textfield::Type::DATE: case text::textfield::Type::DATE:
case text::textfield::Type::TIME: case text::textfield::Type::TIME:
case text::textfield::Type::EXTENDED_DATE:
case text::textfield::Type::EXTENDED_TIME: case text::textfield::Type::EXTENDED_TIME:
return getPropertyValueDateTime(aPropertyName); return getPropertyValueDateTime(aPropertyName);
case text::textfield::Type::FILE: case text::textfield::Type::FILE:

View File

@@ -907,7 +907,7 @@ uno::Reference< uno::XInterface > SAL_CALL SdXImpressDocument::createInstance( c
if( ( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime") ) ) || if( ( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime") ) ) ||
( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.textfield.DateTime") ) ) ) ( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.textfield.DateTime") ) ) )
{ {
return (::cppu::OWeakObject * )new SvxUnoTextField( text::textfield::Type::EXTENDED_DATE ); return (::cppu::OWeakObject * )new SvxUnoTextField( text::textfield::Type::DATE );
} }
if( (0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.presentation.TextField.Header"))) || if( (0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.presentation.TextField.Header"))) ||

View File

@@ -413,7 +413,7 @@ uno::Reference< uno::XInterface > SAL_CALL SvxUnoDrawingModel::createInstance( c
if( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime") ) ) if( 0 == aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextField.DateTime") ) )
{ {
return (::cppu::OWeakObject * )new SvxUnoTextField(text::textfield::Type::EXTENDED_DATE); return (::cppu::OWeakObject * )new SvxUnoTextField(text::textfield::Type::DATE);
} }
uno::Reference< uno::XInterface > xRet; uno::Reference< uno::XInterface > xRet;