Port plasma code to PLASMA_RELATIVE_DATA_INSTALL_DIR
This commit is contained in:
parent
dfd425ae82
commit
9cd8f9fbeb
@ -26,7 +26,7 @@ LayoutTemplatePackageStructure::LayoutTemplatePackageStructure(QObject *parent)
|
||||
: Plasma::PackageStructure(parent)
|
||||
{
|
||||
setServicePrefix("plasma-layout-template");
|
||||
setDefaultPackageRoot("plasma/layout-templates");
|
||||
setDefaultPackageRoot(PLASMA_RELATIVE_DATA_INSTALL_DIR "/layout-templates");
|
||||
addFileDefinition("mainscript", "layout.js", "Main Script File");
|
||||
setRequired("mainscript", true);
|
||||
}
|
||||
|
@ -224,7 +224,7 @@ void ScriptEngine::exception(const QScriptValue &value)
|
||||
QStringList ScriptEngine::pendingUpdateScripts()
|
||||
{
|
||||
const QString appName = KGlobal::activeComponent().aboutData()->appName();
|
||||
QStringList scripts = KGlobal::dirs()->findAllResources("data", appName + "/plasma/layout/updates/*.js");
|
||||
QStringList scripts = KGlobal::dirs()->findAllResources("data", appName + "PLASMA_RELATIVE_DATA_INSTALL_DIR /layout/updates/*.js");
|
||||
QStringList scriptPaths;
|
||||
|
||||
if (scripts.isEmpty()) {
|
||||
@ -259,7 +259,7 @@ QStringList ScriptEngine::pendingUpdateScripts()
|
||||
QStringList ScriptEngine::defaultLayoutScripts()
|
||||
{
|
||||
const QString appName = KGlobal::activeComponent().aboutData()->appName();
|
||||
QStringList scripts = KGlobal::dirs()->findAllResources("data", appName + "/plasma/layout/init/*.js");
|
||||
QStringList scripts = KGlobal::dirs()->findAllResources("data", appName + PLASMA_RELATIVE_DATA_INSTALL_DIR "/layout/init/*.js");
|
||||
QStringList scriptPaths;
|
||||
|
||||
if (scripts.isEmpty()) {
|
||||
|
@ -779,7 +779,7 @@ KPluginInfo::List PluginLoader::internalContainmentActionsInfo() const
|
||||
static KPluginInfo::List standardInternalInfo(const QString &type, const QString &category = QString())
|
||||
{
|
||||
QStringList files = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation,
|
||||
"plasma/internal/" + type + "/*.desktop",
|
||||
PLASMA_RELATIVE_DATA_INSTALL_DIR "/internal/" + type + "/*.desktop",
|
||||
QStandardPaths::LocateFile);
|
||||
|
||||
KPluginInfo::List allInfo = KPluginInfo::fromFiles(files);
|
||||
|
@ -105,6 +105,8 @@ void ViewPrivate::setContainment(Plasma::Containment *cont)
|
||||
|
||||
QQuickItem *graphicObject = qobject_cast<QQuickItem *>(containment.data()->property("_plasma_graphicObject").value<QObject *>());
|
||||
|
||||
qDebug() << containment.data()->pluginInfo().name();
|
||||
Q_ASSERT(graphicObject);
|
||||
if (graphicObject) {
|
||||
qDebug() << "using as graphic containment" << graphicObject << containment.data();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user