Implement workaround for PySide bug