remove appletMimeType()
addContainment becomes createContainment
This commit is contained in:
parent
f4de55af67
commit
585c1ec21e
@ -42,7 +42,7 @@ PlasmaKPartCorona::PlasmaKPartCorona(QObject *parent)
|
|||||||
void PlasmaKPartCorona::loadDefaultLayout()
|
void PlasmaKPartCorona::loadDefaultLayout()
|
||||||
{
|
{
|
||||||
// used to force a save into the config file
|
// used to force a save into the config file
|
||||||
Plasma::Containment *c = addContainment(QString());
|
Plasma::Containment *c = createContainment(QString());
|
||||||
|
|
||||||
if (!c) {
|
if (!c) {
|
||||||
// do some error reporting?
|
// do some error reporting?
|
||||||
|
@ -75,16 +75,6 @@ Plasma::Package Corona::package() const
|
|||||||
return d->package;
|
return d->package;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Corona::setAppletMimeType(const QString &type)
|
|
||||||
{
|
|
||||||
d->mimetype = type;
|
|
||||||
}
|
|
||||||
|
|
||||||
QString Corona::appletMimeType()
|
|
||||||
{
|
|
||||||
return d->mimetype;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Corona::setDefaultContainmentPlugin(const QString &name)
|
void Corona::setDefaultContainmentPlugin(const QString &name)
|
||||||
{
|
{
|
||||||
// we could check if it is in:
|
// we could check if it is in:
|
||||||
@ -257,7 +247,7 @@ KSharedConfigPtr Corona::config() const
|
|||||||
return d->config;
|
return d->config;
|
||||||
}
|
}
|
||||||
|
|
||||||
Containment *Corona::addContainment(const QString &name, const QVariantList &args)
|
Containment *Corona::createContainment(const QString &name, const QVariantList &args)
|
||||||
{
|
{
|
||||||
if (d->immutability == Mutable) {
|
if (d->immutability == Mutable) {
|
||||||
return d->addContainment(name, args, 0);
|
return d->addContainment(name, args, 0);
|
||||||
@ -396,7 +386,6 @@ QHash<QString, QString> Corona::defaultContainmentActionsPlugins(ContainmentType
|
|||||||
CoronaPrivate::CoronaPrivate(Corona *corona)
|
CoronaPrivate::CoronaPrivate(Corona *corona)
|
||||||
: q(corona),
|
: q(corona),
|
||||||
immutability(Mutable),
|
immutability(Mutable),
|
||||||
mimetype("text/x-plasmoidservicename"),
|
|
||||||
defaultContainmentPlugin("desktop"),
|
defaultContainmentPlugin("desktop"),
|
||||||
config(0),
|
config(0),
|
||||||
configSyncTimer(new QTimer(corona)),
|
configSyncTimer(new QTimer(corona)),
|
||||||
|
@ -61,17 +61,6 @@ public:
|
|||||||
**/
|
**/
|
||||||
Plasma::Package package() const;
|
Plasma::Package package() const;
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the mimetype of Drag/Drop items. Default is
|
|
||||||
* text/x-plasmoidservicename
|
|
||||||
*/
|
|
||||||
void setAppletMimeType(const QString &mimetype);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The current mime type of Drag/Drop items.
|
|
||||||
*/
|
|
||||||
QString appletMimeType();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return the default containment plugin type
|
* @return the default containment plugin type
|
||||||
* @since 4.7
|
* @since 4.7
|
||||||
@ -103,7 +92,7 @@ public:
|
|||||||
* when widgets are locked, or if the requested containment plugin can not be located
|
* when widgets are locked, or if the requested containment plugin can not be located
|
||||||
* or successfully loaded.
|
* or successfully loaded.
|
||||||
*/
|
*/
|
||||||
Containment *addContainment(const QString &name, const QVariantList &args = QVariantList());
|
Containment *createContainment(const QString &name, const QVariantList &args = QVariantList());
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the Containment, if any, for a given physical screen and desktop
|
* Returns the Containment, if any, for a given physical screen and desktop
|
||||||
|
@ -56,7 +56,6 @@ public:
|
|||||||
Corona *q;
|
Corona *q;
|
||||||
Package package;
|
Package package;
|
||||||
ImmutabilityType immutability;
|
ImmutabilityType immutability;
|
||||||
QString mimetype;
|
|
||||||
QString configName;
|
QString configName;
|
||||||
QString defaultContainmentPlugin;
|
QString defaultContainmentPlugin;
|
||||||
KSharedConfigPtr config;
|
KSharedConfigPtr config;
|
||||||
|
@ -53,7 +53,7 @@ DesktopCorona::~DesktopCorona()
|
|||||||
|
|
||||||
void DesktopCorona::loadDefaultLayout()
|
void DesktopCorona::loadDefaultLayout()
|
||||||
{
|
{
|
||||||
Plasma::Containment *cont = addContainment("org.kde.testcontainment");
|
Plasma::Containment *cont = createContainment("org.kde.testcontainment");
|
||||||
cont->setScreen(0);
|
cont->setScreen(0);
|
||||||
qDebug() << containmentForScreen(0);
|
qDebug() << containmentForScreen(0);
|
||||||
Plasma::Applet *appl = cont->createApplet("org.kde.testapplet");
|
Plasma::Applet *appl = cont->createApplet("org.kde.testapplet");
|
||||||
@ -118,7 +118,7 @@ void DesktopCorona::checkDesktop(/*Activity *activity,*/ bool signalWhenExists,
|
|||||||
|
|
||||||
//TODO: remove following when activities are restored
|
//TODO: remove following when activities are restored
|
||||||
if (!c) {
|
if (!c) {
|
||||||
c = addContainment("desktop");
|
c = createContainment("desktop");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!c) {
|
if (!c) {
|
||||||
|
Loading…
Reference in New Issue
Block a user