Thanks for your help but I can't get it working. It's my lack of
knowledge in Python programming that is the main problem.
I can't figure out how to return 'items', how does this list look like?
I've tried serveral ways but this is, basically, what I want:
class PluginInterface(plugin.MainMenuPlugin):
def items(self, parent):
items = []
items.append(MenuItem('Grab todays Dilbert strip',
self.get_strip1))
return [ items ]
def get_strip1(self, arg=None, menuw=None):
self.get_strip(1)
---------------
It fails with: AttributeError: 'list' object has no attribute 'image'
/Bjorn
--- Dirk Meyer <[EMAIL PROTECTED]> skrev: > Jortan wrote:
> > What I meant was that I want the menu items to appear in
> Images-section
> > when entering from Main menu, just like Webradio appears when
> entering
> > Music section from Main menu. Webradio plugin is defined as 'class
> > PluginInterface(plugin.MainMenuPlugin)' so I guess my plugin should
> not
> > be an item plugin. But as I mentioned the Webradio plugin is too
> > complicated for me to follow.
>
> Ah, ok. Yes, it's a MenuMenu plugin. If you put a MenuMenu plugin
> into
> images/plugins, it will show itself in the Image Main Menu.
>
> You don't return actions() here, you return a list items(). This is
> something which inherits from Item (item.py). Webradio is more
> complex
> because it adds a menu with a submenu and so on. A very simple
> example
> is images/plugins/camera.py. It returns a DirItem (directory) when a
> given usb device is plugged in. Or you look at
> video/plugins/linkbrowser. The class at the end is the
> PluginInterface. And it uses a menu based on Link (the second class
> in
> this file, inherits from Item).
>
>
> Dischi
>
>
> --
> "Programming today is a race between software engineers striving to
> build
> bigger and better idiot-proof programs, and the Universe trying to
> produce
> bigger and better idiots. So far, the Universe is winning." - Rich
> Cook
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: SF.net Giveback Program.
> SourceForge.net hosts over 70,000 Open Source Projects.
> See the people who have HELPED US provide better services:
> Click here: http://sourceforge.net/supporters.php
> _______________________________________________
> Freevo-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/freevo-users
H�strusk och gr� moln - k�p en resa till solen p� Yahoo! Resor p� adressen
http://se.docs.yahoo.com/travel/index.html
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
_______________________________________________
Freevo-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-users