![]() Registered Member ![]()
|
How can I get signal or property (something like "bool isOnPanel();"), when my plasma applet moved to panel, instead of desktop?
Last edited by RazrFalcon on Wed Jun 08, 2011 9:56 pm, edited 1 time in total.
|
![]() KDE Developer ![]()
|
Reimplement the protected virtual method:
of Plasma::Applet, checking that the "constraints" parameter contain the Plasma::FormFactorConstraint flag; if it does, then the form factor changed, so you can check the new value using formFactor(). See the API documentation of Plasma::Applet and the Plasma namespace.
Pino Toscano
|
![]() Registered Member ![]()
|
Thank you very much. It's works fine.
formFactor() returns "0" when applet are on desktop, and "2" when are on panel. |
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot]