Package Pmv :: Module deleteCommands :: Class DeleteMolecule
[hide private]
[frames] | no frames]

Class DeleteMolecule

source code

ViewerFramework.VFCommand.Command --+    
                                    |    
                  mvCommand.MVCommand --+
                                        |
                                       DeleteMolecule

Command to delete a molecule from the MoleculeViewer
    
Package : Pmv
    
Module  : deleteCommands
    
Class   : DeleteMolecule
    
Command : deleteMolecule
    
Synopsis:

        None<---deleteMol(nodes, **kw)
    
Required Arguments:

        nodes --- TreeNodeSet holding the current selection
           It resets the undo stack automatically.

    



Instance Methods [hide private]
  onAddCmdToViewer(self)
method called when an instance of this command is added to the viewer.
  onAddObjectToViewer(self, obj)
  deleteMolecule_cb(self)
called each time the 'Delete Molecule' button is pressed
  hide_cb(self)
  continue_cb(self)
  cancel_cb(self)
  guiCallback(self)
Default callback function called by the gui
  deleteMol(self, mol)
Function to delete all the references to each elements of a molecule and then these elements and the molecule to free the memory space.
  getFreeMemoryInformation(self)
Store how many TreeNodes have been actually free'ed during the last delete operation in a dictionary
  doit(self, nodes)
virtual method.
  __call__(self, nodes, **kw)
None <- deleteMol(nodes, **kw)

Inherited from mvCommand.MVCommand: __init__, strArg

Inherited from mvCommand.MVCommand (private): _strArg

Inherited from ViewerFramework.VFCommand.Command: __repr__, addCallbackAfter, addCallbackBefore, addUndoCall, afterDoit, beforeDoit, buildFormDescr, buildLogArgList, checkDependencies, cleanup, customizeGUI, doitWrapper, getArguments, getHelp, getLastUsedValues, getLogArgs, getValNamedArgs, log, logString, onAddNewCmd, onCmdRun, setLastUsedValues, setupUndoAfter, setupUndoBefore, showForm, tkCb, updateGeom, warningMsg


Class Variables [hide private]

Inherited from ViewerFramework.VFCommand.Command: negateKw, objArgOnly


Method Details [hide private]

onAddCmdToViewer(self)

source code 
method called when an instance of this command is added to the viewer. This enable viewer-addition time initializations
Overrides: ViewerFramework.VFCommand.Command.onAddCmdToViewer
(inherited documentation)

onAddObjectToViewer(self, obj)

source code 
None

deleteMolecule_cb(self)

source code 
called each time the 'Delete Molecule' button is pressed

hide_cb(self)

source code 
None

continue_cb(self)

source code 
None

cancel_cb(self)

source code 
None

guiCallback(self)

source code 
Default callback function called by the gui
Overrides: mvCommand.MVCommand.guiCallback

deleteMol(self, mol)

source code 
Function to delete all the references to each elements of a molecule and then these elements and the molecule to free the memory space.

getFreeMemoryInformation(self)

source code 
Store how many TreeNodes have been actually free'ed during the last delete operation in a dictionary

doit(self, nodes)

source code 
virtual method. Has to be implemented by the sub classes
Overrides: ViewerFramework.VFCommand.Command.doit
(inherited documentation)

__call__(self, nodes, **kw)
(Call operator)

source code 

None <- deleteMol(nodes, **kw)

nodes: TreeNodeSet holding the current selection.

It resets the undo stack automatically.
Overrides: ViewerFramework.VFCommand.Command.__call__