Index: fpdfsdk/fxedit/fxet_edit.cpp |
diff --git a/fpdfsdk/fxedit/fxet_edit.cpp b/fpdfsdk/fxedit/fxet_edit.cpp |
index fb219ca16ca18604836df0755b24b75ee1e7e63d..603c459cf77303c812733fbd100a3ab519a7f9f9 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); |
} |