diff options
author | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-05-08 11:48:30 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-05-08 14:23:05 -0400 |
commit | 1af56c22b4b17922f43b67aaf1ceb9562b98f941 (patch) | |
tree | 4d066f129b19a7e83ccf5f2161aaf4e6ed1a5d03 /sc/source/ui/unoobj/notesuno.cxx | |
parent | 63114e6d863de32e2d93f0da54caca928916d9c2 (diff) |
Adjust ScEditFieldObj for the change done in SvxUnoTextRangeBase.
Treat date and time field types together, and handle appropriate
properties to have it not throw UnknownPropertyValue exception.
Change-Id: I6a4c512fb3030bfc48ab7372cb1a217069dedfc4
Diffstat (limited to 'sc/source/ui/unoobj/notesuno.cxx')
-rw-r--r-- | sc/source/ui/unoobj/notesuno.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/unoobj/notesuno.cxx b/sc/source/ui/unoobj/notesuno.cxx index 1ed78c914fde..f94e812bb0a5 100644 --- a/sc/source/ui/unoobj/notesuno.cxx +++ b/sc/source/ui/unoobj/notesuno.cxx @@ -391,7 +391,9 @@ void SAL_CALL ScAnnotationShapeObj::insertTextContent( const uno::Reference< tex uno::RuntimeException) { SolarMutexGuard aGuard; - +#if 1 + GetUnoText().insertTextContent(xRange, xContent, bAbsorb); +#else // Evil hack to convert a ScEditFieldObj based text field into a // SvxUnoTextField based one. See SvxUnoTextBase::insertTextContent() for // the reason why. We need a clean solution for this. @@ -402,6 +404,7 @@ void SAL_CALL ScAnnotationShapeObj::insertTextContent( const uno::Reference< tex xContent2.set(new SvxUnoTextField(pField->GetFieldType())); GetUnoText().insertTextContent(xRange, xContent2, bAbsorb); +#endif } void SAL_CALL ScAnnotationShapeObj::removeTextContent( const uno::Reference< text::XTextContent >& xContent ) |