summaryrefslogtreecommitdiff
path: root/fpdfsdk
diff options
context:
space:
mode:
Diffstat (limited to 'fpdfsdk')
-rw-r--r--fpdfsdk/src/fxedit/fxet_pageobjs.cpp12
-rw-r--r--fpdfsdk/src/pdfwindow/PWL_Utils.cpp4
2 files changed, 4 insertions, 12 deletions
diff --git a/fpdfsdk/src/fxedit/fxet_pageobjs.cpp b/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
index 63ab467ebe..6d091b7c19 100644
--- a/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
+++ b/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
@@ -100,9 +100,7 @@ void IFX_Edit::DrawUnderline(CFX_RenderDevice* pDevice,
if (!rcClip.IsEmpty()) {
CFX_FloatRect rcTemp = rcClip;
pUser2Device->TransformRect(rcTemp);
- pDevice->SetClip_Rect(FX_RECT((int32_t)rcTemp.left, (int32_t)rcTemp.top,
- (int32_t)rcTemp.right,
- (int32_t)rcTemp.bottom));
+ pDevice->SetClip_Rect(rcTemp.ToFxRect());
}
if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
@@ -171,9 +169,7 @@ void IFX_Edit::DrawEdit(CFX_RenderDevice* pDevice,
if (!rcClip.IsEmpty()) {
CFX_FloatRect rcTemp = rcClip;
pUser2Device->TransformRect(rcTemp);
- pDevice->SetClip_Rect(FX_RECT((int32_t)rcTemp.left, (int32_t)rcTemp.top,
- (int32_t)rcTemp.right,
- (int32_t)rcTemp.bottom));
+ pDevice->SetClip_Rect(rcTemp.ToFxRect());
}
if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
@@ -293,9 +289,7 @@ void IFX_Edit::DrawRichEdit(CFX_RenderDevice* pDevice,
if (!rcClip.IsEmpty()) {
CFX_FloatRect rcTemp = rcClip;
pUser2Device->TransformRect(rcTemp);
- pDevice->SetClip_Rect(FX_RECT((int32_t)rcTemp.left, (int32_t)rcTemp.top,
- (int32_t)rcTemp.right,
- (int32_t)rcTemp.bottom));
+ pDevice->SetClip_Rect(rcTemp.ToFxRect());
}
if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
diff --git a/fpdfsdk/src/pdfwindow/PWL_Utils.cpp b/fpdfsdk/src/pdfwindow/PWL_Utils.cpp
index db1323e78a..926ab3f0b7 100644
--- a/fpdfsdk/src/pdfwindow/PWL_Utils.cpp
+++ b/fpdfsdk/src/pdfwindow/PWL_Utils.cpp
@@ -1696,9 +1696,7 @@ void CPWL_Utils::DrawEditSpellCheck(CFX_RenderDevice* pDevice,
if (!rcClip.IsEmpty()) {
CFX_FloatRect rcTemp = rcClip;
pUser2Device->TransformRect(rcTemp);
- pDevice->SetClip_Rect(FX_RECT((int32_t)rcTemp.left, (int32_t)rcTemp.top,
- (int32_t)rcTemp.right,
- (int32_t)rcTemp.bottom));
+ pDevice->SetClip_Rect(rcTemp.ToFxRect());
}
if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {