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
2932e45b
Kaydet (Commit)
2932e45b
authored
Haz 01, 2014
tarafından
Matteo Casalin
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
sal_uInt16 to size_t, constify
Change-Id: Ie864814c71a31aaf2b139641bac9bb720143abfe
üst
672ef15c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
29 deletions
+29
-29
unocoll.cxx
sw/source/core/unocore/unocoll.cxx
+29
-29
No files found.
sw/source/core/unocore/unocoll.cxx
Dosyayı görüntüle @
2932e45b
...
...
@@ -478,7 +478,7 @@ OUString SwXServiceProvider::GetProviderName(sal_uInt16 nObjectType)
{
SolarMutexGuard
aGuard
;
OUString
sRet
;
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
const
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
if
(
nObjectType
<
nEntries
)
sRet
=
OUString
::
createFromAscii
(
aProvNamesId
[
nObjectType
].
pName
);
return
sRet
;
...
...
@@ -486,7 +486,7 @@ OUString SwXServiceProvider::GetProviderName(sal_uInt16 nObjectType)
uno
::
Sequence
<
OUString
>
SwXServiceProvider
::
GetAllServiceNames
()
{
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
const
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
uno
::
Sequence
<
OUString
>
aRet
(
nEntries
);
OUString
*
pArray
=
aRet
.
getArray
();
sal_uInt16
n
=
0
;
...
...
@@ -506,7 +506,7 @@ uno::Sequence<OUString> SwXServiceProvider::GetAllServiceNames()
sal_uInt16
SwXServiceProvider
::
GetProviderType
(
const
OUString
&
rServiceName
)
{
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
const
sal_uInt16
nEntries
=
sizeof
(
aProvNamesId
)
/
sizeof
(
aProvNamesId
[
0
]);
for
(
sal_uInt16
i
=
0
;
i
<
nEntries
;
i
++
)
{
if
(
rServiceName
.
equalsAscii
(
aProvNamesId
[
i
].
pName
))
...
...
@@ -889,7 +889,7 @@ uno::Any SwXTextTables::getByName(const OUString& rItemName)
uno
::
Any
aRet
;
if
(
IsValid
())
{
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
const
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
uno
::
Reference
<
XTextTable
>
xTbl
;
for
(
sal_uInt16
i
=
0
;
i
<
nCount
;
i
++
)
{
...
...
@@ -916,7 +916,7 @@ uno::Sequence< OUString > SwXTextTables::getElementNames(void)
SolarMutexGuard
aGuard
;
if
(
!
IsValid
())
throw
uno
::
RuntimeException
();
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
const
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
uno
::
Sequence
<
OUString
>
aSeq
(
nCount
);
if
(
nCount
)
{
...
...
@@ -938,7 +938,7 @@ sal_Bool SwXTextTables::hasByName(const OUString& rName)
bool
bRet
=
false
;
if
(
IsValid
())
{
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
const
sal_uInt16
nCount
=
GetDoc
()
->
GetTblFrmFmtCount
(
true
);
for
(
sal_uInt16
i
=
0
;
i
<
nCount
;
i
++
)
{
SwFrmFmt
&
rFmt
=
GetDoc
()
->
GetTblFrmFmt
(
i
,
true
);
...
...
@@ -1084,14 +1084,14 @@ SwXFrameEnumeration<T>::SwXFrameEnumeration(const SwDoc* const pDoc)
return
;
// #i104937#
// const SwFrmFmt* const pFmtsEnd = (*pFmts)[pFmts->Count()];
const
s
al_uInt16
nSize
=
pFmts
->
size
();
const
s
ize_t
nSize
=
pFmts
->
size
();
::
std
::
insert_iterator
<
frmcontainer_t
>
pInserter
=
::
std
::
insert_iterator
<
frmcontainer_t
>
(
m_aFrames
,
m_aFrames
.
begin
());
// #i104937#
SwFrmFmt
*
pFmt
(
0
);
std
::
list
<
SwFrmFmt
*>
aTextBoxes
=
SwTextBoxHelper
::
findTextBoxes
(
pDoc
);
for
(
s
al_uInt16
i
=
0
;
i
<
nSize
;
++
i
)
for
(
s
ize_t
i
=
0
;
i
<
nSize
;
++
i
)
// for(SwFrmFmt* pFmt = (*pFmts)[0]; pFmt < pFmtsEnd; ++pFmt)
{
// #i104937#
...
...
@@ -1423,8 +1423,8 @@ sal_Int32 SwXTextSections::getCount(void) throw( uno::RuntimeException, std::exc
if
(
!
IsValid
())
throw
uno
::
RuntimeException
();
const
SwSectionFmts
&
rSectFmts
=
GetDoc
()
->
GetSections
();
s
al_uInt16
nCount
=
rSectFmts
.
size
();
for
(
s
al_uInt16
i
=
nCount
;
i
;
i
--
)
s
ize_t
nCount
=
rSectFmts
.
size
();
for
(
s
ize_t
i
=
nCount
;
i
;
--
i
)
{
if
(
!
rSectFmts
[
i
-
1
]
->
IsInNodesArr
())
nCount
--
;
...
...
@@ -1442,17 +1442,17 @@ uno::Any SwXTextSections::getByIndex(sal_Int32 nIndex)
SwSectionFmts
&
rFmts
=
GetDoc
()
->
GetSections
();
const
SwSectionFmts
&
rSectFmts
=
GetDoc
()
->
GetSections
();
sal_uInt16
nCount
=
rSectFmts
.
size
();
for
(
s
al_uInt16
i
=
0
;
i
<
nCount
;
i
++
)
const
size_t
nCount
=
rSectFmts
.
size
();
for
(
s
ize_t
i
=
0
;
i
<
nCount
;
++
i
)
{
if
(
!
rSectFmts
[
i
]
->
IsInNodesArr
())
nIndex
++
;
else
if
(
nIndex
==
i
)
else
if
(
static_cast
<
size_t
>
(
nIndex
)
==
i
)
break
;
if
(
nIndex
==
i
)
if
(
static_cast
<
size_t
>
(
nIndex
)
==
i
)
break
;
}
if
(
nIndex
>=
0
&&
nIndex
<
(
sal_Int32
)
rFmts
.
size
())
if
(
nIndex
>=
0
&&
static_cast
<
size_t
>
(
nIndex
)
<
rFmts
.
size
())
{
SwSectionFmt
*
pFmt
=
rFmts
[(
sal_uInt16
)
nIndex
];
xRet
=
GetObject
(
*
pFmt
);
...
...
@@ -1475,7 +1475,7 @@ uno::Any SwXTextSections::getByName(const OUString& Name)
OUString
aName
(
Name
);
SwSectionFmts
&
rFmts
=
GetDoc
()
->
GetSections
();
uno
::
Reference
<
XTextSection
>
xSect
;
for
(
s
al_uInt16
i
=
0
;
i
<
rFmts
.
size
();
i
++
)
for
(
s
ize_t
i
=
0
;
i
<
rFmts
.
size
();
++
i
)
{
SwSectionFmt
*
pFmt
=
rFmts
[
i
];
if
(
pFmt
->
IsInNodesArr
()
...
...
@@ -1500,9 +1500,9 @@ uno::Sequence< OUString > SwXTextSections::getElementNames(void)
SolarMutexGuard
aGuard
;
if
(
!
IsValid
())
throw
uno
::
RuntimeException
();
s
al_uInt16
nCount
=
GetDoc
()
->
GetSections
().
size
();
s
ize_t
nCount
=
GetDoc
()
->
GetSections
().
size
();
SwSectionFmts
&
rSectFmts
=
GetDoc
()
->
GetSections
();
for
(
s
al_uInt16
i
=
nCount
;
i
;
i
--
)
for
(
s
ize_t
i
=
nCount
;
i
;
--
i
)
{
if
(
!
rSectFmts
[
i
-
1
]
->
IsInNodesArr
())
nCount
--
;
...
...
@@ -1513,8 +1513,8 @@ uno::Sequence< OUString > SwXTextSections::getElementNames(void)
{
SwSectionFmts
&
rFmts
=
GetDoc
()
->
GetSections
();
OUString
*
pArray
=
aSeq
.
getArray
();
s
al_uInt16
nIndex
=
0
;
for
(
s
al_uInt16
i
=
0
;
i
<
nCount
;
i
++
,
nIndex
++
)
s
ize_t
nIndex
=
0
;
for
(
s
ize_t
i
=
0
;
i
<
nCount
;
++
i
,
++
nIndex
)
{
const
SwSectionFmt
*
pFmt
=
rFmts
[
nIndex
];
while
(
!
pFmt
->
IsInNodesArr
())
...
...
@@ -1535,7 +1535,7 @@ sal_Bool SwXTextSections::hasByName(const OUString& rName)
if
(
IsValid
())
{
SwSectionFmts
&
rFmts
=
GetDoc
()
->
GetSections
();
for
(
s
al_uInt16
i
=
0
;
i
<
rFmts
.
size
();
i
++
)
for
(
s
ize_t
i
=
0
;
i
<
rFmts
.
size
();
++
i
)
{
const
SwSectionFmt
*
pFmt
=
rFmts
[
i
];
if
(
rName
==
pFmt
->
GetSection
()
->
GetSectionName
())
...
...
@@ -1562,7 +1562,7 @@ uno::Type SAL_CALL SwXTextSections::getElementType() throw(uno::RuntimeException
sal_Bool
SwXTextSections
::
hasElements
(
void
)
throw
(
uno
::
RuntimeException
,
std
::
exception
)
{
SolarMutexGuard
aGuard
;
s
al_uInt16
nCount
=
0
;
s
ize_t
nCount
=
0
;
if
(
IsValid
())
{
SwSectionFmts
&
rFmts
=
GetDoc
()
->
GetSections
();
...
...
@@ -1760,9 +1760,9 @@ uno::Any SwXNumberingRulesCollection::getByIndex(sal_Int32 nIndex)
if
(
IsValid
())
{
uno
::
Reference
<
XIndexReplace
>
xRef
;
if
(
nIndex
<
(
sal_Int32
)
GetDoc
()
->
GetNumRuleTbl
().
size
()
)
if
(
static_cast
<
size_t
>
(
nIndex
)
<
GetDoc
()
->
GetNumRuleTbl
().
size
()
)
{
xRef
=
new
SwXNumberingRules
(
*
GetDoc
()
->
GetNumRuleTbl
()[
static_cast
<
sal_uInt16
>
(
nIndex
)
],
GetDoc
());
xRef
=
new
SwXNumberingRules
(
*
GetDoc
()
->
GetNumRuleTbl
()[
nIndex
],
GetDoc
());
aRet
.
setValue
(
&
xRef
,
cppu
::
UnoType
<
XIndexReplace
>::
get
());
}
...
...
@@ -1821,9 +1821,9 @@ sal_Int32 SwXFootnotes::getCount(void) throw( uno::RuntimeException, std::except
if
(
!
IsValid
())
throw
uno
::
RuntimeException
();
sal_Int32
nCount
=
0
;
sal_uInt16
n
,
nFtnCnt
=
GetDoc
()
->
GetFtnIdxs
().
size
();
const
size_t
nFtnCnt
=
GetDoc
()
->
GetFtnIdxs
().
size
();
SwTxtFtn
*
pTxtFtn
;
for
(
n
=
0
;
n
<
nFtnCnt
;
++
n
)
for
(
size_t
n
=
0
;
n
<
nFtnCnt
;
++
n
)
{
pTxtFtn
=
GetDoc
()
->
GetFtnIdxs
()[
n
];
const
SwFmtFtn
&
rFtn
=
pTxtFtn
->
GetFtn
();
...
...
@@ -1842,10 +1842,10 @@ uno::Any SwXFootnotes::getByIndex(sal_Int32 nIndex)
sal_Int32
nCount
=
0
;
if
(
IsValid
())
{
sal_uInt16
n
,
nFtnCnt
=
GetDoc
()
->
GetFtnIdxs
().
size
();
const
size_t
nFtnCnt
=
GetDoc
()
->
GetFtnIdxs
().
size
();
SwTxtFtn
*
pTxtFtn
;
uno
::
Reference
<
XFootnote
>
xRef
;
for
(
n
=
0
;
n
<
nFtnCnt
;
++
n
)
for
(
size_t
n
=
0
;
n
<
nFtnCnt
;
++
n
)
{
pTxtFtn
=
GetDoc
()
->
GetFtnIdxs
()[
n
];
const
SwFmtFtn
&
rFtn
=
pTxtFtn
->
GetFtn
();
...
...
@@ -1971,7 +1971,7 @@ uno::Sequence< OUString > SwXReferenceMarks::getElementNames(void) throw( uno::R
if
(
IsValid
())
{
std
::
vector
<
OUString
>
aStrings
;
sal_uInt16
nCount
=
GetDoc
()
->
GetRefMarks
(
&
aStrings
);
const
sal_uInt16
nCount
=
GetDoc
()
->
GetRefMarks
(
&
aStrings
);
aRet
.
realloc
(
nCount
);
OUString
*
pNames
=
aRet
.
getArray
();
for
(
sal_uInt16
i
=
0
;
i
<
nCount
;
i
++
)
...
...
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