def make_element(self, cd, parent, type): if type == "Custom": return CustomBlock(cd, 'Custom').construct(parent) elif type == "Input": return InputBlock(cd, 'Input', '用户取得自定义功能的输入数据').construct(parent) elif type == "Output": return OutputBlock(cd, 'Output', '用于设定用户自定义模块的输出数据').construct(parent) elif type == "Note": return Note(cd).construct(parent)