pymel.core.windows.currentMenuParent

currentMenuParent()

shortcut for ui.PyUI(setParent(q=1, menu=1))