fix up constraintsEvent documentation
This commit is contained in:
parent
fb0b49af8c
commit
454cbaa7cb
10
applet.h
10
applet.h
@ -1003,9 +1003,15 @@ class PLASMA_EXPORT Applet : public QGraphicsWidget
|
|||||||
void showMessage(const QIcon &icon, const QString &message, const Plasma::MessageButtons buttons);
|
void showMessage(const QIcon &icon, const QString &message, const Plasma::MessageButtons buttons);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called when any of the geometry constraints have been updated.
|
* Called when any of the constraints for the applet have been updated. These constraints
|
||||||
|
* range from notifying when the applet has officially "started up" to when geometry changes
|
||||||
|
* to when the form factor changes.
|
||||||
*
|
*
|
||||||
* This is always called prior to painting and should be used as an
|
* Each constraint that has been changed is passed in the constraints flag.
|
||||||
|
* All of the constraints and how they work is documented in the @see Plasma::Constraints
|
||||||
|
* enumeration.
|
||||||
|
*
|
||||||
|
* On applet creation, this is always called prior to painting and can be used as an
|
||||||
* opportunity to layout the widget, calculate sizings, etc.
|
* opportunity to layout the widget, calculate sizings, etc.
|
||||||
*
|
*
|
||||||
* Do not call update() from this method; an update() will be triggered
|
* Do not call update() from this method; an update() will be triggered
|
||||||
|
26
plasma.h
26
plasma.h
@ -42,23 +42,15 @@ namespace Plasma
|
|||||||
* for instance in Applet::constraintsUpdated
|
* for instance in Applet::constraintsUpdated
|
||||||
*/
|
*/
|
||||||
enum Constraint {
|
enum Constraint {
|
||||||
NoConstraint = 0,
|
NoConstraint = 0, /**< No constraint; never passed in to Applet::constraintsEvent on its own */
|
||||||
/** The FormFactor for an object */
|
FormFactorConstraint = 1, /**< The FormFactor for an object */
|
||||||
FormFactorConstraint = 1,
|
LocationConstraint = 2, /**< The Location of an object */
|
||||||
/** The Location of an object */
|
ScreenConstraint = 4, /**< Which screen an object is on */
|
||||||
LocationConstraint = 2,
|
SizeConstraint = 8, /**< the size of the applet was changed */
|
||||||
/** Which screen an object is on */
|
ImmutableConstraint = 16, /**< the immutability (locked) nature of the applet changed */
|
||||||
ScreenConstraint = 4,
|
StartupCompletedConstraint = 32, /**< application startup has completed */
|
||||||
/** the size of the applet was changed */
|
ContextConstraint = 64, /**< the context (e.g. activity) has changed */
|
||||||
SizeConstraint = 8,
|
PopupConstraint = 128, /**< the position of the popup needs to be recalculated*/
|
||||||
/** the immutability (locked) nature of the applet changed */
|
|
||||||
ImmutableConstraint = 16,
|
|
||||||
/** application startup has completed */
|
|
||||||
StartupCompletedConstraint = 32,
|
|
||||||
/** the desktop context has changed */
|
|
||||||
ContextConstraint = 64,
|
|
||||||
/** the position of the popup needs to be recalculated*/
|
|
||||||
PopupConstraint = 128,
|
|
||||||
AllConstraints = FormFactorConstraint | LocationConstraint | ScreenConstraint |
|
AllConstraints = FormFactorConstraint | LocationConstraint | ScreenConstraint |
|
||||||
SizeConstraint | ImmutableConstraint | ContextConstraint | PopupConstraint
|
SizeConstraint | ImmutableConstraint | ContextConstraint | PopupConstraint
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user