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
7b7d1120
Kaydet (Commit)
7b7d1120
authored
Şub 22, 2015
tarafından
Miklos Vajna
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Extract SwRangeRedline::dumpAsXml() from SwRedlineTbl
Change-Id: Ia0eea8a0c4ef7a8297da185d8187017e76bea422
üst
4e910033
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
44 additions
and
40 deletions
+44
-40
redline.hxx
sw/inc/redline.hxx
+1
-0
docredln.cxx
sw/source/core/doc/docredln.cxx
+43
-40
No files found.
sw/inc/redline.hxx
Dosyayı görüntüle @
7b7d1120
...
@@ -293,6 +293,7 @@ public:
...
@@ -293,6 +293,7 @@ public:
bool
operator
==
(
const
SwRangeRedline
&
)
const
;
bool
operator
==
(
const
SwRangeRedline
&
)
const
;
bool
operator
<
(
const
SwRangeRedline
&
)
const
;
bool
operator
<
(
const
SwRangeRedline
&
)
const
;
void
dumpAsXml
(
struct
_xmlTextWriter
*
pWriter
)
const
;
};
};
/// Base object for 'Redlines' that are not of 'Ranged' type (like table row insert\delete)
/// Base object for 'Redlines' that are not of 'Ranged' type (like table row insert\delete)
...
...
sw/source/core/doc/docredln.cxx
Dosyayı görüntüle @
7b7d1120
...
@@ -572,47 +572,9 @@ void SwRedlineTbl::dumpAsXml(xmlTextWriterPtr pWriter) const
...
@@ -572,47 +572,9 @@ void SwRedlineTbl::dumpAsXml(xmlTextWriterPtr pWriter) const
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"ptr"
),
"%p"
,
this
);
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"ptr"
),
"%p"
,
this
);
for
(
sal_uInt16
nCurRedlinePos
=
0
;
nCurRedlinePos
<
size
();
++
nCurRedlinePos
)
for
(
sal_uInt16
nCurRedlinePos
=
0
;
nCurRedlinePos
<
size
();
++
nCurRedlinePos
)
{
operator
[](
nCurRedlinePos
)
->
dumpAsXml
(
pWriter
);
const
SwRangeRedline
*
pRedline
=
operator
[](
nCurRedlinePos
);
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"swRangeRedline"
));
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"ptr"
),
"%p"
,
pRedline
);
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"id"
),
BAD_CAST
(
OString
::
number
(
pRedline
->
GetSeqNo
()).
getStr
()));
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"author"
),
BAD_CAST
(
SW_MOD
()
->
GetRedlineAuthor
(
pRedline
->
GetAuthor
()).
toUtf8
().
getStr
()));
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"date"
),
BAD_CAST
(
DateTimeToOString
(
pRedline
->
GetTimeStamp
()).
getStr
()));
OString
sRedlineType
;
xmlTextWriterEndElement
(
pWriter
);
switch
(
pRedline
->
GetType
())
{
case
nsRedlineType_t
:
:
REDLINE_INSERT
:
sRedlineType
=
"REDLINE_INSERT"
;
break
;
case
nsRedlineType_t
:
:
REDLINE_DELETE
:
sRedlineType
=
"REDLINE_DELETE"
;
break
;
case
nsRedlineType_t
:
:
REDLINE_FORMAT
:
sRedlineType
=
"REDLINE_FORMAT"
;
break
;
default
:
sRedlineType
=
"UNKNOWN"
;
break
;
}
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"type"
),
BAD_CAST
(
sRedlineType
.
getStr
()));
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"point"
));
pRedline
->
GetPoint
()
->
dumpAsXml
(
pWriter
);
xmlTextWriterEndElement
(
pWriter
);
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"mark"
));
pRedline
->
GetMark
()
->
dumpAsXml
(
pWriter
);
xmlTextWriterEndElement
(
pWriter
);
const
SwRedlineExtraData
*
pExtraRedlineData
=
pRedline
->
GetExtraData
();
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"swRedlineExtraData"
));
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"symbol"
),
"%s"
,
BAD_CAST
(
typeid
(
pExtraRedlineData
).
name
()));
xmlTextWriterEndElement
(
pWriter
);
// swRadlineExtraData
xmlTextWriterEndElement
(
pWriter
);
// swRangeRedline
}
xmlTextWriterEndElement
(
pWriter
);
// swRedlineTbl
}
}
SwRedlineExtraData
::~
SwRedlineExtraData
()
SwRedlineExtraData
::~
SwRedlineExtraData
()
...
@@ -1651,6 +1613,47 @@ OUString SwRangeRedline::GetDescr(sal_uInt16 nPos)
...
@@ -1651,6 +1613,47 @@ OUString SwRangeRedline::GetDescr(sal_uInt16 nPos)
return
aResult
;
return
aResult
;
}
}
void
SwRangeRedline
::
dumpAsXml
(
xmlTextWriterPtr
pWriter
)
const
{
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"swRangeRedline"
));
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"ptr"
),
"%p"
,
this
);
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"id"
),
BAD_CAST
(
OString
::
number
(
GetSeqNo
()).
getStr
()));
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"author"
),
BAD_CAST
(
SW_MOD
()
->
GetRedlineAuthor
(
GetAuthor
()).
toUtf8
().
getStr
()));
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"date"
),
BAD_CAST
(
DateTimeToOString
(
GetTimeStamp
()).
getStr
()));
OString
sRedlineType
;
switch
(
GetType
())
{
case
nsRedlineType_t
:
:
REDLINE_INSERT
:
sRedlineType
=
"REDLINE_INSERT"
;
break
;
case
nsRedlineType_t
:
:
REDLINE_DELETE
:
sRedlineType
=
"REDLINE_DELETE"
;
break
;
case
nsRedlineType_t
:
:
REDLINE_FORMAT
:
sRedlineType
=
"REDLINE_FORMAT"
;
break
;
default
:
sRedlineType
=
"UNKNOWN"
;
break
;
}
xmlTextWriterWriteAttribute
(
pWriter
,
BAD_CAST
(
"type"
),
BAD_CAST
(
sRedlineType
.
getStr
()));
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"point"
));
GetPoint
()
->
dumpAsXml
(
pWriter
);
xmlTextWriterEndElement
(
pWriter
);
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"mark"
));
GetMark
()
->
dumpAsXml
(
pWriter
);
xmlTextWriterEndElement
(
pWriter
);
const
SwRedlineExtraData
*
pExtraRedlineData
=
GetExtraData
();
xmlTextWriterStartElement
(
pWriter
,
BAD_CAST
(
"swRedlineExtraData"
));
xmlTextWriterWriteFormatAttribute
(
pWriter
,
BAD_CAST
(
"symbol"
),
"%s"
,
BAD_CAST
(
typeid
(
pExtraRedlineData
).
name
()));
xmlTextWriterEndElement
(
pWriter
);
// swRadlineExtraData
xmlTextWriterEndElement
(
pWriter
);
}
bool
SwExtraRedlineTbl
::
Insert
(
SwExtraRedline
*
p
)
bool
SwExtraRedlineTbl
::
Insert
(
SwExtraRedline
*
p
)
{
{
m_aExtraRedlines
.
push_back
(
p
);
m_aExtraRedlines
.
push_back
(
p
);
...
...
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