make compatible with qt5