Skip to content

Commit

Permalink
Fix issue #7: Differences panel for Webpage mode
Browse files Browse the repository at this point in the history
  • Loading branch information
sdottaka committed Oct 26, 2024
1 parent d6b0f37 commit fb065aa
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/WinWebDiffLib/DiffLocation.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,16 +124,19 @@ class DiffLocation
rect.top = diffRect.top;
rect.width = diffRect.width;
rect.height = diffRect.height;
for (int containerId = diffRect.containerId; containerId != -1; )
for (int containerId = diffRect.containerId; containerId > 0; )
{
const ContainerRect& containerRect = m_containerRects[window][containerId];
if (containerRect.id == 0 && (containerRect.width == 0 || containerRect.height == 0))
break;
clip(rect, containerRect);
containerId = containerRect.containerId;
}
rect.left += m_scrollX;
rect.top += m_scrollY;
if (rect.left != -99999.9f || rect.top != -99999.9f)
{
rect.left += m_scrollX;
rect.top += m_scrollY;
}
if (!window.empty())
{
calcGlobalPosition(rect, window);
Expand Down

0 comments on commit fb065aa

Please sign in to comment.