Added Qt5 compatibility.