Commit 1fef3c41 authored by hjk's avatar hjk

Debugger: Fix QRegion dumper for Qt 5.4

The layout has changed in ee324e4ed527.

Change-Id: I4b5f47f6526bf1218fdb79dc625f7482af21012b
Reviewed-by: default avatarChristian Stenger <christian.stenger@digia.com>
parent 5fb0d57d
......@@ -1582,14 +1582,20 @@ def qdump__QRegion(d, value):
ns = d.qtNamespace()
rectType = d.lookupType(ns + "QRect")
d.putIntItem("numRects", n)
d.putSubItem("extents", d.createValue(pp + 2 * v, rectType))
d.putSubItem("innerRect", d.createValue(pp + 2 * v + rectType.sizeof, rectType))
d.putIntItem("innerArea", d.extractInt(pp + 2 * v + 2 * rectType.sizeof))
if d.qtVersion() >= 0x050400:
# Changed in ee324e4ed
d.putSubItem("extents", d.createValue(pp + 8 + v, rectType))
d.putSubItem("innerRect", d.createValue(pp + 8 + v + rectType.sizeof, rectType))
d.putIntItem("innerArea", d.extractInt(pp + 4))
else:
d.putSubItem("extents", d.createValue(pp + 2 * v, rectType))
d.putSubItem("innerRect", d.createValue(pp + 2 * v + rectType.sizeof, rectType))
d.putIntItem("innerArea", d.extractInt(pp + 2 * v + 2 * rectType.sizeof))
# FIXME
try:
# Can fail if QVector<QRect> debuginfo is missing.
vectType = d.lookupType("%sQVector<%sQRect>" % (ns, ns))
d.putSubItem("rects", d.createValue(pp + v, vectType))
d.putSubItem("rects", d.createValue(pp + 8, vectType))
except:
with SubItem(d, "rects"):
d.putItemCount(n)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment