Opened 8 years ago

Last modified 3 months ago

#2454 new feature-request

Plugin frame work only allows script resources, no CSS or images

Reported by: amain Owned by:
Priority: minor Milestone: 2.1.0
Component: Web UI Version: 1.3.6
Keywords: Cc:


It is not possible, or unclear how, to register image resources within a plugin. Script resources are added by:

class WebUI(WebPluginBase?):

scripts = [get_resource("<my-js-resource>.js")]

def enable(self):


def disable(self):


It be great if plugins would be allowed to register image sources. Image resources can be used for example in the torrent drop-down menu. At the moment all torrent drop-down menu internal items have an nice icon associated. Items added by plugins don't.

Change History (6)

comment:1 Changed 8 years ago by amain

  • Version changed from other (please specify) to 1.3.6

comment:2 Changed 7 years ago by amain

A response is appreciated.

comment:3 Changed 5 years ago by Cas

  • Milestone changed from Future to 2.0

I've not tested this but it is possible from within a plugin WebUI class to access the existing components the same way that the scripts are added:

from deluge import component
icons = component.get('Icons')
css = component.get('Css')

I'll see about getting that code added to pluginmanager

comment:4 Changed 4 years ago by Cas

  • Milestone changed from 2.0 to 2.0.0

Milestone renamed

comment:5 Changed 3 years ago by Cas

  • Milestone changed from 2.0.0 to 2.1.x

Ticket retargeted after milestone closed

comment:6 Changed 3 months ago by Cas

  • Milestone changed from 2.1.x to 2.1.0

Milestone renamed

Note: See TracTickets for help on using tickets.