[Libreoffice-commits] core.git: accessibility/inc accessibility/source
Stephan Bergmann
sbergman at redhat.com
Tue Jun 27 14:09:12 UTC 2017
accessibility/inc/extended/textwindowaccessibility.hxx | 14 ----
accessibility/source/extended/textwindowaccessibility.cxx | 43 +-------------
2 files changed, 4 insertions(+), 53 deletions(-)
New commits:
commit 4ab979fce0f92733da568b5ef58b4272738740f5
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue Jun 27 16:07:10 2017 +0200
Document::retrieveDefaultAttributesImpl did nothing
...ever since dac3b388798e78803a5df77894bfd30cddeb77c3 "INTEGRATION: CWS
a11ysep"
Change-Id: I1bba12e9f6ab69cf561a7eda010cefba91c47a49
diff --git a/accessibility/inc/extended/textwindowaccessibility.hxx b/accessibility/inc/extended/textwindowaccessibility.hxx
index c44c028b8459..d30259c2a70d 100644
--- a/accessibility/inc/extended/textwindowaccessibility.hxx
+++ b/accessibility/inc/extended/textwindowaccessibility.hxx
@@ -412,15 +412,6 @@ public:
// within Paragraph's constructor (i.e., when the Paragraph's ref count is
// still zero), pass a "Paragraph const &" instead of a
// "::rtl::Reference< Paragraph > const &".
- css::uno::Sequence< css::beans::PropertyValue > retrieveDefaultAttributes(
- Paragraph const * pParagraph,
- const css::uno::Sequence< OUString >& RequestedAttributes);
-
- // Must be called only after init has been called.
- // To make it possible for this method to be (indirectly) called from
- // within Paragraph's constructor (i.e., when the Paragraph's ref count is
- // still zero), pass a "Paragraph const &" instead of a
- // "::rtl::Reference< Paragraph > const &".
// Throws css::lang::IndexOutOfBoundsException.
css::uno::Sequence< css::beans::PropertyValue > retrieveRunAttributes(
Paragraph const * pParagraph, ::sal_Int32 Index,
@@ -563,11 +554,6 @@ private:
static ::FontWeight mapFontWeight(css::uno::Any const & rWeight);
- static void retrieveDefaultAttributesImpl(
- Paragraph const * pParagraph,
- const css::uno::Sequence< OUString >& RequestedAttributes,
- tPropValMap& rDefAttrSeq);
-
void retrieveRunAttributesImpl(
Paragraph const * pParagraph, ::sal_Int32 Index,
const css::uno::Sequence< OUString >& RequestedAttributes,
diff --git a/accessibility/source/extended/textwindowaccessibility.cxx b/accessibility/source/extended/textwindowaccessibility.cxx
index 322118940159..9d0e19931131 100644
--- a/accessibility/source/extended/textwindowaccessibility.cxx
+++ b/accessibility/source/extended/textwindowaccessibility.cxx
@@ -489,10 +489,10 @@ sal_Bool SAL_CALL Paragraph::setText(OUString const & rText)
// virtual
css::uno::Sequence< css::beans::PropertyValue > SAL_CALL
-Paragraph::getDefaultAttributes(const css::uno::Sequence< OUString >& RequestedAttributes)
+Paragraph::getDefaultAttributes(const css::uno::Sequence< OUString >&)
{
checkDisposed();
- return m_xDocument->retrieveDefaultAttributes( this, RequestedAttributes );
+ return {}; // default attributes are not supported by text engine
}
// virtual
@@ -1017,21 +1017,10 @@ Document::retrieveCharacterAttributes(
" Document::retrieveCharacterAttributes",
static_cast< css::uno::XWeak * >(this));
- // retrieve default attributes
- tPropValMap aCharAttrSeq;
- retrieveDefaultAttributesImpl( pParagraph, aRequestedAttributes, aCharAttrSeq );
// retrieve run attributes
- tPropValMap aRunAttrSeq;
- retrieveRunAttributesImpl( pParagraph, nIndex, aRequestedAttributes, aRunAttrSeq );
-
- // merge default and run attributes
- for ( tPropValMap::const_iterator aRunIter = aRunAttrSeq.begin();
- aRunIter != aRunAttrSeq.end();
- ++aRunIter )
- {
- aCharAttrSeq[ aRunIter->first ] = aRunIter->second;
- }
+ tPropValMap aCharAttrSeq;
+ retrieveRunAttributesImpl( pParagraph, nIndex, aRequestedAttributes, aCharAttrSeq );
css::beans::PropertyValue* pValues = aAttribs.getArray();
for (i = 0; i < AttributeCount; i++,pValues++)
@@ -1059,30 +1048,6 @@ Document::retrieveCharacterAttributes(
return aNewValues;
}
-void Document::retrieveDefaultAttributesImpl(
- Paragraph const * pParagraph,
- const css::uno::Sequence< OUString >& RequestedAttributes,
- tPropValMap& rDefAttrSeq)
-{
- // default attributes are not supported by text engine
- (void) pParagraph;
- (void) RequestedAttributes;
- (void) rDefAttrSeq;
-}
-
-css::uno::Sequence< css::beans::PropertyValue >
-Document::retrieveDefaultAttributes(
- Paragraph const * pParagraph,
- const css::uno::Sequence< OUString >& RequestedAttributes)
-{
- SolarMutexGuard aGuard;
- ::osl::MutexGuard aInternalGuard( GetMutex() );
-
- tPropValMap aDefAttrSeq;
- retrieveDefaultAttributesImpl( pParagraph, RequestedAttributes, aDefAttrSeq );
- return comphelper::mapValuesToSequence( aDefAttrSeq );
-}
-
void Document::retrieveRunAttributesImpl(
Paragraph const * pParagraph, ::sal_Int32 Index,
const css::uno::Sequence< OUString >& RequestedAttributes,
More information about the Libreoffice-commits
mailing list