QMessageBox.critical(self,"Error",f"Could not create profile directory: {e}")
return
else:
QMessageBox.warning(self,"Profile Exists","A profile with that name already exists.")
defdelete_profile(self):
selected_items=self.profile_list.selectedItems()
ifnotselected_items:
return
item=selected_items[0]
profile_name=item.text()
profile_path=item.data(Qt.ItemDataRole.UserRole)
reply=QMessageBox.question(self,"Confirm Deletion",f"Are you sure you want to delete the profile '{profile_name}'?\nThis will permanently delete all its data.",