Replace #include <QtWidgets> with accurate #include to be compatible Qt4 and Qt5.