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
cca4e470
Kaydet (Commit)
cca4e470
authored
Eyl 05, 2014
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
coverity#1233486 Unchecked dynamic_cast
Change-Id: Icc4faeb5597267c04591e8d68ec429344d5bd126
üst
0065cb5d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
unotext.cxx
sw/source/core/unocore/unotext.cxx
+9
-9
No files found.
sw/source/core/unocore/unotext.cxx
Dosyayı görüntüle @
cca4e470
...
@@ -1674,14 +1674,14 @@ SwXText::convertToTextFrame(
...
@@ -1674,14 +1674,14 @@ SwXText::convertToTextFrame(
const
uno
::
Reference
<
text
::
XTextFrame
>
xNewFrame
(
const
uno
::
Reference
<
text
::
XTextFrame
>
xNewFrame
(
SwXTextFrame
::
CreateXTextFrame
(
*
m_pImpl
->
m_pDoc
,
0
));
SwXTextFrame
::
CreateXTextFrame
(
*
m_pImpl
->
m_pDoc
,
0
));
SwXTextFrame
*
const
pNewFrame
=
dynamic_cast
<
SwXTextFrame
*>
(
xNewFrame
.
get
());
SwXTextFrame
&
rNewFrame
=
dynamic_cast
<
SwXTextFrame
&>
(
*
xNewFrame
.
get
());
pNewFrame
->
SetSelection
(
aStartPam
);
rNewFrame
.
SetSelection
(
aStartPam
);
try
try
{
{
const
beans
::
PropertyValue
*
pValues
=
rFrameProperties
.
getConstArray
();
const
beans
::
PropertyValue
*
pValues
=
rFrameProperties
.
getConstArray
();
for
(
sal_Int32
nProp
=
0
;
nProp
<
rFrameProperties
.
getLength
();
++
nProp
)
for
(
sal_Int32
nProp
=
0
;
nProp
<
rFrameProperties
.
getLength
();
++
nProp
)
{
{
pNewFrame
->
SwXFrame
::
setPropertyValue
(
rNewFrame
.
SwXFrame
::
setPropertyValue
(
pValues
[
nProp
].
Name
,
pValues
[
nProp
].
Value
);
pValues
[
nProp
].
Name
,
pValues
[
nProp
].
Value
);
}
}
...
@@ -1690,8 +1690,8 @@ SwXText::convertToTextFrame(
...
@@ -1690,8 +1690,8 @@ SwXText::convertToTextFrame(
const
uno
::
Reference
<
text
::
XTextRange
>
xInsertTextRange
=
const
uno
::
Reference
<
text
::
XTextRange
>
xInsertTextRange
=
new
SwXTextRange
(
aStartPam
,
this
);
new
SwXTextRange
(
aStartPam
,
this
);
aStartPam
.
DeleteMark
();
// mark position node may be deleted!
aStartPam
.
DeleteMark
();
// mark position node may be deleted!
pNewFrame
->
attach
(
xInsertTextRange
);
rNewFrame
.
attach
(
xInsertTextRange
);
pNewFrame
->
setName
(
m_pImpl
->
m_pDoc
->
GetUniqueFrameName
());
rNewFrame
.
setName
(
m_pImpl
->
m_pDoc
->
GetUniqueFrameName
());
}
}
SwTxtNode
*
const
pTxtNode
(
aStartPam
.
GetNode
().
GetTxtNode
());
SwTxtNode
*
const
pTxtNode
(
aStartPam
.
GetNode
().
GetTxtNode
());
...
@@ -1704,10 +1704,10 @@ SwXText::convertToTextFrame(
...
@@ -1704,10 +1704,10 @@ SwXText::convertToTextFrame(
if
(
aMovePam
.
Move
(
fnMoveForward
,
fnGoCntnt
))
if
(
aMovePam
.
Move
(
fnMoveForward
,
fnGoCntnt
))
{
{
// move the anchor to the next paragraph
// move the anchor to the next paragraph
SwFmtAnchor
aNewAnchor
(
pNewFrame
->
GetFrmFmt
()
->
GetAnchor
());
SwFmtAnchor
aNewAnchor
(
rNewFrame
.
GetFrmFmt
()
->
GetAnchor
());
aNewAnchor
.
SetAnchor
(
aMovePam
.
Start
()
);
aNewAnchor
.
SetAnchor
(
aMovePam
.
Start
()
);
m_pImpl
->
m_pDoc
->
SetAttr
(
m_pImpl
->
m_pDoc
->
SetAttr
(
aNewAnchor
,
*
pNewFrame
->
GetFrmFmt
()
);
aNewAnchor
,
*
rNewFrame
.
GetFrmFmt
()
);
// also move frames anchored to us
// also move frames anchored to us
for
(
size_t
i
=
0
;
i
<
m_pImpl
->
m_pDoc
->
GetSpzFrmFmts
()
->
size
();
++
i
)
for
(
size_t
i
=
0
;
i
<
m_pImpl
->
m_pDoc
->
GetSpzFrmFmts
()
->
size
();
++
i
)
...
@@ -1736,11 +1736,11 @@ SwXText::convertToTextFrame(
...
@@ -1736,11 +1736,11 @@ SwXText::convertToTextFrame(
sMessage
=
rRuntime
.
Message
;
sMessage
=
rRuntime
.
Message
;
bRuntimeException
=
true
;
bRuntimeException
=
true
;
}
}
xRet
=
p
NewFrame
;
xRet
=
&
r
NewFrame
;
if
(
bParaBeforeInserted
||
bParaAfterInserted
)
if
(
bParaBeforeInserted
||
bParaAfterInserted
)
{
{
const
uno
::
Reference
<
text
::
XTextCursor
>
xFrameTextCursor
=
const
uno
::
Reference
<
text
::
XTextCursor
>
xFrameTextCursor
=
pNewFrame
->
createTextCursor
();
rNewFrame
.
createTextCursor
();
const
uno
::
Reference
<
XUnoTunnel
>
xTunnel
(
xFrameTextCursor
,
const
uno
::
Reference
<
XUnoTunnel
>
xTunnel
(
xFrameTextCursor
,
uno
::
UNO_QUERY
);
uno
::
UNO_QUERY
);
SwXTextCursor
*
const
pFrameCursor
=
SwXTextCursor
*
const
pFrameCursor
=
...
...
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