Bug 202601 - Plasma.PopupApplet not available in python plasmoid
Summary: Plasma.PopupApplet not available in python plasmoid
Status: RESOLVED WORKSFORME
Alias: None
Product: bindings
Classification: Developer tools
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: kde-bindings
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-05 12:25 UTC by Magnus Kulke
Modified: 2023-01-08 05:16 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Magnus Kulke 2009-08-05 12:25:10 UTC
Version:            (using KDE 4.3.0)
OS:                Linux
Installed from:    Ubuntu Packages

There seems to be no way to use Plasma.PopupApplet in python plasmoids right now. 

in "class PythonAppletScript(Plasma.AppletScript):" the applet for the plasmoid is created the following way:

        self.pyapplet = self.module.main.CreateApplet(None)
        self.pyapplet.setApplet(self.applet())
        self.pyapplet.init()

when you put "self.setApplet(MyPopupApplet(None))" in your plasmascript.Applet's "init(self)" method to overwrite the applet, the result is an empty applet.
Comment 1 Thomas Tanghus 2010-12-04 15:36:53 UTC
This works from 4.5 if you put:

ServiceTypes=Plasma/Applet,Plasma/PopupApplet

in metadata.desktop and just construct the Applet as a normal Applet:

from PyKDE4.plasmascript import Applet

class MyPopupApplet(Applet):

  def __init__(self,parent,args=None):
    Applet.__init__(self, parent)

  def init(self):
    self._widget = MyMopupWidget(self) # Some QGraphicsWidget derivative
    self.setGraphicsWidget(self._widget)
    self.setPopupIcon("my-icon")
    self.setGraphicsWidget(self._widget) # for some reason it only works when called twice.


So this should be marked as (almost) fixed and closed.
Comment 2 Andrew Crouthamel 2018-11-05 03:10:09 UTC
Dear Bug Submitter,

This bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? I am setting the status to NEEDSINFO pending your response, please change the Status back to REPORTED when you respond.

Thank you for helping us make KDE software even better for everyone!
Comment 3 Andrew Crouthamel 2018-11-16 05:26:34 UTC
Dear Bug Submitter,

This is a reminder that this bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version?

Thank you for helping us make KDE software even better for everyone!
Comment 4 Justin Zobel 2022-12-09 22:13:19 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 5 Bug Janitor Service 2022-12-24 05:22:51 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 6 Bug Janitor Service 2023-01-08 05:16:07 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!