def delete(self, index1, index2=None):
	print self._tclCommands
	if index2 is None:
	    index2 = index1
	# First find out what entries have defined commands.
	cmds = []
	for i in range(self.index(index1), self.index(index2)+1):
	    c = str(self.entrycget(i, 'command'))
	    if c in self._tclCommands:
		# I don't want to delete the command already, since it
		# seems mystical to do that while the entry is not yet deleted.
		cmds.append(c)
	# Delete the menu entries.
	self.tk.call(self._w, 'delete', index1, index2)
	# Now that the menu entries have been deleted, we can delete their commands.
	for c in cmds:
	    self.deletecommand(c)
Returns a dictionary of namespaces to be exported with an XML
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/guppy-0.1.10/guppy/heapy/test/test_menuleak.py/FixedMenu.delete--crossover with--dataset/ETHPy150Open STIXProject/python-stix/stix/utils/nsparser.py/NamespaceInfo._finalize_namespaces