def METHOD_NAME(self):
    if self.uiExistingImageRadioButton.isChecked():
        index = self.uiImageListComboBox.currentIndex()
        return self.uiImageListComboBox.itemText(index)
    else:
        name = self.uiImageLineEdit.text()
        return name