fix flowchart context menu redundant menu (#1060)
This commit is contained in:
parent
f2740f7e69
commit
cb4d9b23b2
@ -834,9 +834,9 @@ class FlowchartWidget(dockarea.DockArea):
|
|||||||
def buildMenu(self, pos=None):
|
def buildMenu(self, pos=None):
|
||||||
def buildSubMenu(node, rootMenu, subMenus, pos=None):
|
def buildSubMenu(node, rootMenu, subMenus, pos=None):
|
||||||
for section, node in node.items():
|
for section, node in node.items():
|
||||||
menu = QtGui.QMenu(section)
|
|
||||||
rootMenu.addMenu(menu)
|
|
||||||
if isinstance(node, OrderedDict):
|
if isinstance(node, OrderedDict):
|
||||||
|
menu = QtGui.QMenu(section)
|
||||||
|
rootMenu.addMenu(menu)
|
||||||
buildSubMenu(node, menu, subMenus, pos=pos)
|
buildSubMenu(node, menu, subMenus, pos=pos)
|
||||||
subMenus.append(menu)
|
subMenus.append(menu)
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user