'Enable the resizing of the menu with a size grip in a bottom
right corner (enabled by default).'

def setSizeGripEnabled(self, enabled):

    if (bool(enabled) != bool(self.__grip)):
        if self.__grip:
            self.__grip.deleteLater()
            self.__grip = None
        else:
            self.__grip = WindowSizeGrip(self)
            self.__grip.raise_()
