Add unittests for building menus, fixing some errors
This commit is contained in:
parent
0ac83639e0
commit
e26f04d573
3 changed files with 916 additions and 636 deletions
|
|
@ -586,11 +586,9 @@ class CmdSetHandler(object):
|
|||
"""
|
||||
if callable(cmdset) and hasattr(cmdset, 'path'):
|
||||
# try it as a callable
|
||||
print "Try callable", cmdset
|
||||
if must_be_default:
|
||||
return self.cmdset_stack and (self.cmdset_stack[0].path == cmdset.path)
|
||||
else:
|
||||
print [cset.path for cset in self.cmdset_stack], cmdset.path
|
||||
return any([cset for cset in self.cmdset_stack
|
||||
if cset.path == cmdset.path])
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue