Skip to content
Browse files

[Plugin Installer] Simplify plugin reloading

  • Loading branch information
borysiasty committed Jun 25, 2013
1 parent 6cfe4a5 commit fd2b221e6541c1850d7fb8b9037e13c73b9dc785
Showing with 6 additions and 4 deletions.
  1. +6 −4 python/pyplugin_installer/
@@ -320,11 +320,13 @@ def installPlugin(self, key, quiet=False):
settings = QSettings()
settings.setValue("/PythonPlugins/"+plugin["id"], True)
infoString = ("Plugin reinstalled successfully"),"Plugin reinstalled successfully"))
settings = QSettings()
if settings.value("/PythonPlugins/"+key, False, type=bool): # plugin will be reloaded on the fly only if currently loaded
infoString = ("Plugin reinstalled successfully"),"Plugin reinstalled successfully"))
else: infoString = ("Plugin reinstalled successfully"),"Python plugin reinstalled.\nYou need to restart QGIS in order to reload it."))
if settings.value("/PythonPlugins/"+key, False, type=bool):
reloadPlugin(key) # unloadPlugin + loadPlugin + startPlugin
unloadPlugin(key) # Just for a case. Will exit quietly if really not loaded
if quiet:
infoString = (None, None)

0 comments on commit fd2b221

Please sign in to comment.
You can’t perform that action at this time.