Fix for more generic versions of Qt