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
38f46105
Kaydet (Commit)
38f46105
authored
Kas 10, 2011
tarafından
Eike Rathke
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
sal_Bool to bool
üst
d0aedf87
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
54 additions
and
54 deletions
+54
-54
attrib.hxx
sc/inc/attrib.hxx
+24
-24
attrib.cxx
sc/source/core/data/attrib.cxx
+30
-30
No files found.
sc/inc/attrib.hxx
Dosyayı görüntüle @
38f46105
...
...
@@ -55,7 +55,7 @@
class
EditTextObject
;
namespace
editeng
{
class
SvxBorderLine
;
}
sal_B
ool
SC_DLLPUBLIC
ScHasPriority
(
const
::
editeng
::
SvxBorderLine
*
pThis
,
const
::
editeng
::
SvxBorderLine
*
pOther
);
b
ool
SC_DLLPUBLIC
ScHasPriority
(
const
::
editeng
::
SvxBorderLine
*
pThis
,
const
::
editeng
::
SvxBorderLine
*
pOther
);
//------------------------------------------------------------------------
...
...
@@ -79,7 +79,7 @@ public:
SCsCOL
GetColMerge
()
const
{
return
nColMerge
;
}
SCsROW
GetRowMerge
()
const
{
return
nRowMerge
;
}
sal_B
ool
IsMerged
()
const
{
return
nColMerge
>
1
||
nRowMerge
>
1
;
}
b
ool
IsMerged
()
const
{
return
nColMerge
>
1
||
nRowMerge
>
1
;
}
inline
ScMergeAttr
&
operator
=
(
const
ScMergeAttr
&
rMerge
)
{
...
...
@@ -98,31 +98,31 @@ public:
ScMergeFlagAttr
(
sal_Int16
nFlags
);
~
ScMergeFlagAttr
();
sal_B
ool
IsHorOverlapped
()
const
{
return
(
GetValue
()
&
SC_MF_HOR
)
!=
0
;
}
sal_B
ool
IsVerOverlapped
()
const
{
return
(
GetValue
()
&
SC_MF_VER
)
!=
0
;
}
sal_B
ool
IsOverlapped
()
const
{
return
(
GetValue
()
&
(
SC_MF_HOR
|
SC_MF_VER
)
)
!=
0
;
}
b
ool
IsHorOverlapped
()
const
{
return
(
GetValue
()
&
SC_MF_HOR
)
!=
0
;
}
b
ool
IsVerOverlapped
()
const
{
return
(
GetValue
()
&
SC_MF_VER
)
!=
0
;
}
b
ool
IsOverlapped
()
const
{
return
(
GetValue
()
&
(
SC_MF_HOR
|
SC_MF_VER
)
)
!=
0
;
}
sal_B
ool
HasAutoFilter
()
const
{
return
(
GetValue
()
&
SC_MF_AUTO
)
!=
0
;
}
sal_B
ool
HasButton
()
const
{
return
(
GetValue
()
&
SC_MF_BUTTON
)
!=
0
;
}
b
ool
HasAutoFilter
()
const
{
return
(
GetValue
()
&
SC_MF_AUTO
)
!=
0
;
}
b
ool
HasButton
()
const
{
return
(
GetValue
()
&
SC_MF_BUTTON
)
!=
0
;
}
bool
HasDPTable
()
const
{
return
(
GetValue
()
&
SC_MF_DP_TABLE
)
!=
0
;
}
sal_B
ool
IsScenario
()
const
{
return
(
GetValue
()
&
SC_MF_SCENARIO
)
!=
0
;
}
b
ool
IsScenario
()
const
{
return
(
GetValue
()
&
SC_MF_SCENARIO
)
!=
0
;
}
};
//------------------------------------------------------------------------
class
SC_DLLPUBLIC
ScProtectionAttr
:
public
SfxPoolItem
{
sal_B
ool
bProtection
;
// protect cell
sal_B
ool
bHideFormula
;
// hide formula
sal_B
ool
bHideCell
;
// hide cell
sal_B
ool
bHidePrint
;
// don't print cell
b
ool
bProtection
;
// protect cell
b
ool
bHideFormula
;
// hide formula
b
ool
bHideCell
;
// hide cell
b
ool
bHidePrint
;
// don't print cell
public
:
TYPEINFO
();
ScProtectionAttr
();
ScProtectionAttr
(
sal_B
ool
bProtect
,
sal_B
ool
bHFormula
=
false
,
sal_B
ool
bHCell
=
false
,
sal_B
ool
bHPrint
=
false
);
ScProtectionAttr
(
b
ool
bProtect
,
b
ool
bHFormula
=
false
,
b
ool
bHCell
=
false
,
b
ool
bHPrint
=
false
);
ScProtectionAttr
(
const
ScProtectionAttr
&
);
~
ScProtectionAttr
();
...
...
@@ -141,14 +141,14 @@ public:
virtual
bool
QueryValue
(
com
::
sun
::
star
::
uno
::
Any
&
rVal
,
sal_uInt8
nMemberId
=
0
)
const
;
virtual
bool
PutValue
(
const
com
::
sun
::
star
::
uno
::
Any
&
rVal
,
sal_uInt8
nMemberId
=
0
);
sal_B
ool
GetProtection
()
const
{
return
bProtection
;
}
sal_Bool
SetProtection
(
sal_B
ool
bProtect
);
sal_B
ool
GetHideFormula
()
const
{
return
bHideFormula
;
}
sal_Bool
SetHideFormula
(
sal_B
ool
bHFormula
);
sal_B
ool
GetHideCell
()
const
{
return
bHideCell
;
}
sal_Bool
SetHideCell
(
sal_B
ool
bHCell
);
sal_B
ool
GetHidePrint
()
const
{
return
bHidePrint
;
}
sal_Bool
SetHidePrint
(
sal_B
ool
bHPrint
);
b
ool
GetProtection
()
const
{
return
bProtection
;
}
bool
SetProtection
(
b
ool
bProtect
);
b
ool
GetHideFormula
()
const
{
return
bHideFormula
;
}
bool
SetHideFormula
(
b
ool
bHFormula
);
b
ool
GetHideCell
()
const
{
return
bHideCell
;
}
bool
SetHideCell
(
b
ool
bHCell
);
b
ool
GetHidePrint
()
const
{
return
bHidePrint
;
}
bool
SetHidePrint
(
b
ool
bHPrint
);
inline
ScProtectionAttr
&
operator
=
(
const
ScProtectionAttr
&
rProtection
)
{
bProtection
=
rProtection
.
bProtection
;
...
...
sc/source/core/data/attrib.cxx
Dosyayı görüntüle @
38f46105
...
...
@@ -75,30 +75,30 @@ TYPEINIT1(ScPageScaleToItem, SfxPoolItem);
// allgemeine Hilfsfunktionen
//
sal_B
ool
ScHasPriority
(
const
::
editeng
::
SvxBorderLine
*
pThis
,
const
::
editeng
::
SvxBorderLine
*
pOther
)
b
ool
ScHasPriority
(
const
::
editeng
::
SvxBorderLine
*
pThis
,
const
::
editeng
::
SvxBorderLine
*
pOther
)
{
if
(
!
pThis
)
return
false
;
if
(
!
pOther
)
return
sal_T
rue
;
return
t
rue
;
sal_uInt16
nThisSize
=
pThis
->
GetOutWidth
()
+
pThis
->
GetDistance
()
+
pThis
->
GetInWidth
();
sal_uInt16
nOtherSize
=
pOther
->
GetOutWidth
()
+
pOther
->
GetDistance
()
+
pOther
->
GetInWidth
();
if
(
nThisSize
>
nOtherSize
)
return
sal_T
rue
;
return
t
rue
;
else
if
(
nThisSize
<
nOtherSize
)
return
false
;
else
{
if
(
pOther
->
GetInWidth
()
&&
!
pThis
->
GetInWidth
()
)
return
sal_T
rue
;
return
t
rue
;
else
if
(
pThis
->
GetInWidth
()
&&
!
pOther
->
GetInWidth
()
)
return
false
;
else
{
return
sal_T
rue
;
//! ???
return
t
rue
;
//! ???
}
}
}
...
...
@@ -205,7 +205,7 @@ ScMergeFlagAttr::~ScMergeFlagAttr()
ScProtectionAttr
::
ScProtectionAttr
()
:
SfxPoolItem
(
ATTR_PROTECTION
),
bProtection
(
sal_T
rue
),
bProtection
(
t
rue
),
bHideFormula
(
false
),
bHideCell
(
false
),
bHidePrint
(
false
)
...
...
@@ -214,8 +214,8 @@ ScProtectionAttr::ScProtectionAttr():
//------------------------------------------------------------------------
ScProtectionAttr
::
ScProtectionAttr
(
sal_Bool
bProtect
,
sal_B
ool
bHFormula
,
sal_Bool
bHCell
,
sal_B
ool
bHPrint
)
:
ScProtectionAttr
::
ScProtectionAttr
(
bool
bProtect
,
b
ool
bHFormula
,
bool
bHCell
,
b
ool
bHPrint
)
:
SfxPoolItem
(
ATTR_PROTECTION
),
bProtection
(
bProtect
),
bHideFormula
(
bHFormula
),
...
...
@@ -275,7 +275,7 @@ bool ScProtectionAttr::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
bool
ScProtectionAttr
::
PutValue
(
const
uno
::
Any
&
rVal
,
sal_uInt8
nMemberId
)
{
bool
bRet
=
false
;
sal_Bool
bVal
=
sal_
Bool
()
;
sal_Bool
bVal
=
sal_
False
;
nMemberId
&=
~
CONVERT_TWIPS
;
switch
(
nMemberId
)
{
...
...
@@ -412,34 +412,34 @@ SfxPoolItem* ScProtectionAttr::Create( SvStream& rStream, sal_uInt16 /* n */ ) c
//------------------------------------------------------------------------
sal_Bool
ScProtectionAttr
::
SetProtection
(
sal_B
ool
bProtect
)
bool
ScProtectionAttr
::
SetProtection
(
b
ool
bProtect
)
{
bProtection
=
bProtect
;
return
sal_T
rue
;
return
t
rue
;
}
//------------------------------------------------------------------------
sal_Bool
ScProtectionAttr
::
SetHideFormula
(
sal_B
ool
bHFormula
)
bool
ScProtectionAttr
::
SetHideFormula
(
b
ool
bHFormula
)
{
bHideFormula
=
bHFormula
;
return
sal_T
rue
;
return
t
rue
;
}
//------------------------------------------------------------------------
sal_Bool
ScProtectionAttr
::
SetHideCell
(
sal_B
ool
bHCell
)
bool
ScProtectionAttr
::
SetHideCell
(
b
ool
bHCell
)
{
bHideCell
=
bHCell
;
return
sal_T
rue
;
return
t
rue
;
}
//------------------------------------------------------------------------
sal_Bool
ScProtectionAttr
::
SetHidePrint
(
sal_B
ool
bHPrint
)
bool
ScProtectionAttr
::
SetHidePrint
(
b
ool
bHPrint
)
{
bHidePrint
=
bHPrint
;
return
sal_T
rue
;
return
t
rue
;
}
// -----------------------------------------------------------------------
...
...
@@ -552,7 +552,7 @@ int ScTableListItem::operator==( const SfxPoolItem& rAttr ) const
OSL_ENSURE
(
SfxPoolItem
::
operator
==
(
rAttr
),
"unequal types"
);
ScTableListItem
&
rCmp
=
(
ScTableListItem
&
)
rAttr
;
sal_B
ool
bEqual
=
(
nCount
==
rCmp
.
nCount
);
b
ool
bEqual
=
(
nCount
==
rCmp
.
nCount
);
if
(
nCount
>
0
)
{
...
...
@@ -698,7 +698,7 @@ bool ScPageHFItem::PutValue( const uno::Any& rVal, sal_uInt8 /* nMemberId */ )
if
(
!
pLeftArea
||
!
pCenterArea
||
!
pRightArea
)
{
// keine Texte auf NULL stehen lassen
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
sal_T
rue
);
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
t
rue
);
if
(
!
pLeftArea
)
pLeftArea
=
aEngine
.
CreateTextObject
();
if
(
!
pCenterArea
)
...
...
@@ -758,9 +758,9 @@ void lcl_SetSpace( String& rStr, const ESelection& rSel )
rStr
.
SetChar
(
rSel
.
nStartPos
,
' '
);
}
sal_B
ool
lcl_ConvertFields
(
EditEngine
&
rEng
,
const
String
*
pCommands
)
b
ool
lcl_ConvertFields
(
EditEngine
&
rEng
,
const
String
*
pCommands
)
{
sal_B
ool
bChange
=
false
;
b
ool
bChange
=
false
;
sal_uInt16
nParCnt
=
rEng
.
GetParagraphCount
();
for
(
sal_uInt16
nPar
=
0
;
nPar
<
nParCnt
;
nPar
++
)
{
...
...
@@ -771,37 +771,37 @@ sal_Bool lcl_ConvertFields(EditEngine& rEng, const String* pCommands)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
0
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxPageField
(),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
while
((
nPos
=
aStr
.
Search
(
pCommands
[
1
]))
!=
STRING_NOTFOUND
)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
1
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxPagesField
(),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
while
((
nPos
=
aStr
.
Search
(
pCommands
[
2
]))
!=
STRING_NOTFOUND
)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
2
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxDateField
(
Date
(),
SVXDATETYPE_VAR
),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
while
((
nPos
=
aStr
.
Search
(
pCommands
[
3
]))
!=
STRING_NOTFOUND
)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
3
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxTimeField
(),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
while
((
nPos
=
aStr
.
Search
(
pCommands
[
4
]))
!=
STRING_NOTFOUND
)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
4
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxFileField
(),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
while
((
nPos
=
aStr
.
Search
(
pCommands
[
5
]))
!=
STRING_NOTFOUND
)
{
ESelection
aSel
(
nPar
,
nPos
,
nPar
,
nPos
+
pCommands
[
5
].
Len
()
);
rEng
.
QuickInsertField
(
SvxFieldItem
(
SvxTableField
(),
EE_FEATURE_FIELD
),
aSel
);
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
sal_T
rue
;
lcl_SetSpace
(
aStr
,
aSel
);
bChange
=
t
rue
;
}
}
return
bChange
;
...
...
@@ -825,7 +825,7 @@ SfxPoolItem* ScPageHFItem::Create( SvStream& rStream, sal_uInt16 nVer ) const
// Excel import in 5.1 created broken TextObjects (#67442#) that are
// corrected here to avoid saving wrong files again (#90487#).
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
sal_T
rue
);
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
t
rue
);
if
(
pLeft
==
NULL
||
pLeft
->
GetParagraphCount
()
==
0
)
{
delete
pLeft
;
...
...
@@ -859,7 +859,7 @@ SfxPoolItem* ScPageHFItem::Create( SvStream& rStream, sal_uInt16 nVer ) const
for
(
i
=
0
;
i
<
SC_FIELD_COUNT
;
i
++
)
aCommands
[
i
]
+=
rDel
;
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
sal_T
rue
);
ScEditEngineDefaulter
aEngine
(
EditEngine
::
CreatePool
(),
t
rue
);
aEngine
.
SetText
(
*
pLeft
);
if
(
lcl_ConvertFields
(
aEngine
,
aCommands
))
{
...
...
@@ -1216,7 +1216,7 @@ bool ScPageScaleToItem::QueryValue( uno::Any& rAny, sal_uInt8 nMemberId ) const
bool
ScPageScaleToItem
::
PutValue
(
const
uno
::
Any
&
rAny
,
sal_uInt8
nMemberId
)
{
sal_B
ool
bRet
=
false
;
b
ool
bRet
=
false
;
switch
(
nMemberId
)
{
case
SC_MID_PAGE_SCALETO_WIDTH
:
bRet
=
rAny
>>=
mnWidth
;
break
;
...
...
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