本文整理汇总了Python中command_support.EditCommand.EditCommand.runCommand方法的典型用法代码示例。如果您正苦于以下问题:Python EditCommand.runCommand方法的具体用法?Python EditCommand.runCommand怎么用?Python EditCommand.runCommand使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类command_support.EditCommand.EditCommand
的用法示例。
在下文中一共展示了EditCommand.runCommand方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: runCommand
# 需要导入模块: from command_support.EditCommand import EditCommand [as 别名]
# 或者: from command_support.EditCommand.EditCommand import runCommand [as 别名]
def runCommand(self):
"""
Overrides superclass method.
Run this edit command. This method is called when user invokes
Insert > Plane command (to create a new plane object) . In addition
to creating the Plane object and Property manager, this also updates
the property manager values with the ones for the new Plane object.
@see: MWSemantics.createPlane() which calls this while inserting a
new Plane
@see: self.editStructure()
@see: PlanePropertyManager.setParameters()
@see: self._updatePropMgrParams()
@TODO: The code that updates the PropMgr params etc needs to be in the
EditCommand API method/
"""
EditCommand.runCommand(self)
if self.hasValidStructure():
self._updatePropMgrParams()
#Store the previous parameters. Important to set it after you
#set attrs in the propMgr.
#self.previousParams is used in self._previewStructure and
#self._finalizeStructure to check if self.struct changed.
self.previousParams = self._gatherParameters()