Debugger: Handle Qt4/5 behavior incompatibility in QVariant handler

Change-Id: I059955b24daa323d4f0a85e67650ee29c018d1b6
Reviewed-by: hjk <hjk121@nokiamail.com>