get rid of Plasma::FormFactor
This commit is contained in:
parent
ad2fe77745
commit
9b9fbf6eb9
@ -517,7 +517,7 @@ KActionCollection *Applet::actions() const
|
||||
return d->actions;
|
||||
}
|
||||
|
||||
FormFactor Applet::formFactor() const
|
||||
Types::FormFactor Applet::formFactor() const
|
||||
{
|
||||
Containment *c = containment();
|
||||
QObject *pw = qobject_cast<QObject *>(parent());
|
||||
|
@ -138,21 +138,21 @@ class PLASMA_EXPORT Applet : public QObject
|
||||
* @return the status of the applet
|
||||
* @since 4.4
|
||||
*/
|
||||
ItemStatus status() const;
|
||||
Types::ItemStatus status() const;
|
||||
|
||||
/**
|
||||
* Returns the current form factor the applet is being displayed in.
|
||||
*
|
||||
* @see Plasma::FormFactor
|
||||
*/
|
||||
FormFactor formFactor() const;
|
||||
Types::FormFactor formFactor() const;
|
||||
|
||||
/**
|
||||
* Returns the location of the scene which is displaying applet.
|
||||
*
|
||||
* @see Plasma::Location
|
||||
*/
|
||||
Location location() const;
|
||||
Types::Location location() const;
|
||||
|
||||
//CONFIGURATION
|
||||
/**
|
||||
|
@ -178,8 +178,8 @@ void Containment::restore(KConfigGroup &group)
|
||||
return;
|
||||
}
|
||||
|
||||
setLocation((Plasma::Location)group.readEntry("location", (int)d->location));
|
||||
setFormFactor((Plasma::FormFactor)group.readEntry("formfactor", (int)d->formFactor));
|
||||
setLocation((Plasma::Types::Location)group.readEntry("location", (int)d->location));
|
||||
setFormFactor((Plasma::Types::FormFactor)group.readEntry("formfactor", (int)d->formFactor));
|
||||
//kDebug() << "setScreen from restore";
|
||||
d->setScreen(group.readEntry("screen", d->screen));
|
||||
d->activityId = group.readEntry("activityId", QString());
|
||||
@ -310,7 +310,7 @@ Corona *Containment::corona() const
|
||||
return qobject_cast<Corona*>(parent());
|
||||
}
|
||||
|
||||
void Containment::setFormFactor(FormFactor formFactor)
|
||||
void Containment::setFormFactor(Types::FormFactor formFactor)
|
||||
{
|
||||
if (d->formFactor == formFactor) {
|
||||
return;
|
||||
@ -327,7 +327,7 @@ void Containment::setFormFactor(FormFactor formFactor)
|
||||
emit formFactorChanged(formFactor);
|
||||
}
|
||||
|
||||
void Containment::setLocation(Location location)
|
||||
void Containment::setLocation(Types::Location location)
|
||||
{
|
||||
if (d->location == location) {
|
||||
return;
|
||||
|
@ -260,7 +260,7 @@ Q_SIGNALS:
|
||||
* Emitted when the formFactor has changed
|
||||
* @since 5.0
|
||||
*/
|
||||
void formFactorChanged(Plasma::FormFactor formFactor);
|
||||
void formFactorChanged(Plasma::Types::FormFactor formFactor);
|
||||
|
||||
public Q_SLOTS:
|
||||
/**
|
||||
@ -277,7 +277,7 @@ Q_SIGNALS:
|
||||
* the arrangement of Applets as well as the display choices of individual
|
||||
* Applets.
|
||||
*/
|
||||
void setFormFactor(Plasma::FormFactor formFactor);
|
||||
void setFormFactor(Plasma::Types::FormFactor formFactor);
|
||||
|
||||
/**
|
||||
* Sets the type of this containment.
|
||||
|
@ -301,7 +301,7 @@ PLASMA_EXPORT Types::Direction locationToInverseDirection(Types::Location locati
|
||||
//TODO: remove
|
||||
//typedef Types::Constraint Constraint;
|
||||
//Q_DECLARE_FLAGS(Constraints, Constraint)
|
||||
typedef Types::FormFactor FormFactor;
|
||||
//typedef Types::FormFactor FormFactor;
|
||||
typedef Types::ContainmentType ContainmentType;
|
||||
typedef Types::ActionType ActionType;
|
||||
typedef Types::Direction Direction;
|
||||
|
@ -95,8 +95,8 @@ public:
|
||||
static void addDefaultActions(KActionCollection *actions, Containment *c = 0);
|
||||
|
||||
Containment *q;
|
||||
FormFactor formFactor;
|
||||
Location location;
|
||||
Types::FormFactor formFactor;
|
||||
Types::Location location;
|
||||
QList<Applet *> applets;
|
||||
QString wallpaper;
|
||||
QHash<QString, ContainmentActions*> localActionPlugins;
|
||||
|
@ -86,8 +86,8 @@ void Panel::setLocation(const QString &locationString)
|
||||
}
|
||||
|
||||
const QString lower = locationString.toLower();
|
||||
Plasma::Location loc = Plasma::Types::Floating;
|
||||
Plasma::FormFactor ff = Plasma::Types::Planar;
|
||||
Plasma::Types::Location loc = Plasma::Types::Floating;
|
||||
Plasma::Types::FormFactor ff = Plasma::Types::Planar;
|
||||
if (lower == "desktop") {
|
||||
loc = Plasma::Types::Desktop;
|
||||
} else if (lower == "fullscreen") {
|
||||
|
@ -75,8 +75,8 @@ void View::init()
|
||||
|
||||
void View::setContainment(Plasma::Containment *cont)
|
||||
{
|
||||
Plasma::Location oldLoc = (Plasma::Location)location();
|
||||
Plasma::FormFactor oldForm = formFactor();
|
||||
Plasma::Types::Location oldLoc = (Plasma::Types::Location)location();
|
||||
Plasma::Types::FormFactor oldForm = formFactor();
|
||||
|
||||
if (m_containment) {
|
||||
disconnect(m_containment.data(), 0, this, 0);
|
||||
@ -90,7 +90,7 @@ void View::setContainment(Plasma::Containment *cont)
|
||||
m_containment = cont;
|
||||
|
||||
if (oldLoc != location()) {
|
||||
emit locationChanged((Plasma::Location)location());
|
||||
emit locationChanged((Plasma::Types::Location)location());
|
||||
}
|
||||
if (oldForm != formFactor()) {
|
||||
emit formFactorChanged(formFactor());
|
||||
@ -133,7 +133,7 @@ Plasma::Containment *View::containment() const
|
||||
//FIXME: wrong types
|
||||
void View::setLocation(int location)
|
||||
{
|
||||
m_containment.data()->setLocation((Plasma::Location)location);
|
||||
m_containment.data()->setLocation((Plasma::Types::Location)location);
|
||||
}
|
||||
|
||||
//FIXME: wrong types
|
||||
@ -145,7 +145,7 @@ int View::location() const
|
||||
return m_containment.data()->location();
|
||||
}
|
||||
|
||||
Plasma::FormFactor View::formFactor() const
|
||||
Plasma::Types::FormFactor View::formFactor() const
|
||||
{
|
||||
if (!m_containment) {
|
||||
return Plasma::Types::Planar;
|
||||
|
@ -51,7 +51,7 @@ public:
|
||||
int location() const;
|
||||
void setLocation(int location);
|
||||
|
||||
Plasma::FormFactor formFactor() const;
|
||||
Plasma::Types::FormFactor formFactor() const;
|
||||
|
||||
QRectF screenGeometry();
|
||||
|
||||
@ -59,8 +59,8 @@ protected Q_SLOTS:
|
||||
void showConfigurationInterface(Plasma::Applet *applet);
|
||||
|
||||
Q_SIGNALS:
|
||||
void locationChanged(Plasma::Location location);
|
||||
void formFactorChanged(Plasma::FormFactor formFactor);
|
||||
void locationChanged(Plasma::Types::Location location);
|
||||
void formFactorChanged(Plasma::Types::FormFactor formFactor);
|
||||
void containmentChanged();
|
||||
void screenGeometryChanged();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user