Hi,

im trying to add a Submenu to a Context Menu of my Plasmoid - but i'm
failing.
Below is the Code for adding 2 Items to the Context Menu:

def contextualActions(self):
            menu=[]
            a = QAction(KIcon(self.package().path() +
"contents/icons/show.svg"), "item1", self)
            b = QAction(KIcon(self.package().path() +
"contents/icons/show.svg"), "item2", self)
            menu.append(a)
            menu.append(b)

            return menu


but how can i add a Submenu so that one item in the menu is a menu in
itself ?

Thanks for any help in advance.
_______________________________________________
PyQt mailing list    [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to