Plasma::AspectRatioMode, just like Qt::AspectRatioMode. the setter/getter in Applet even used Mode.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=802866
This commit is contained in:
parent
ef45e56b8c
commit
43e6bac986
@ -761,12 +761,12 @@ Location Applet::location() const
|
|||||||
return c ? c->d->location : Plasma::Desktop;
|
return c ? c->d->location : Plasma::Desktop;
|
||||||
}
|
}
|
||||||
|
|
||||||
Plasma::AspectRatio Applet::aspectRatioMode() const
|
Plasma::AspectRatioMode Applet::aspectRatioMode() const
|
||||||
{
|
{
|
||||||
return d->aspectRatioMode;
|
return d->aspectRatioMode;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Applet::setAspectRatioMode(Plasma::AspectRatio mode)
|
void Applet::setAspectRatioMode(Plasma::AspectRatioMode mode)
|
||||||
{
|
{
|
||||||
d->aspectRatioMode = mode;
|
d->aspectRatioMode = mode;
|
||||||
}
|
}
|
||||||
@ -1183,7 +1183,7 @@ Applet::Private::Private(KService::Ptr service, int uniqueID, Applet *applet)
|
|||||||
cachedBackground(0),
|
cachedBackground(0),
|
||||||
mainConfig(0),
|
mainConfig(0),
|
||||||
pendingConstraints(NoConstraint),
|
pendingConstraints(NoConstraint),
|
||||||
aspectRatioMode(Qt::KeepAspectRatio),
|
aspectRatioMode(Plasma::KeepAspectRatio),
|
||||||
immutability(NotImmutable),
|
immutability(NotImmutable),
|
||||||
hasConfigurationInterface(false),
|
hasConfigurationInterface(false),
|
||||||
failed(false),
|
failed(false),
|
||||||
|
4
applet.h
4
applet.h
@ -222,12 +222,12 @@ class PLASMA_EXPORT Applet : public QGraphicsWidget
|
|||||||
/**
|
/**
|
||||||
* @return the prefered aspect ratio mode for placement and resizing
|
* @return the prefered aspect ratio mode for placement and resizing
|
||||||
*/
|
*/
|
||||||
Plasma::AspectRatio aspectRatioMode() const;
|
Plasma::AspectRatioMode aspectRatioMode() const;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the prefered aspect ratio mode for placement and resizing
|
* Sets the prefered aspect ratio mode for placement and resizing
|
||||||
*/
|
*/
|
||||||
void setAspectRatioMode(Plasma::AspectRatio);
|
void setAspectRatioMode(Plasma::AspectRatioMode);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a list of all known applets.
|
* Returns a list of all known applets.
|
||||||
|
12
plasma.h
12
plasma.h
@ -146,18 +146,18 @@ enum ItemTypes { AppletType = QGraphicsItem::UserType + 1,
|
|||||||
* Defines the immutability of items like applets, corona and containments
|
* Defines the immutability of items like applets, corona and containments
|
||||||
* they can be free to modify, locked down by the user or locked down by the system (e.g. kiosk setups)
|
* they can be free to modify, locked down by the user or locked down by the system (e.g. kiosk setups)
|
||||||
*/
|
*/
|
||||||
enum ImmutabilityType { NotImmutable = 1 /**The item can be modified in any way **/,
|
enum ImmutabilityType { NotImmutable = 1 /**< The item can be modified in any way **/,
|
||||||
UserImmutable = 2 /**The user has requested a lock down, and can undo the lock down at any time **/,
|
UserImmutable = 2 /**< The user has requested a lock down, and can undo the lock down at any time **/,
|
||||||
SystemImmutable = 4 /** the item is locked down by the system, the user can't unlock it **/
|
SystemImmutable = 4 /**< the item is locked down by the system, the user can't unlock it **/
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Defines the aspect ratio used when scaling an applet
|
* Defines the aspect ratio used when scaling an applet
|
||||||
*/
|
*/
|
||||||
enum AspectRatio { IgnoreAspectRatio = 0 /** The applet can be freely resized */,
|
enum AspectRatioMode { IgnoreAspectRatio = 0 /**< The applet can be freely resized */,
|
||||||
KeepAspectRatio = 1 /** The applet keeps a fixed aspect ratio */,
|
KeepAspectRatio = 1 /**< The applet keeps a fixed aspect ratio */,
|
||||||
Square = 2 /** The applet is always a square */
|
Square = 2 /**< The applet is always a square */
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user