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
96c85e7d
Kaydet (Commit)
96c85e7d
authored
Ock 16, 2018
tarafından
Noel Grandin
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
loplugin:useuniqueptr in hwpfilter
Change-Id: Id276015425ea7de3cf55b9ef21b4e7ce54c2ce47
üst
61bfcf16
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
19 additions
and
25 deletions
+19
-25
drawdef.h
hwpfilter/source/drawdef.h
+3
-2
drawing.h
hwpfilter/source/drawing.h
+2
-8
hwpfile.cxx
hwpfilter/source/hwpfile.cxx
+5
-6
hwpfile.h
hwpfilter/source/hwpfile.h
+2
-2
hwpreader.cxx
hwpfilter/source/hwpreader.cxx
+7
-7
No files found.
hwpfilter/source/drawdef.h
Dosyayı görüntüle @
96c85e7d
...
...
@@ -21,6 +21,7 @@
#define INCLUDED_HWPFILTER_SOURCE_DRAWDEF_H
#include "hwplib.h"
#include <memory>
class
HWPPara
;
...
...
@@ -228,11 +229,11 @@ struct HWPDrawingObject
HWPDOArc
arc
;
}
u
;
st
ruct
HWPDrawingObject
*
next
;
st
d
::
unique_ptr
<
struct
HWPDrawingObject
>
next
;
/**
* This exists for container object
*/
st
ruct
HWPDrawingObject
*
child
;
st
d
::
unique_ptr
<
struct
HWPDrawingObject
>
child
;
int
index
;
HWPDrawingObject
();
~
HWPDrawingObject
();
...
...
hwpfilter/source/drawing.h
Dosyayı görüntüle @
96c85e7d
...
...
@@ -355,7 +355,7 @@ static HWPDrawingObject *LoadDrawingObject(void)
}
if
(
link_info
&
HDOFILE_HAS_CHILD
)
{
hdo
->
child
=
LoadDrawingObject
(
);
hdo
->
child
.
reset
(
LoadDrawingObject
()
);
if
(
hdo
->
child
==
nullptr
)
{
goto
error
;
...
...
@@ -364,7 +364,7 @@ static HWPDrawingObject *LoadDrawingObject(void)
if
(
prev
==
nullptr
)
head
=
hdo
;
else
prev
->
next
=
hdo
;
prev
->
next
.
reset
(
hdo
)
;
prev
=
hdo
;
}
while
(
link_info
&
HDOFILE_HAS_NEXT
);
...
...
@@ -682,12 +682,6 @@ HWPDrawingObject::HWPDrawingObject()
HWPDrawingObject
::~
HWPDrawingObject
()
{
if
(
child
)
delete
child
;
if
(
next
)
delete
next
;
if
(
property
.
pPara
)
FreeParaList
(
property
.
pPara
);
...
...
hwpfilter/source/hwpfile.cxx
Dosyayı görüntüle @
96c85e7d
...
...
@@ -61,8 +61,8 @@ HWPFile::HWPFile()
HWPFile
::~
HWPFile
()
{
delete
oledata
;
delete
hiodev
;
oledata
.
reset
()
;
hiodev
.
reset
()
;
}
int
HWPFile
::
ReadHwpFile
(
HStream
*
stream
)
...
...
@@ -185,9 +185,9 @@ void HWPFile::SetCompressed(bool flag)
HIODev
*
HWPFile
::
SetIODevice
(
HIODev
*
new_hiodev
)
{
HIODev
*
old_hiodev
=
hiodev
;
HIODev
*
old_hiodev
=
hiodev
.
release
()
;
hiodev
=
new_hiodev
;
hiodev
.
reset
(
new_hiodev
)
;
return
old_hiodev
;
}
...
...
@@ -316,8 +316,7 @@ void HWPFile::TagsRead()
}
break
;
case
FILETAG_OLE_OBJECT
:
delete
oledata
;
oledata
=
new
OlePicture
(
size
);
oledata
.
reset
(
new
OlePicture
(
size
)
);
oledata
->
Read
(
*
this
);
break
;
case
FILETAG_HYPERTEXT
:
...
...
hwpfilter/source/hwpfile.h
Dosyayı görüntüle @
96c85e7d
...
...
@@ -273,7 +273,7 @@ class DLLEXPORT HWPFile
unsigned
char
linenumber
;
int
info_block_len
;
int
error_code
;
OlePicture
*
oledata
;
std
::
unique_ptr
<
OlePicture
>
oledata
;
unsigned
char
scratch
[
SAL_MAX_UINT16
];
int
readdepth
;
...
...
@@ -281,7 +281,7 @@ class DLLEXPORT HWPFile
/* hwp 파일 이름 */
int
m_nCurrentPage
;
int
m_nMaxSettedPage
;
HIODev
*
hiodev
;
std
::
unique_ptr
<
HIODev
>
hiodev
;
// read hwp contents
HWPInfo
_hwpInfo
;
HWPFont
_hwpFont
;
...
...
hwpfilter/source/hwpreader.cxx
Dosyayı görüntüle @
96c85e7d
...
...
@@ -427,12 +427,12 @@ void HwpReader::makeDrawMiscStyle( HWPDrawingObject *hdo )
while
(
hdo
)
{
if
(
hdo
->
child
)
makeDrawMiscStyle
(
hdo
->
child
);
makeDrawMiscStyle
(
hdo
->
child
.
get
()
);
HWPDOProperty
*
prop
=
&
hdo
->
property
;
if
(
hdo
->
type
==
HWPDO_CONTAINER
)
{
hdo
=
hdo
->
next
;
hdo
=
hdo
->
next
.
get
()
;
continue
;
}
...
...
@@ -694,7 +694,7 @@ void HwpReader::makeDrawMiscStyle( HWPDrawingObject *hdo )
rendEl
(
"draw:hatch"
);
}
}
hdo
=
hdo
->
next
;
hdo
=
hdo
->
next
.
get
()
;
}
}
...
...
@@ -2205,9 +2205,9 @@ void HwpReader::makeDrawStyle( HWPDrawingObject * hdo, FBoxStyle * fstyle)
if
(
hdo
->
type
==
0
)
{
makeDrawStyle
(
hdo
->
child
,
fstyle
);
makeDrawStyle
(
hdo
->
child
.
get
()
,
fstyle
);
}
hdo
=
hdo
->
next
;
hdo
=
hdo
->
next
.
get
()
;
}
}
...
...
@@ -4016,7 +4016,7 @@ void HwpReader::makePictureDRAW(HWPDrawingObject *drawobj, Picture * hbox)
{
rstartEl
(
"draw:g"
,
mxList
.
get
());
mxList
->
clear
();
makePictureDRAW
(
drawobj
->
child
,
hbox
);
makePictureDRAW
(
drawobj
->
child
.
get
()
,
hbox
);
rendEl
(
"draw:g"
);
}
else
...
...
@@ -4574,7 +4574,7 @@ void HwpReader::makePictureDRAW(HWPDrawingObject *drawobj, Picture * hbox)
}
}
mxList
->
clear
();
drawobj
=
drawobj
->
next
;
drawobj
=
drawobj
->
next
.
get
()
;
}
}
...
...
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