def METHOD_NAME(self, row, column):
    flags = Qt.ItemIsEnabled | Qt.ItemIsSelectable
    if column.name == "marked":
        if row.markable:
            flags |= Qt.ItemIsUserCheckable
    elif column.name == "name":
        flags |= Qt.ItemIsEditable
    return flags