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
2460b39d
Kaydet (Commit)
2460b39d
authored
Mar 28, 2013
tarafından
Kohei Yoshida
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
ScBaseCell::CellEqual is no more.
Change-Id: I9a2923ec85ce116662d66a38b61a5258ff113168
üst
b9079dc2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
94 deletions
+12
-94
cell.hxx
sc/inc/cell.hxx
+0
-2
cell.cxx
sc/source/core/data/cell.cxx
+0
-80
documen4.cxx
sc/source/core/data/documen4.cxx
+12
-12
No files found.
sc/inc/cell.hxx
Dosyayı görüntüle @
2460b39d
...
...
@@ -100,8 +100,6 @@ public:
bool
HasStringData
()
const
;
rtl
::
OUString
GetStringData
()
const
;
// only real strings
static
bool
CellEqual
(
const
ScBaseCell
*
pCell1
,
const
ScBaseCell
*
pCell2
);
private
:
ScBaseCell
&
operator
=
(
const
ScBaseCell
&
);
...
...
sc/source/core/data/cell.cxx
Dosyayı görüntüle @
2460b39d
...
...
@@ -345,86 +345,6 @@ rtl::OUString ScBaseCell::GetStringData() const
return
aStr
;
}
bool
ScBaseCell
::
CellEqual
(
const
ScBaseCell
*
pCell1
,
const
ScBaseCell
*
pCell2
)
{
CellType
eType1
=
CELLTYPE_NONE
;
CellType
eType2
=
CELLTYPE_NONE
;
if
(
pCell1
)
{
eType1
=
pCell1
->
GetCellType
();
if
(
eType1
==
CELLTYPE_EDIT
)
eType1
=
CELLTYPE_STRING
;
else
if
(
eType1
==
CELLTYPE_NOTE
)
eType1
=
CELLTYPE_NONE
;
}
if
(
pCell2
)
{
eType2
=
pCell2
->
GetCellType
();
if
(
eType2
==
CELLTYPE_EDIT
)
eType2
=
CELLTYPE_STRING
;
else
if
(
eType2
==
CELLTYPE_NOTE
)
eType2
=
CELLTYPE_NONE
;
}
if
(
eType1
!=
eType2
)
return
false
;
switch
(
eType1
)
// Both Types are the same
{
case
CELLTYPE_NONE
:
// Both Empty
return
true
;
case
CELLTYPE_VALUE
:
// Really Value-Cells
return
(
((
const
ScValueCell
*
)
pCell1
)
->
GetValue
()
==
((
const
ScValueCell
*
)
pCell2
)
->
GetValue
()
);
case
CELLTYPE_STRING
:
// String or Edit
{
rtl
::
OUString
aText1
;
if
(
pCell1
->
GetCellType
()
==
CELLTYPE_STRING
)
aText1
=
((
const
ScStringCell
*
)
pCell1
)
->
GetString
();
else
aText1
=
((
const
ScEditCell
*
)
pCell1
)
->
GetString
();
rtl
::
OUString
aText2
;
if
(
pCell2
->
GetCellType
()
==
CELLTYPE_STRING
)
aText2
=
((
const
ScStringCell
*
)
pCell2
)
->
GetString
();
else
aText2
=
((
const
ScEditCell
*
)
pCell2
)
->
GetString
();
return
(
aText1
==
aText2
);
}
case
CELLTYPE_FORMULA
:
{
//! pasted Lines / allow Slots!!!!!
//! Comparsion Function of the Formula Cell???
//! To request with ScColumn::SwapRow to catch together!
ScTokenArray
*
pCode1
=
((
ScFormulaCell
*
)
pCell1
)
->
GetCode
();
ScTokenArray
*
pCode2
=
((
ScFormulaCell
*
)
pCell2
)
->
GetCode
();
if
(
pCode1
->
GetLen
()
==
pCode2
->
GetLen
())
// nicht-UPN
{
bool
bEqual
=
true
;
sal_uInt16
nLen
=
pCode1
->
GetLen
();
FormulaToken
**
ppToken1
=
pCode1
->
GetArray
();
FormulaToken
**
ppToken2
=
pCode2
->
GetArray
();
for
(
sal_uInt16
i
=
0
;
i
<
nLen
;
i
++
)
if
(
!
ppToken1
[
i
]
->
TextEqual
(
*
(
ppToken2
[
i
]))
)
{
bEqual
=
false
;
break
;
}
if
(
bEqual
)
return
true
;
}
return
false
;
// varying long or varying Tokens
}
default
:
OSL_FAIL
(
"oops, something for the Cells???"
);
}
return
false
;
}
// ============================================================================
ScNoteCell
::
ScNoteCell
(
SvtBroadcaster
*
pBC
)
:
ScBaseCell
(
CELLTYPE_NOTE
)
{
...
...
sc/source/core/data/documen4.cxx
Dosyayı görüntüle @
2460b39d
...
...
@@ -790,18 +790,18 @@ sal_uInt16 ScDocument::RowDifferences( SCROW nThisRow, SCTAB nThisTab,
if
(
ValidCol
(
nOtherCol
))
// nur Spalten vergleichen, die in beiden Dateien sind
{
const
ScBaseCell
*
pThisCell
=
GetCell
(
ScAddress
(
nThisCol
,
nThisRow
,
nThisTab
)
);
const
ScBaseCell
*
pOtherCell
=
rOtherDoc
.
GetCell
(
ScAddress
(
nOtherCol
,
nOtherRow
,
nOtherTab
)
);
if
(
!
ScBaseCell
::
CellEqual
(
pThisCell
,
pOtherCell
))
ScRefCellValue
aThisCell
,
aOtherCell
;
aThisCell
.
assign
(
*
this
,
ScAddress
(
nThisCol
,
nThisRow
,
nThisTab
));
aOtherCell
.
assign
(
rOtherDoc
,
ScAddress
(
nOtherCol
,
nOtherRow
,
nOtherTab
));
if
(
!
aThisCell
.
equalsWithoutFormat
(
aOtherCell
))
{
if
(
pThisCell
&&
pOtherCell
)
if
(
!
aThisCell
.
isEmpty
()
&&
!
aOtherCell
.
isEmpty
()
)
nDif
+=
3
;
else
nDif
+=
4
;
// Inhalt <-> leer zaehlt mehr
}
if
(
(
pThisCell
&&
pThisCell
->
GetCellType
()
!=
CELLTYPE_NOTE
)
||
(
pOtherCell
&&
pOtherCell
->
GetCellType
()
!=
CELLTYPE_NOTE
)
)
if
(
!
aThisCell
.
isEmpty
()
||
!
aOtherCell
.
isEmpty
())
++
nUsed
;
}
}
...
...
@@ -831,18 +831,18 @@ sal_uInt16 ScDocument::ColDifferences( SCCOL nThisCol, SCTAB nThisTab,
if
(
ValidRow
(
nOtherRow
))
// nur Zeilen vergleichen, die in beiden Dateien sind
{
const
ScBaseCell
*
pThisCell
=
GetCell
(
ScAddress
(
nThisCol
,
nThisRow
,
nThisTab
)
);
const
ScBaseCell
*
pOtherCell
=
rOtherDoc
.
GetCell
(
ScAddress
(
nOtherCol
,
nOtherRow
,
nOtherTab
)
);
if
(
!
ScBaseCell
::
CellEqual
(
pThisCell
,
pOtherCell
))
ScRefCellValue
aThisCell
,
aOtherCell
;
aThisCell
.
assign
(
*
this
,
ScAddress
(
nThisCol
,
nThisRow
,
nThisTab
));
aOtherCell
.
assign
(
rOtherDoc
,
ScAddress
(
nOtherCol
,
nOtherRow
,
nOtherTab
));
if
(
!
aThisCell
.
equalsWithoutFormat
(
aOtherCell
))
{
if
(
pThisCell
&&
pOtherCell
)
if
(
!
aThisCell
.
isEmpty
()
&&
!
aOtherCell
.
isEmpty
()
)
nDif
+=
3
;
else
nDif
+=
4
;
// Inhalt <-> leer zaehlt mehr
}
if
(
(
pThisCell
&&
pThisCell
->
GetCellType
()
!=
CELLTYPE_NOTE
)
||
(
pOtherCell
&&
pOtherCell
->
GetCellType
()
!=
CELLTYPE_NOTE
)
)
if
(
!
aThisCell
.
isEmpty
()
||
!
aOtherCell
.
isEmpty
())
++
nUsed
;
}
}
...
...
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