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
8d820a45
Kaydet (Commit)
8d820a45
authored
Nis 24, 2013
tarafından
Kohei Yoshida
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Let's use std::for_each for this.
Change-Id: I74f59ad697eb5ff28b81cd883db58ba9f19c086c
üst
898e806e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
6 deletions
+18
-6
column3.cxx
sc/source/core/data/column3.cxx
+18
-6
No files found.
sc/source/core/data/column3.cxx
Dosyayı görüntüle @
8d820a45
...
...
@@ -2051,6 +2051,23 @@ xub_StrLen ScColumn::GetMaxNumberStringLen(
return
nStringLen
;
}
namespace
{
struct
CellGroupSetter
:
std
::
unary_function
<
ColEntry
,
void
>
{
ScFormulaCellGroupRef
mxGroup
;
public
:
CellGroupSetter
(
const
ScFormulaCellGroupRef
&
xGroup
)
:
mxGroup
(
xGroup
)
{}
void
operator
()
(
ColEntry
&
rEntry
)
{
if
(
rEntry
.
pCell
&&
rEntry
.
pCell
->
GetCellType
()
==
CELLTYPE_FORMULA
)
static_cast
<
ScFormulaCell
*>
(
rEntry
.
pCell
)
->
SetCellGroup
(
mxGroup
);
}
};
}
// Very[!] slow way to look for and merge contiguous runs
// of similar formulae into a formulagroup
void
ScColumn
::
RebuildFormulaGroups
()
...
...
@@ -2064,12 +2081,7 @@ void ScColumn::RebuildFormulaGroups()
// clear previous groups
ScFormulaCellGroupRef
xNone
;
for
(
size_t
i
=
0
;
i
<
maItems
.
size
();
i
++
)
{
ColEntry
&
rCur
=
maItems
[
i
];
if
(
rCur
.
pCell
&&
rCur
.
pCell
->
GetCellType
()
==
CELLTYPE_FORMULA
)
static_cast
<
ScFormulaCell
*>
(
rCur
.
pCell
)
->
SetCellGroup
(
xNone
);
}
std
::
for_each
(
maItems
.
begin
(),
maItems
.
end
(),
CellGroupSetter
(
xNone
));
maFnGroups
.
clear
();
// re-build groups
...
...
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