Kaydet (Commit) 05d355ca authored tarafından Miklos Vajna's avatar Miklos Vajna

sw: use std::unique_ptr in accpara

Change-Id: I0fcc22f987208ae9fa0e99f14253856ee6faa062
üst 5d81c9f2
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 . * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/ */
#include <memory>
#include <txtfrm.hxx> #include <txtfrm.hxx>
#include <flyfrm.hxx> #include <flyfrm.hxx>
#include <ndtxt.hxx> #include <ndtxt.hxx>
...@@ -83,7 +84,6 @@ ...@@ -83,7 +84,6 @@
#include <unoprnms.hxx> #include <unoprnms.hxx>
#include <com/sun/star/text/WritingMode2.hpp> #include <com/sun/star/text/WritingMode2.hpp>
#include <viewimp.hxx> #include <viewimp.hxx>
#include <boost/scoped_ptr.hpp>
#include <textmarkuphelper.hxx> #include <textmarkuphelper.hxx>
#include <parachangetrackinginfo.hxx> #include <parachangetrackinginfo.hxx>
#include <com/sun/star/text/TextMarkupType.hpp> #include <com/sun/star/text/TextMarkupType.hpp>
...@@ -1741,7 +1741,7 @@ void SwAccessibleParagraph::_getDefaultAttributesImpl( ...@@ -1741,7 +1741,7 @@ void SwAccessibleParagraph::_getDefaultAttributesImpl(
{ {
// retrieve default attributes // retrieve default attributes
const SwTextNode* pTextNode( GetTextNode() ); const SwTextNode* pTextNode( GetTextNode() );
::boost::scoped_ptr<SfxItemSet> pSet; std::unique_ptr<SfxItemSet> pSet;
if ( !bOnlyCharAttrs ) if ( !bOnlyCharAttrs )
{ {
pSet.reset( new SfxItemSet( const_cast<SwAttrPool&>(pTextNode->GetDoc()->GetAttrPool()), pSet.reset( new SfxItemSet( const_cast<SwAttrPool&>(pTextNode->GetDoc()->GetAttrPool()),
...@@ -2102,7 +2102,7 @@ void SwAccessibleParagraph::_getSupplementalAttributesImpl( ...@@ -2102,7 +2102,7 @@ void SwAccessibleParagraph::_getSupplementalAttributesImpl(
tAccParaPropValMap& rSupplementalAttrSeq ) tAccParaPropValMap& rSupplementalAttrSeq )
{ {
const SwTextNode* pTextNode( GetTextNode() ); const SwTextNode* pTextNode( GetTextNode() );
::boost::scoped_ptr<SfxItemSet> pSet; std::unique_ptr<SfxItemSet> pSet;
pSet.reset( new SfxItemSet( const_cast<SwAttrPool&>(pTextNode->GetDoc()->GetAttrPool()), pSet.reset( new SfxItemSet( const_cast<SwAttrPool&>(pTextNode->GetDoc()->GetAttrPool()),
RES_PARATR_ADJUST, RES_PARATR_ADJUST, RES_PARATR_ADJUST, RES_PARATR_ADJUST,
RES_PARATR_TABSTOP, RES_PARATR_TABSTOP, RES_PARATR_TABSTOP, RES_PARATR_TABSTOP,
...@@ -3284,7 +3284,7 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getTextMarkupCount( sal_Int32 nTextMar ...@@ -3284,7 +3284,7 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getTextMarkupCount( sal_Int32 nTextMar
throw (lang::IllegalArgumentException, throw (lang::IllegalArgumentException,
uno::RuntimeException, std::exception) uno::RuntimeException, std::exception)
{ {
boost::scoped_ptr<SwTextMarkupHelper> pTextMarkupHelper; std::unique_ptr<SwTextMarkupHelper> pTextMarkupHelper;
switch ( nTextMarkupType ) switch ( nTextMarkupType )
{ {
case text::TextMarkupType::TRACK_CHANGE_INSERTION: case text::TextMarkupType::TRACK_CHANGE_INSERTION:
...@@ -3509,7 +3509,7 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::addSelection( sal_Int32, sal_Int32 sta ...@@ -3509,7 +3509,7 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::addSelection( sal_Int32, sal_Int32 sta
lang::IllegalArgumentException, lang::IllegalArgumentException,
uno::RuntimeException, std::exception) uno::RuntimeException, std::exception)
{ {
boost::scoped_ptr<SwTextMarkupHelper> pTextMarkupHelper; std::unique_ptr<SwTextMarkupHelper> pTextMarkupHelper;
switch ( nTextMarkupType ) switch ( nTextMarkupType )
{ {
case text::TextMarkupType::TRACK_CHANGE_INSERTION: case text::TextMarkupType::TRACK_CHANGE_INSERTION:
...@@ -3544,7 +3544,7 @@ uno::Sequence< /*accessibility::*/TextSegment > SAL_CALL ...@@ -3544,7 +3544,7 @@ uno::Sequence< /*accessibility::*/TextSegment > SAL_CALL
throw lang::IndexOutOfBoundsException(); throw lang::IndexOutOfBoundsException();
} }
boost::scoped_ptr<SwTextMarkupHelper> pTextMarkupHelper; std::unique_ptr<SwTextMarkupHelper> pTextMarkupHelper;
switch ( nTextMarkupType ) switch ( nTextMarkupType )
{ {
case text::TextMarkupType::TRACK_CHANGE_INSERTION: case text::TextMarkupType::TRACK_CHANGE_INSERTION:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment