summaryrefslogtreecommitdiff
path: root/dbaccess/source/ui
diff options
context:
space:
mode:
authorTakeshi Abe <tabe@fixedpoint.jp>2014-02-20 11:02:54 +0900
committerTakeshi Abe <tabe@fixedpoint.jp>2014-02-20 11:25:30 +0900
commitc92753e39575b4b823ce9df8f10fc8ecb8a9915e (patch)
tree788b8420e98a56fca51e15f7d0473d75888c8d69 /dbaccess/source/ui
parent22b709e84a7b6d38cab2dd37f2f2b28e0fc9d062 (diff)
Replace deprecated std::auto_ptr with boost::scoped_ptr
Change-Id: Iafdebacd43ed24a30fb8e2d041fe975a1adbcfa0
Diffstat (limited to 'dbaccess/source/ui')
-rw-r--r--dbaccess/source/ui/app/AppIconControl.cxx4
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx10
-rw-r--r--dbaccess/source/ui/misc/propertystorage.cxx6
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx4
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx14
5 files changed, 15 insertions, 23 deletions
diff --git a/dbaccess/source/ui/app/AppIconControl.cxx b/dbaccess/source/ui/app/AppIconControl.cxx
index 752ac35d7179..ad6f505bd694 100644
--- a/dbaccess/source/ui/app/AppIconControl.cxx
+++ b/dbaccess/source/ui/app/AppIconControl.cxx
@@ -25,7 +25,7 @@
#include <vcl/image.hxx>
#include "callbacks.hxx"
#include "AppElementType.hxx"
-#include <memory>
+#include <boost/scoped_ptr.hpp>
using namespace ::dbaui;
// class OApplicationIconControl
@@ -68,7 +68,7 @@ OApplicationIconControl::~OApplicationIconControl()
SvxIconChoiceCtrlEntry* pEntry = GetEntry( i );
if ( pEntry )
{
- ::std::auto_ptr<ElementType> aType(static_cast<ElementType*>(pEntry->GetUserData()));
+ boost::scoped_ptr<ElementType> aType(static_cast<ElementType*>(pEntry->GetUserData()));
pEntry->SetUserData(NULL);
}
}
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index 2f33b1689328..a7c63001815d 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -50,7 +50,7 @@
#include <comphelper/numbers.hxx>
#include <comphelper/string.hxx>
#include "UITools.hxx"
-#include <memory>
+#include <boost/scoped_ptr.hpp>
#include "dbu_control.hrc"
#include "dbu_tbl.hrc"
#include <osl/diagnose.h>
@@ -212,15 +212,11 @@ OFieldDescControl::~OFieldDescControl()
{
{
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<Window> aTemp(m_pVertScroll);
- SAL_WNODEPRECATED_DECLARATIONS_POP
+ boost::scoped_ptr<Window> aTemp(m_pVertScroll);
m_pVertScroll = NULL;
}
{
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<Window> aTemp(m_pHorzScroll);
- SAL_WNODEPRECATED_DECLARATIONS_POP
+ boost::scoped_ptr<Window> aTemp(m_pHorzScroll);
m_pHorzScroll = NULL;
}
if ( m_bAdded )
diff --git a/dbaccess/source/ui/misc/propertystorage.cxx b/dbaccess/source/ui/misc/propertystorage.cxx
index fd56ba1354c6..f13c3a1862e8 100644
--- a/dbaccess/source/ui/misc/propertystorage.cxx
+++ b/dbaccess/source/ui/misc/propertystorage.cxx
@@ -23,7 +23,8 @@
#include <svl/stritem.hxx>
#include <svl/eitem.hxx>
-#include <memory>
+#include <cassert>
+#include <boost/scoped_ptr.hpp>
namespace dbaui
{
@@ -61,7 +62,8 @@ namespace dbaui
// TODO: one could throw an IllegalArgumentException here - finally, this method
// is (to be) used from within an XPropertySet::setPropertyValue implementation,
// where this would be the appropriate reaction on wrong value types
- ::std::auto_ptr< ITEMTYPE > pClone( dynamic_cast< ITEMTYPE* >( pTypedItem->Clone() ) );
+ boost::scoped_ptr< ITEMTYPE > pClone( dynamic_cast< ITEMTYPE* >( pTypedItem->Clone() ) );
+ assert(pClone.get());
pClone->SetValue( aValue );
_rSet.Put( *pClone );
return true;
diff --git a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
index 912ee70128db..2677a5b395a7 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
@@ -21,7 +21,7 @@
#include <tools/debug.hxx>
#include <svtools/svmedit.hxx>
#include "dbaccess_helpid.hrc"
-#include <memory>
+#include <boost/scoped_ptr.hpp>
using namespace dbaui;
#define STANDARD_MARGIN 6
// class OTableDesignHelpBar
@@ -37,7 +37,7 @@ OTableDesignHelpBar::OTableDesignHelpBar( Window* pParent ) :
OTableDesignHelpBar::~OTableDesignHelpBar()
{
- ::std::auto_ptr<Window> aTemp(m_pTextWin);
+ boost::scoped_ptr<Window> aTemp(m_pTextWin);
m_pTextWin = NULL;
}
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
index da5c37e4e67c..04ea9cb6f31b 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
@@ -25,7 +25,7 @@
#include <vcl/fixed.hxx>
#include "dbaccess_helpid.hrc"
#include "moduledbu.hxx"
-#include <memory>
+#include <boost/scoped_ptr.hpp>
#define STANDARD_MARGIN 6
#define DETAILS_HEADER_HEIGHT 25
@@ -70,21 +70,15 @@ OTableFieldDescWin::~OTableFieldDescWin()
m_pHeader->Hide();
{
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<Window> aTemp(m_pGenPage);
- SAL_WNODEPRECATED_DECLARATIONS_POP
+ boost::scoped_ptr<Window> aTemp(m_pGenPage);
m_pGenPage = NULL;
}
{
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<Window> aTemp(m_pHeader);
- SAL_WNODEPRECATED_DECLARATIONS_POP
+ boost::scoped_ptr<Window> aTemp(m_pHeader);
m_pHeader = NULL;
}
{
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<Window> aTemp(m_pHelpBar);
- SAL_WNODEPRECATED_DECLARATIONS_POP
+ boost::scoped_ptr<Window> aTemp(m_pHelpBar);
m_pHelpBar = NULL;
}
}