mirror of
https://github.com/fergalmoran/picard.git
synced 2026-02-21 15:14:13 +00:00
Display only the plugin file without plugin path in the options. Fixes issues with text wrapping when the path was too long.
This commit is contained in:
@@ -53,8 +53,9 @@ class ExtensionPoint(QtCore.QObject):
|
||||
|
||||
class PluginWrapper(object):
|
||||
|
||||
def __init__(self, module):
|
||||
def __init__(self, module, plugindir):
|
||||
self.module = module
|
||||
self.dir = plugindir
|
||||
|
||||
def __get_name(self):
|
||||
try:
|
||||
@@ -133,7 +134,7 @@ class PluginManager(QtCore.QObject):
|
||||
info = imp.find_module(name, [plugindir])
|
||||
try:
|
||||
plugin_module = imp.load_module('picard.plugins.' + name, *info)
|
||||
plugin = PluginWrapper(plugin_module)
|
||||
plugin = PluginWrapper(plugin_module, plugindir)
|
||||
for version in list(plugin.api_versions):
|
||||
found = False
|
||||
for api_version in picard.api_versions:
|
||||
|
||||
@@ -96,7 +96,7 @@ class PluginsOptionsPage(OptionsPage):
|
||||
author = plugin.author
|
||||
if author:
|
||||
text.append("<b>" + _("Author") + "</b>: " + author)
|
||||
text.append("<b>" + _("File") + "</b>: " + plugin.file)
|
||||
text.append("<b>" + _("File") + "</b>: " + plugin.file[len(plugin.dir)+1:])
|
||||
self.ui.details.setText("<p>%s</p>" % "<br/>\n".join(text))
|
||||
|
||||
def open_plugin_dir(self):
|
||||
|
||||
Reference in New Issue
Block a user