Python maya.cmds.unloadPlugin() Examples
The following are 5
code examples of maya.cmds.unloadPlugin().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
maya.cmds
, or try the search function
.
Example #1
Source File: cmdx.py From cmdx with BSD 2-Clause "Simplified" License | 6 votes |
def uninstall(): if ENABLE_UNDO: # Plug-in may exist in undo queue and # therefore cannot be unloaded until flushed. cmds.flushUndo() # Discard shared module shared.undo = None shared.redo = None shared.undos.clear() shared.redos.clear() sys.modules.pop(name, None) cmds.unloadPlugin(os.path.basename(__file__)) self.installed = False
Example #2
Source File: test_util.py From spore with MIT License | 5 votes |
def load_plugin(cls, plugin): if cmds.pluginInfo(plugin, q=True, l=True): cmds.unloadPlugin(plugin) cmds.loadPlugin(plugin, qt=True) cls.plugins.add(plugin)
Example #3
Source File: test_util.py From spore with MIT License | 5 votes |
def unload_plugins(cls): for plugin in cls.plugins: cmds.unloadPlugin(plugin) cls.plugins = set()
Example #4
Source File: utils.py From rush with MIT License | 5 votes |
def reloadRush(): try: cmds.unloadPlugin("Rush.py") cmds.loadPlugin("Rush.py") except Exception: print("Failed to reload plugin")
Example #5
Source File: mayaunittest.py From cmt with MIT License | 5 votes |
def unload_plugins(cls): # Unload any plugins that this test case loaded for plugin in cls.plugins_loaded: cmds.unloadPlugin(plugin) cls.plugins_loaded = []