def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)
    _window.show()
def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)
    _window.show()
Exemplo n.º 3
0
def getmainwindow():
    parent = None
    try:
        parent = mayautils.get_maya_window()
    except RuntimeError as error:
        if (error.message != 'No Maya window found.'):
            raise error
    return parent
Exemplo n.º 4
0
def getmainwindow():
    parent = None
    try:
        parent = mayautils.get_maya_window()
    except RuntimeError as error:
        if (error.message != 'No Maya window found.'):
            raise error
    return parent
def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()
        def emit_selchanged(_): #(1)
            cont.selectionChanged.emit(
                pmc.selected(type='transform'))
        OpenMaya.MEventMessage.addEventCallback( #(2)
            'SelectionChanged', emit_selchanged)
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)
    _window.show()
Exemplo n.º 6
0
def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()

        def emit_selchanged(_):  #(1)
            cont.selectionChanged.emit(pmc.selected(type='transform'))

        OpenMaya.MEventMessage.addEventCallback(  #(2)
            'SelectionChanged', emit_selchanged)
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)
    _window.show()
Exemplo n.º 7
0
def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()

        def emit_selchanged(_):
            cont.selectionChanged.emit(pmc.selected(type='transform'))
        OpenMaya.MEventMessage.addEventCallback('SelectionChanged', emit_selchanged)
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)

        def onconvert(prefix):
            settings = dict(charcreator.SETTINGS_DEFAULT, prefix=unicode(prefix))
            charcreator.convert_hierarchies_main(settings)

        _window.convertClicked.connect(onconvert)
    _window.show()
def show():
    global _window
    if _window is None:
        cont = hierconvgui.HierarchyConverterController()

        def emit_selchanged(_):
            cont.selectionChanged.emit(pmc.selected(type='transform'))

        OpenMaya.MEventMessage.addEventCallback('SelectionChanged',
                                                emit_selchanged)
        parent = mayautils.get_maya_window()
        _window = hierconvgui.create_window(cont, parent)

        def onconvert(prefix):  #(2)
            settings = dict(charcreator.SETTINGS_DEFAULT,
                            prefix=unicode(prefix))  #(3)
            charcreator.convert_hierarchies_main(settings)

        _window.convertClicked.connect(onconvert)  #(4)
    _window.show()