'Deletes the selected profile.'

def delete_profile(self, widget=None):

    profile_obj = self._get_profile()
    msg = _("Do    you    really    want    to    DELETE    the    profile    '%s'?")
    dlg = gtk.MessageDialog(None, gtk.DIALOG_MODAL, gtk.MESSAGE_WARNING, gtk.BUTTONS_YES_NO, (msg % profile_obj.get_name()))
    opt = dlg.run()
    dlg.destroy()
    if (opt == gtk.RESPONSE_YES):
        if (profile_obj.get_profile_file() == self._parameter_profile):
            self._parameter_profile = None
        self.w3af.profiles.remove_profile(profile_obj.get_profile_file())
        self.w3af.mainwin.sb(_('The    profile    was    deleted'))
        self.load_profiles()
