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
13673b71
Kaydet (Commit)
13673b71
authored
Kas 26, 2011
tarafından
August Sodora
Kaydeden (comit)
Thorsten Behrens
Kas 28, 2011
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Remove uses of OUString::setCharAt
üst
b1447d64
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
31 deletions
+31
-31
sbxcurr.cxx
basic/source/sbx/sbxcurr.cxx
+5
-5
imagecontainer.cxx
sdext/source/pdfimport/tree/imagecontainer.cxx
+7
-7
ConversionHelper.cxx
writerfilter/source/dmapper/ConversionHelper.cxx
+19
-19
No files found.
basic/source/sbx/sbxcurr.cxx
Dosyayı görüntüle @
13673b71
...
@@ -85,13 +85,13 @@ static rtl::OUString ImpCurrencyToString( const sal_Int64 &rVal )
...
@@ -85,13 +85,13 @@ static rtl::OUString ImpCurrencyToString( const sal_Int64 &rVal )
for
(
sal_Int32
charCpyIndex
=
aAbsStr
.
getLength
()
-
1
;
nInsertIndex
>=
nEndIndex
;
++
nDigitCount
)
for
(
sal_Int32
charCpyIndex
=
aAbsStr
.
getLength
()
-
1
;
nInsertIndex
>=
nEndIndex
;
++
nDigitCount
)
{
{
if
(
nDigitCount
==
4
)
if
(
nDigitCount
==
4
)
aBuf
.
setCharAt
(
nInsertIndex
--
,
cDecimalSep
)
;
aBuf
[
nInsertIndex
--
]
=
cDecimalSep
;
#if MAYBEFUTURE
#if MAYBEFUTURE
if
(
nDigitCount
>
4
&&
!
(
(
nDigitCount
-
4
)
%
3
)
)
if
(
nDigitCount
>
4
&&
!
(
(
nDigitCount
-
4
)
%
3
)
)
aBuf
.
setCharAt
(
nInsertIndex
--
,
cThousandSep
)
;
aBuf
[
nInsertIndex
--
]
=
cThousandSep
;
#endif
#endif
if
(
nDigitCount
<
initialLen
)
if
(
nDigitCount
<
initialLen
)
aBuf
.
setCharAt
(
nInsertIndex
--
,
aAbsStr
[
charCpyIndex
--
]
)
;
aBuf
[
nInsertIndex
--
]
=
aAbsStr
[
charCpyIndex
--
]
;
else
else
// Handle leading 0's to right of decimal point
// Handle leading 0's to right of decimal point
// Note: in VBA the stringification is a little more complex
// Note: in VBA the stringification is a little more complex
...
@@ -104,10 +104,10 @@ static rtl::OUString ImpCurrencyToString( const sal_Int64 &rVal )
...
@@ -104,10 +104,10 @@ static rtl::OUString ImpCurrencyToString( const sal_Int64 &rVal )
// 0 0.0000 0
// 0 0.0000 0
// 0.1 0.1000 0.1
// 0.1 0.1000 0.1
aBuf
.
setCharAt
(
nInsertIndex
--
,
(
sal_Unicode
)
'0'
)
;
aBuf
[
nInsertIndex
--
]
=
(
sal_Unicode
)
'0'
;
}
}
if
(
isNeg
)
if
(
isNeg
)
aBuf
.
setCharAt
(
nInsertIndex
,
(
sal_Unicode
)
'-'
)
;
aBuf
[
nInsertIndex
]
=
(
sal_Unicode
)
'-'
;
aAbsStr
=
aBuf
.
makeStringAndClear
();
aAbsStr
=
aBuf
.
makeStringAndClear
();
return
aAbsStr
;
return
aAbsStr
;
...
...
sdext/source/pdfimport/tree/imagecontainer.cxx
Dosyayı görüntüle @
13673b71
...
@@ -73,16 +73,16 @@ rtl::OUString encodeBase64( const sal_Int8* i_pBuffer, const sal_uInt32 i_nBuffe
...
@@ -73,16 +73,16 @@ rtl::OUString encodeBase64( const sal_Int8* i_pBuffer, const sal_uInt32 i_nBuffe
aBuf
.
appendAscii
(
"===="
);
aBuf
.
appendAscii
(
"===="
);
sal_uInt8
nIndex
(
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0000
)
>>
18
));
sal_uInt8
nIndex
(
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0000
)
>>
18
));
aBuf
.
setCharAt
(
nBufPos
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
]
=
aBase64EncodeTable
[
nIndex
]
;
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F000
)
>>
12
);
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F000
)
>>
12
);
aBuf
.
setCharAt
(
nBufPos
+
1
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
+
1
]
=
aBase64EncodeTable
[
nIndex
]
;
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0
)
>>
6
);
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0
)
>>
6
);
aBuf
.
setCharAt
(
nBufPos
+
2
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
+
2
]
=
aBase64EncodeTable
[
nIndex
]
;
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F
));
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F
));
aBuf
.
setCharAt
(
nBufPos
+
3
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
+
3
]
=
aBase64EncodeTable
[
nIndex
]
;
}
}
if
(
nRemain
>
0
)
if
(
nRemain
>
0
)
{
{
...
@@ -98,15 +98,15 @@ rtl::OUString encodeBase64( const sal_Int8* i_pBuffer, const sal_uInt32 i_nBuffe
...
@@ -98,15 +98,15 @@ rtl::OUString encodeBase64( const sal_Int8* i_pBuffer, const sal_uInt32 i_nBuffe
break
;
break
;
}
}
sal_uInt8
nIndex
(
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0000
)
>>
18
));
sal_uInt8
nIndex
(
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0000
)
>>
18
));
aBuf
.
setCharAt
(
nBufPos
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
]
=
aBase64EncodeTable
[
nIndex
]
;
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F000
)
>>
12
);
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0x3F000
)
>>
12
);
aBuf
.
setCharAt
(
nBufPos
+
1
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
+
1
]
=
aBase64EncodeTable
[
nIndex
]
;
if
(
nRemain
==
2
)
if
(
nRemain
==
2
)
{
{
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0
)
>>
6
);
nIndex
=
static_cast
<
sal_uInt8
>
((
nBinary
&
0xFC0
)
>>
6
);
aBuf
.
setCharAt
(
nBufPos
+
2
,
aBase64EncodeTable
[
nIndex
])
;
aBuf
[
nBufPos
+
2
]
=
aBase64EncodeTable
[
nIndex
]
;
}
}
}
}
...
...
writerfilter/source/dmapper/ConversionHelper.cxx
Dosyayı görüntüle @
13673b71
...
@@ -224,9 +224,9 @@ void lcl_SwapQuotesInField(::rtl::OUString &rFmt)
...
@@ -224,9 +224,9 @@ void lcl_SwapQuotesInField(::rtl::OUString &rFmt)
for
(
sal_Int32
nI
=
0
;
nI
<
nLen
;
++
nI
)
for
(
sal_Int32
nI
=
0
;
nI
<
nLen
;
++
nI
)
{
{
if
((
pFmt
[
nI
]
==
'\"'
)
&&
(
!
nI
||
pFmt
[
nI
-
1
]
!=
'\\'
))
if
((
pFmt
[
nI
]
==
'\"'
)
&&
(
!
nI
||
pFmt
[
nI
-
1
]
!=
'\\'
))
aBuffer
.
setCharAt
(
nI
,
'\''
)
;
aBuffer
[
nI
]
=
'\''
;
else
if
((
pFmt
[
nI
]
==
'\''
)
&&
(
!
nI
||
pFmt
[
nI
-
1
]
!=
'\\'
))
else
if
((
pFmt
[
nI
]
==
'\''
)
&&
(
!
nI
||
pFmt
[
nI
-
1
]
!=
'\\'
))
aBuffer
.
setCharAt
(
nI
,
'\"'
)
;
aBuffer
[
nI
]
=
'\"'
;
}
}
rFmt
=
aBuffer
.
makeStringAndClear
();
rFmt
=
aBuffer
.
makeStringAndClear
();
}
}
...
@@ -235,8 +235,8 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
...
@@ -235,8 +235,8 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
return
(
return
(
(
nPos
==
rFmt
.
getLength
()
-
1
)
||
(
nPos
==
rFmt
.
getLength
()
-
1
)
||
(
(
(
rFmt
.
getStr
()
[
nPos
+
1
]
!=
'M'
)
&&
(
rFmt
[
nPos
+
1
]
!=
'M'
)
&&
(
rFmt
.
getStr
()
[
nPos
+
1
]
!=
'm'
)
(
rFmt
[
nPos
+
1
]
!=
'm'
)
)
)
);
);
}
}
...
@@ -253,34 +253,34 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
...
@@ -253,34 +253,34 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
sal_Int32
nLen
=
sFormat
.
getLength
();
sal_Int32
nLen
=
sFormat
.
getLength
();
sal_Int32
nI
=
0
;
sal_Int32
nI
=
0
;
// const sal_Unicode* pFormat = sFormat.getStr();
// const sal_Unicode* pFormat = sFormat.getStr();
::
rtl
::
OUStringBuffer
aNewFormat
(
sFormat
.
getStr
()
);
::
rtl
::
OUStringBuffer
aNewFormat
(
sFormat
);
while
(
nI
<
nLen
)
while
(
nI
<
nLen
)
{
{
if
(
aNewFormat
.
charAt
(
nI
)
==
'\\'
)
if
(
aNewFormat
[
nI
]
==
'\\'
)
nI
++
;
nI
++
;
else
if
(
aNewFormat
.
charAt
(
nI
)
==
'\"'
)
else
if
(
aNewFormat
[
nI
]
==
'\"'
)
{
{
++
nI
;
++
nI
;
//While not at the end and not at an unescaped end quote
//While not at the end and not at an unescaped end quote
while
((
nI
<
nLen
)
&&
(
!
(
aNewFormat
.
charAt
(
nI
)
==
'\"'
)
&&
(
aNewFormat
.
charAt
(
nI
-
1
)
!=
'\\'
)))
while
((
nI
<
nLen
)
&&
(
!
(
aNewFormat
[
nI
]
==
'\"'
)
&&
(
aNewFormat
[
nI
-
1
]
!=
'\\'
)))
++
nI
;
++
nI
;
}
}
else
//normal unquoted section
else
//normal unquoted section
{
{
sal_Unicode
nChar
=
aNewFormat
.
charAt
(
nI
)
;
sal_Unicode
nChar
=
aNewFormat
[
nI
]
;
if
(
nChar
==
'O'
)
if
(
nChar
==
'O'
)
{
{
aNewFormat
.
setCharAt
(
nI
,
'M'
)
;
aNewFormat
[
nI
]
=
'M'
;
bForceNatNum
=
true
;
bForceNatNum
=
true
;
}
}
else
if
(
nChar
==
'o'
)
else
if
(
nChar
==
'o'
)
{
{
aNewFormat
.
setCharAt
(
nI
,
'm'
)
;
aNewFormat
[
nI
]
=
'm'
;
bForceNatNum
=
true
;
bForceNatNum
=
true
;
}
}
else
if
((
nChar
==
'A'
)
&&
lcl_IsNotAM
(
sFormat
,
nI
))
else
if
((
nChar
==
'A'
)
&&
lcl_IsNotAM
(
sFormat
,
nI
))
{
{
aNewFormat
.
setCharAt
(
nI
,
'D'
)
;
aNewFormat
[
nI
]
=
'D'
;
bForceNatNum
=
true
;
bForceNatNum
=
true
;
}
}
else
if
((
nChar
==
'g'
)
||
(
nChar
==
'G'
))
else
if
((
nChar
==
'g'
)
||
(
nChar
==
'G'
))
...
@@ -289,11 +289,11 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
...
@@ -289,11 +289,11 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
bForceJapanese
=
true
;
bForceJapanese
=
true
;
else
if
(
nChar
==
'E'
)
else
if
(
nChar
==
'E'
)
{
{
if
((
nI
!=
nLen
-
1
)
&&
(
aNewFormat
.
charAt
(
nI
+
1
)
==
'E'
))
if
((
nI
!=
nLen
-
1
)
&&
(
aNewFormat
[
nI
+
1
]
==
'E'
))
{
{
//todo: this cannot be the right way to replace a part of the string!
//todo: this cannot be the right way to replace a part of the string!
aNewFormat
.
setCharAt
(
nI
,
'Y'
)
;
aNewFormat
[
nI
]
=
'Y'
;
aNewFormat
.
setCharAt
(
nI
+
1
,
'Y'
)
;
aNewFormat
[
nI
+
1
]
=
'Y'
;
aNewFormat
.
insert
(
nI
+
2
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"YY"
)));
aNewFormat
.
insert
(
nI
+
2
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"YY"
)));
nLen
+=
2
;
nLen
+=
2
;
nI
+=
3
;
nI
+=
3
;
...
@@ -302,11 +302,11 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
...
@@ -302,11 +302,11 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
}
}
else
if
(
nChar
==
'e'
)
else
if
(
nChar
==
'e'
)
{
{
if
((
nI
!=
nLen
-
1
)
&&
(
aNewFormat
.
charAt
(
nI
+
1
)
==
'e'
))
if
((
nI
!=
nLen
-
1
)
&&
(
aNewFormat
[
nI
+
1
]
==
'e'
))
{
{
//todo: this cannot be the right way to replace a part of the string!
//todo: this cannot be the right way to replace a part of the string!
aNewFormat
.
setCharAt
(
nI
,
'y'
)
;
aNewFormat
[
nI
]
=
'y'
;
aNewFormat
.
setCharAt
(
nI
+
1
,
'y'
)
;
aNewFormat
[
nI
+
1
]
=
'y'
;
aNewFormat
.
insert
(
nI
+
2
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"yy"
)));
aNewFormat
.
insert
(
nI
+
2
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"yy"
)));
nLen
+=
2
;
nLen
+=
2
;
nI
+=
3
;
nI
+=
3
;
...
@@ -317,7 +317,7 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
...
@@ -317,7 +317,7 @@ bool lcl_IsNotAM(::rtl::OUString& rFmt, sal_Int32 nPos)
{
{
// MM We have to escape '/' in case it's used as a char
// MM We have to escape '/' in case it's used as a char
//todo: this cannot be the right way to replace a part of the string!
//todo: this cannot be the right way to replace a part of the string!
aNewFormat
.
setCharAt
(
nI
,
'\\'
)
;
aNewFormat
[
nI
]
=
'\\'
;
aNewFormat
.
insert
(
nI
+
1
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"/"
)));
aNewFormat
.
insert
(
nI
+
1
,
::
rtl
::
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"/"
)));
nI
++
;
nI
++
;
nLen
++
;
nLen
++
;
...
...
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