diff options
Diffstat (limited to 'fpdfsdk/fxedit/fxet_edit.cpp')
-rw-r--r-- | fpdfsdk/fxedit/fxet_edit.cpp | 67 |
1 files changed, 0 insertions, 67 deletions
diff --git a/fpdfsdk/fxedit/fxet_edit.cpp b/fpdfsdk/fxedit/fxet_edit.cpp index fb219ca16c..603c459cf7 100644 --- a/fpdfsdk/fxedit/fxet_edit.cpp +++ b/fpdfsdk/fxedit/fxet_edit.cpp @@ -349,73 +349,6 @@ void CFX_Edit_Refresh::NoAnalyse() { } } -void CFX_Edit_Refresh::Analyse(int32_t nAlignment) { - FX_BOOL bLineTopChanged = FALSE; - CFX_FloatRect rcResult; - FX_FLOAT fWidthDiff; - - int32_t szMax = std::max(m_OldLineRects.GetSize(), m_NewLineRects.GetSize()); - int32_t i = 0; - - while (i < szMax) { - CFX_Edit_LineRect* pOldRect = m_OldLineRects.GetAt(i); - CFX_Edit_LineRect* pNewRect = m_NewLineRects.GetAt(i); - - if (pOldRect) { - if (pNewRect) { - if (bLineTopChanged) { - rcResult = pOldRect->m_rcLine; - rcResult.Union(pNewRect->m_rcLine); - m_RefreshRects.Add(rcResult); - } else { - if (*pNewRect != *pOldRect) { - if (!pNewRect->IsSameTop(*pOldRect) || - !pNewRect->IsSameHeight(*pOldRect)) { - bLineTopChanged = TRUE; - continue; - } - - if (nAlignment == 0) { - if (pNewRect->m_wrLine.BeginPos != pOldRect->m_wrLine.BeginPos) { - rcResult = pOldRect->m_rcLine; - rcResult.Union(pNewRect->m_rcLine); - m_RefreshRects.Add(rcResult); - } else { - if (!pNewRect->IsSameLeft(*pOldRect)) { - rcResult = pOldRect->m_rcLine; - rcResult.Union(pNewRect->m_rcLine); - } else { - fWidthDiff = - pNewRect->m_rcLine.Width() - pOldRect->m_rcLine.Width(); - rcResult = pNewRect->m_rcLine; - if (fWidthDiff > 0.0f) { - rcResult.left = rcResult.right - fWidthDiff; - } else { - rcResult.left = rcResult.right; - rcResult.right -= fWidthDiff; - } - } - m_RefreshRects.Add(rcResult); - } - } else { - rcResult = pOldRect->m_rcLine; - rcResult.Union(pNewRect->m_rcLine); - m_RefreshRects.Add(rcResult); - } - } - } - } else { - m_RefreshRects.Add(pOldRect->m_rcLine); - } - } else { - if (pNewRect) { - m_RefreshRects.Add(pNewRect->m_rcLine); - } - } - i++; - } -} - void CFX_Edit_Refresh::AddRefresh(const CFX_FloatRect& rect) { m_RefreshRects.Add(rect); } |