Fixing Qt-related bugs.