Beispiel #1
0
def openNoiseFX(dock=False, rebuild=False):
    """Opens the noiseFX UI
     Args:
        dock (bool): If the UI should be docked
        rebuild (bool): If the UI is rebuilt when opened
    """
    fxType = "material-space"
    mnpr_system.check()
    print("Opening noiseFX with dock = {0}".format(dock))
    windowObj = mnpr_FX.MNPR_FX_UI(dock=dock, rebuild=rebuild, tab=fxType)

    # change tab
    ptr = omUI.MQtUtil.findWindow(windowObj.windowTitle)  # pointer to main window
    window = wrapInstance(long(ptr), QtWidgets.QWidget)  # wrapper
    tabWidget = window.findChildren(QtWidgets.QTabWidget)
    tabWidget[0].setCurrentIndex(0)
Beispiel #2
0
def openPaintFX(dock=False, rebuild=False):
    """Opens the paintFX UI
     Args:
        dock (bool): If the UI should be docked
        rebuild (bool): If the UI is rebuilt when opened
    """
    fxType = "vertex-space"
    mnpr_system.check()
    # temporary workaround to painting ceasing to work correctly
    if rebuild:
        reload(mnpr_FX)
    print("Opening paintFX with dock = {0}".format(dock))
    windowObj = mnpr_FX.MNPR_FX_UI(dock=dock, rebuild=rebuild, tab=fxType)

    # change tab
    ptr = omUI.MQtUtil.findWindow(windowObj.windowTitle)  # pointer to main window
    window = wrapInstance(long(ptr), QtWidgets.QWidget)  # wrapper
    tabWidget = window.findChildren(QtWidgets.QTabWidget)
    tabWidget[0].setCurrentIndex(1)