Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
b8ea41a9
Kaydet (Commit)
b8ea41a9
authored
Eyl 30, 2014
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
cui: std::auto_ptr -> std::unique_ptr
Change-Id: Iea8b3def77842541129c16346270aa262654fea4
üst
05dfa2f6
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
27 deletions
+13
-27
scriptdlg.cxx
cui/source/dialogs/scriptdlg.cxx
+9
-23
dlgfact.cxx
cui/source/factory/dlgfact.cxx
+1
-1
passwdomdlg.hxx
cui/source/inc/passwdomdlg.hxx
+1
-1
scriptdlg.hxx
cui/source/inc/scriptdlg.hxx
+2
-2
No files found.
cui/source/dialogs/scriptdlg.cxx
Dosyayı görüntüle @
b8ea41a9
...
@@ -18,6 +18,7 @@
...
@@ -18,6 +18,7 @@
*/
*/
#include <memory>
#include <memory>
#include <utility>
#include <sfx2/objsh.hxx>
#include <sfx2/objsh.hxx>
#include <vcl/svapp.hxx>
#include <vcl/svapp.hxx>
...
@@ -238,10 +239,8 @@ void SFTreeListBox::Init( const OUString& language )
...
@@ -238,10 +239,8 @@ void SFTreeListBox::Init( const OUString& language )
Reference
<
browse
::
XBrowseNode
>
langEntries
=
Reference
<
browse
::
XBrowseNode
>
langEntries
=
getLangNodeFromRootNode
(
children
[
n
],
lang
);
getLangNodeFromRootNode
(
children
[
n
],
lang
);
SAL_WNODEPRECATED_DECLARATIONS_PUSH
insertEntry
(
uiName
,
app
?
RID_CUIIMG_HARDDISK
:
RID_CUIIMG_DOC
,
insertEntry
(
uiName
,
app
?
RID_CUIIMG_HARDDISK
:
RID_CUIIMG_DOC
,
0
,
true
,
std
::
auto_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SFROOT
,
langEntries
,
xDocumentModel
)),
factoryURL
);
0
,
true
,
std
::
unique_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SFROOT
,
langEntries
,
xDocumentModel
)),
factoryURL
);
SAL_WNODEPRECATED_DECLARATIONS_POP
}
}
SetUpdateMode
(
true
);
SetUpdateMode
(
true
);
...
@@ -322,17 +321,13 @@ void SFTreeListBox:: RequestSubEntries( SvTreeListEntry* pRootEntry, Reference<
...
@@ -322,17 +321,13 @@ void SFTreeListBox:: RequestSubEntries( SvTreeListEntry* pRootEntry, Reference<
OUString
name
(
children
[
n
]
->
getName
()
);
OUString
name
(
children
[
n
]
->
getName
()
);
if
(
children
[
n
]
->
getType
()
!=
browse
::
BrowseNodeTypes
::
SCRIPT
)
if
(
children
[
n
]
->
getType
()
!=
browse
::
BrowseNodeTypes
::
SCRIPT
)
{
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
insertEntry
(
name
,
RID_CUIIMG_LIB
,
pRootEntry
,
true
,
std
::
unique_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SCRIPTCONTAINER
,
children
[
n
],
model
)));
insertEntry
(
name
,
RID_CUIIMG_LIB
,
pRootEntry
,
true
,
std
::
auto_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SCRIPTCONTAINER
,
children
[
n
],
model
)));
SAL_WNODEPRECATED_DECLARATIONS_POP
}
}
else
else
{
{
if
(
children
[
n
]
->
getType
()
==
browse
::
BrowseNodeTypes
::
SCRIPT
)
if
(
children
[
n
]
->
getType
()
==
browse
::
BrowseNodeTypes
::
SCRIPT
)
{
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
insertEntry
(
name
,
RID_CUIIMG_MACRO
,
pRootEntry
,
false
,
std
::
unique_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_METHOD
,
children
[
n
],
model
)));
insertEntry
(
name
,
RID_CUIIMG_MACRO
,
pRootEntry
,
false
,
std
::
auto_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_METHOD
,
children
[
n
],
model
)));
SAL_WNODEPRECATED_DECLARATIONS_POP
}
}
}
}
...
@@ -348,10 +343,9 @@ void SFTreeListBox::ExpandAllTrees()
...
@@ -348,10 +343,9 @@ void SFTreeListBox::ExpandAllTrees()
{
{
}
}
SAL_WNODEPRECATED_DECLARATIONS_PUSH
SvTreeListEntry
*
SFTreeListBox
::
insertEntry
(
SvTreeListEntry
*
SFTreeListBox
::
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
bool
bChildrenOnDemand
,
std
::
auto_ptr
<
SFEntry
>
aUserData
,
const
OUString
&
factoryURL
)
bool
bChildrenOnDemand
,
std
::
unique_ptr
<
SFEntry
>
&&
aUserData
,
const
OUString
&
factoryURL
)
{
{
SvTreeListEntry
*
p
;
SvTreeListEntry
*
p
;
if
(
nBitmap
==
RID_CUIIMG_DOC
&&
!
factoryURL
.
isEmpty
()
)
if
(
nBitmap
==
RID_CUIIMG_DOC
&&
!
factoryURL
.
isEmpty
()
)
...
@@ -363,16 +357,14 @@ SvTreeListEntry * SFTreeListBox::insertEntry(
...
@@ -363,16 +357,14 @@ SvTreeListEntry * SFTreeListBox::insertEntry(
}
}
else
else
{
{
p
=
insertEntry
(
rText
,
nBitmap
,
pParent
,
bChildrenOnDemand
,
aUserData
);
p
=
insertEntry
(
rText
,
nBitmap
,
pParent
,
bChildrenOnDemand
,
std
::
move
(
aUserData
)
);
}
}
return
p
;
return
p
;
}
}
SAL_WNODEPRECATED_DECLARATIONS_POP
SAL_WNODEPRECATED_DECLARATIONS_PUSH
SvTreeListEntry
*
SFTreeListBox
::
insertEntry
(
SvTreeListEntry
*
SFTreeListBox
::
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
bool
bChildrenOnDemand
,
std
::
auto_ptr
<
SFEntry
>
aUserData
)
bool
bChildrenOnDemand
,
std
::
unique_ptr
<
SFEntry
>
&&
aUserData
)
{
{
Image
aImage
;
Image
aImage
;
if
(
nBitmap
==
RID_CUIIMG_HARDDISK
)
if
(
nBitmap
==
RID_CUIIMG_HARDDISK
)
...
@@ -396,7 +388,6 @@ SvTreeListEntry * SFTreeListBox::insertEntry(
...
@@ -396,7 +388,6 @@ SvTreeListEntry * SFTreeListBox::insertEntry(
aUserData
.
release
());
// XXX possible leak
aUserData
.
release
());
// XXX possible leak
return
p
;
return
p
;
}
}
SAL_WNODEPRECATED_DECLARATIONS_POP
void
SFTreeListBox
::
RequestingChildren
(
SvTreeListEntry
*
pEntry
)
void
SFTreeListBox
::
RequestingChildren
(
SvTreeListEntry
*
pEntry
)
{
{
...
@@ -962,18 +953,13 @@ void SvxScriptOrgDialog::createEntry( SvTreeListEntry* pEntry )
...
@@ -962,18 +953,13 @@ void SvxScriptOrgDialog::createEntry( SvTreeListEntry* pEntry )
// not in alphabetical order
// not in alphabetical order
if
(
aChildNode
->
getType
()
==
browse
::
BrowseNodeTypes
::
SCRIPT
)
if
(
aChildNode
->
getType
()
==
browse
::
BrowseNodeTypes
::
SCRIPT
)
{
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
pNewEntry
=
m_pScriptsBox
->
insertEntry
(
aChildName
,
pNewEntry
=
m_pScriptsBox
->
insertEntry
(
aChildName
,
RID_CUIIMG_MACRO
,
pEntry
,
false
,
std
::
auto_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_METHOD
,
aChildNode
,
xDocumentModel
)
)
);
RID_CUIIMG_MACRO
,
pEntry
,
false
,
std
::
unique_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_METHOD
,
aChildNode
,
xDocumentModel
)
)
);
SAL_WNODEPRECATED_DECLARATIONS_POP
}
}
else
else
{
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
pNewEntry
=
m_pScriptsBox
->
insertEntry
(
aChildName
,
pNewEntry
=
m_pScriptsBox
->
insertEntry
(
aChildName
,
RID_CUIIMG_LIB
,
pEntry
,
false
,
std
::
auto_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SCRIPTCONTAINER
,
aChildNode
,
xDocumentModel
)
)
);
RID_CUIIMG_LIB
,
pEntry
,
false
,
std
::
unique_ptr
<
SFEntry
>
(
new
SFEntry
(
OBJTYPE_SCRIPTCONTAINER
,
aChildNode
,
xDocumentModel
)
)
);
SAL_WNODEPRECATED_DECLARATIONS_POP
// If the Parent is not loaded then set to
// If the Parent is not loaded then set to
// loaded, this will prevent RequestingChildren ( called
// loaded, this will prevent RequestingChildren ( called
...
...
cui/source/factory/dlgfact.cxx
Dosyayı görüntüle @
b8ea41a9
...
@@ -1615,7 +1615,7 @@ public:
...
@@ -1615,7 +1615,7 @@ public:
private
:
private
:
SfxItemSet
m_aItems
;
SfxItemSet
m_aItems
;
::
std
::
auto_ptr
<
SvxMacroAssignDlg
>
m_pDialog
;
::
std
::
unique_ptr
<
SvxMacroAssignDlg
>
m_pDialog
;
};
};
short
SvxMacroAssignDialog
::
Execute
()
short
SvxMacroAssignDialog
::
Execute
()
...
...
cui/source/inc/passwdomdlg.hxx
Dosyayı görüntüle @
b8ea41a9
...
@@ -30,7 +30,7 @@ struct PasswordToOpenModifyDialog_Impl;
...
@@ -30,7 +30,7 @@ struct PasswordToOpenModifyDialog_Impl;
class
PasswordToOpenModifyDialog
:
public
SfxModalDialog
class
PasswordToOpenModifyDialog
:
public
SfxModalDialog
{
{
std
::
auto
_ptr
<
PasswordToOpenModifyDialog_Impl
>
m_pImpl
;
std
::
unique
_ptr
<
PasswordToOpenModifyDialog_Impl
>
m_pImpl
;
// disallow use of copy c-tor and assignment operator
// disallow use of copy c-tor and assignment operator
PasswordToOpenModifyDialog
(
const
PasswordToOpenModifyDialog
&
);
PasswordToOpenModifyDialog
(
const
PasswordToOpenModifyDialog
&
);
...
...
cui/source/inc/scriptdlg.hxx
Dosyayı görüntüle @
b8ea41a9
...
@@ -85,12 +85,12 @@ public:
...
@@ -85,12 +85,12 @@ public:
SvTreeListEntry
*
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
SvTreeListEntry
*
pParent
,
bool
bChildrenOnDemand
,
bool
bChildrenOnDemand
,
std
::
auto_ptr
<
SFEntry
>
aUserData
,
std
::
unique_ptr
<
SFEntry
>
&&
aUserData
,
const
OUString
&
factoryURL
);
const
OUString
&
factoryURL
);
SvTreeListEntry
*
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
insertEntry
(
OUString
const
&
rText
,
sal_uInt16
nBitmap
,
SvTreeListEntry
*
pParent
,
SvTreeListEntry
*
pParent
,
bool
bChildrenOnDemand
,
bool
bChildrenOnDemand
,
std
::
auto_ptr
<
SFEntry
>
aUserData
);
std
::
unique_ptr
<
SFEntry
>
&&
aUserData
);
void
deleteTree
(
SvTreeListEntry
*
pEntry
);
void
deleteTree
(
SvTreeListEntry
*
pEntry
);
void
deleteAllTree
(
);
void
deleteAllTree
(
);
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment