Some more fixes for plugins not fetching data from the correct namespace.

This commit is contained in:
Pedro Algarvio 2011-06-04 19:23:03 +01:00
parent 32c95fac1e
commit ee0d757b0e
3 changed files with 9 additions and 4 deletions

View File

@ -92,8 +92,9 @@ class ExecutePreferences(object):
self.plugin.deregister_hook("on_show_prefs", self.load_commands)
def get_resource(self, filename):
return pkg_resources.resource_filename("execute", os.path.join("data",
filename))
return pkg_resources.resource_filename(
"deluge.plugins.execute", os.path.join("data", filename)
)
def add_command(self, command_id, event, command):
log.debug("Adding command `%s`", command_id)

View File

@ -51,7 +51,9 @@ NO_LABEL = "No Label"
def get_resource(filename):
import pkg_resources
import os
return pkg_resources.resource_filename("label", os.path.join("data", filename))
return pkg_resources.resource_filename(
"deluge.plugins.label", os.path.join("data", filename)
)
#menu
class LabelSidebarMenu(object):

View File

@ -150,4 +150,6 @@ class GtkUI(GtkPluginBase):
def get_resource(self, filename):
import pkg_resources, os
return pkg_resources.resource_filename("stats", os.path.join("data", filename))
return pkg_resources.resource_filename(
"deluge.plugins.stats", os.path.join("data", filename)
)