extragear/multimedia/amarok/src/context

Leo Franchi lfranchi at kde.org
Tue Nov 11 12:38:47 CET 2008


SVN commit 882728 by lfranchi:

switch out plasma servicetypes to AmarokContext/ servicetypes. this prevents any conflict with plasma, and allows us to install our own .desktop files without fear of overwriting a user's plasma ones and breaking their installation.

i tested by removing all my plasma files and installing, and it seems to work. but i don't have plasma here so i can't be 100% sure that it won't mess it up (it shouldn't touch it though).

CCMAIL: amarok-devel at kde.org

 M  +1 -1      applets/albums/amarok-context-applet-albums.desktop  
 M  +1 -1      applets/currenttrack/amarok-context-applet-currenttrack.desktop  
 M  +1 -1      applets/lastfmevents/amarok-context-applet-lastfmevents.desktop  
 M  +1 -1      applets/lyrics/amarok-context-applet-lyrics.desktop  
 M  +1 -1      applets/mediadevices/amarok-context-applet-mediadevices.desktop  
 M  +1 -1      applets/playlistinfo/amarok-context-applet-playlistinfo.desktop  
 M  +1 -1      applets/serviceinfo/amarok-context-applet-serviceinfo.desktop  
 M  +1 -1      applets/video/amarok-context-applet-video.desktop  
 M  +1 -1      applets/wikipedia/amarok-context-applet-wikipedia.desktop  
 M  +1 -1      containments/amarok-containment-context.desktop  
 M  +1 -1      engines/cloud/amarok-data-engine-cloud.desktop  
 M  +1 -1      engines/current/amarok-data-engine-current.desktop  
 M  +1 -1      engines/lastfm/amarok-data-engine-lastfm.desktop  
 M  +1 -1      engines/lyrics/amarok-data-engine-lyrics.desktop  
 M  +1 -1      engines/service/amarok-data-engine-service.desktop  
 M  +1 -1      engines/wikipedia/amarok-data-engine-wikipedia.desktop  
 M  +1 -1      plasma/animator.cpp  
 M  +6 -6      plasma/applet.cpp  
 M  +2 -2      plasma/containment.cpp  
 M  +2 -2      plasma/dataenginemanager.cpp  
 M  +1 -1      plasma/package.cpp  
 M  +3 -3      plasma/tests/packagemetadatatest.cpp  
 M  +1 -1      plasma/tests/packagemetadatatest.desktop  
 M  +1 -1      servicetypes/amarok_animator.desktop  
 D             servicetypes/plasma-animator.desktop   [TRAILING SPACE]
 D             servicetypes/plasma-applet.desktop  
 D             servicetypes/plasma-containment.desktop   [TRAILING SPACE]
 D             servicetypes/plasma-dataengine.desktop  


--- trunk/extragear/multimedia/amarok/src/context/applets/albums/amarok-context-applet-albums.desktop #882727:882728
@@ -25,7 +25,7 @@
 Name[x-test]=xxAlbumsxx
 Name[zh_CN]=专辑
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_albums
 X-KDE-PluginInfo-Author=Seb Ruiz
--- trunk/extragear/multimedia/amarok/src/context/applets/currenttrack/amarok-context-applet-currenttrack.desktop #882727:882728
@@ -32,7 +32,7 @@
 Name[x-test]=xxCurrent Track Infoxx
 Name[zh_CN]=当前音轨信息
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_currenttrack
 X-KDE-PluginInfo-Author=Leo Franchi
--- trunk/extragear/multimedia/amarok/src/context/applets/lastfmevents/amarok-context-applet-lastfmevents.desktop #882727:882728
@@ -33,7 +33,7 @@
 Name[x-test]=xxLast.Fm Eventsxx
 Name[zh_CN]=Last.Fm 事件
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_lastfmevents
 X-KDE-PluginInfo-Author=Leo Franchi
--- trunk/extragear/multimedia/amarok/src/context/applets/lyrics/amarok-context-applet-lyrics.desktop #882727:882728
@@ -32,7 +32,7 @@
 Name[x-test]=xxLyrics Appletxx
 Name[zh_CN]=Lyrics 小程序
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_lyrics
 X-KDE-PluginInfo-Author=Leo Franchi
--- trunk/extragear/multimedia/amarok/src/context/applets/mediadevices/amarok-context-applet-mediadevices.desktop #882727:882728
@@ -24,7 +24,7 @@
 Name[x-test]=xxMedia Devicesxx
 Name[zh_CN]=媒体设备
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_mediadevices
 X-KDE-PluginInfo-Author=Alejandro Wainzinger
--- trunk/extragear/multimedia/amarok/src/context/applets/playlistinfo/amarok-context-applet-playlistinfo.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[x-test]=xxPlaylist Informationxx
 Name[zh_CN]=播放列表信息
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_playlistinfo
 X-KDE-PluginInfo-Author=Jeff Mitchell
--- trunk/extragear/multimedia/amarok/src/context/applets/serviceinfo/amarok-context-applet-serviceinfo.desktop #882727:882728
@@ -31,7 +31,7 @@
 Name[x-test]=xxService Infoxx
 Name[zh_CN]=服务信息
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_serviceinfo
 X-KDE-PluginInfo-Author=Nikolaj Hald Nielsen
--- trunk/extragear/multimedia/amarok/src/context/applets/video/amarok-context-applet-video.desktop #882727:882728
@@ -17,7 +17,7 @@
 Name[x-test]=xxVideoxx
 Name[zh_CN]=视频
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_video
 X-KDE-PluginInfo-Author=Mark Kretschmann
--- trunk/extragear/multimedia/amarok/src/context/applets/wikipedia/amarok-context-applet-wikipedia.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[x-test]=xxWikipedia Appletxx
 Name[zh_CN]=维基百科小程序
 Type=Service
-ServiceTypes=Plasma/Applet
+ServiceTypes=AmarokContext/Applet
 
 X-KDE-Library=amarok_context_applet_wikipedia
 X-KDE-PluginInfo-Author=Leo Franchi
--- trunk/extragear/multimedia/amarok/src/context/containments/amarok-containment-context.desktop #882727:882728
@@ -58,7 +58,7 @@
 Comment[zh_CN]=Amarok 上下文容器
 Icon=
 Type=Service
-ServiceTypes=Plasma/Applet,Plasma/Containment
+ServiceTypes=AmarokContext/Applet,AmarokContext/Containment
 
 X-KDE-Library=amarok_containment_context
 X-KDE-PluginInfo-Author=Leo Franchi
--- trunk/extragear/multimedia/amarok/src/context/engines/cloud/amarok-data-engine-cloud.desktop #882727:882728
@@ -26,7 +26,7 @@
 Name[uk]=Рушій даних Cloud
 Name[x-test]=xxCloud Data Enginexx
 Name[zh_CN]=Cloud 数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=amarok
 X-KDE-Library=amarok_data_engine_cloud
--- trunk/extragear/multimedia/amarok/src/context/engines/current/amarok-data-engine-current.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[uk]=Поточний рушій інформаційних даних
 Name[x-test]=xxCurrent Info Data Enginexx
 Name[zh_CN]=当前信息数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=amarok
 X-KDE-Library=amarok_data_engine_current
--- trunk/extragear/multimedia/amarok/src/context/engines/lastfm/amarok-data-engine-lastfm.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[uk]=Рушій даних LastFM
 Name[x-test]=xxLastFM Data Enginexx
 Name[zh_CN]=LastFM 数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=lastfm
 X-KDE-Library=amarok_data_engine_lastfm
--- trunk/extragear/multimedia/amarok/src/context/engines/lyrics/amarok-data-engine-lyrics.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[uk]=Рушій даних слів пісень
 Name[x-test]=xxLyrics Data Enginexx
 Name[zh_CN]=Lyrics 数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=lyrics
 X-KDE-Library=amarok_data_engine_lyrics
--- trunk/extragear/multimedia/amarok/src/context/engines/service/amarok-data-engine-service.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[uk]=Рушій даних службової інформації
 Name[x-test]=xxService Info Data Enginexx
 Name[zh_CN]=服务信息数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=amarok
 X-KDE-Library=amarok_data_engine_service
--- trunk/extragear/multimedia/amarok/src/context/engines/wikipedia/amarok-data-engine-wikipedia.desktop #882727:882728
@@ -30,7 +30,7 @@
 Name[uk]=Рушій даних Wikipedia
 Name[x-test]=xxWikipedia Data Enginexx
 Name[zh_CN]=维基百科数据引擎
-X-KDE-ServiceTypes=Plasma/DataEngine
+X-KDE-ServiceTypes=AmarokContext/DataEngine
 Type=Service
 Icon=wikipedia
 X-KDE-Library=amarok_data_engine_wikipedia
--- trunk/extragear/multimedia/amarok/src/context/plasma/animator.cpp #882727:882728
@@ -701,7 +701,7 @@
 
     if (!pluginName.isEmpty()) {
         QString constraint = QString("[X-KDE-PluginInfo-Name] == '%1'").arg(pluginName);
-        KService::List offers = KServiceTypeTrader::self()->query("Plasma/Animator", constraint);
+        KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Animator", constraint);
 
         if (!offers.isEmpty()) {
             QString error;
--- trunk/extragear/multimedia/amarok/src/context/plasma/applet.cpp #882727:882728
@@ -606,7 +606,7 @@
     }
 
     QString constraint = QString("[X-KDE-PluginInfo-Name] == '%1'").arg(appletName);
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Applet", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Applet", constraint);
 
     if (offers.isEmpty()) {
         return QString();
@@ -1371,7 +1371,7 @@
         }
     }
 
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Applet", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Applet", constraint);
     //kDebug() << "Applet::listAppletInfo constraint was '" << constraint
     //         << "' which got us " << offers.count() << " matches";
     return KPluginInfo::fromServices(offers);
@@ -1381,7 +1381,7 @@
 {
     QString constraint = QString("'%1' in [X-Plasma-DropMimeTypes]").arg(mimetype);
     //kDebug() << "listAppletInfoForMimetype with" << mimetype << constraint;
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Applet", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Applet", constraint);
     return KPluginInfo::fromServices(offers);
 }
 
@@ -1395,7 +1395,7 @@
         constraint.append(" and [X-KDE-ParentApp] == '").append(parentApp).append("'");
     }
 
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Applet", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Applet", constraint);
     QStringList categories;
     foreach (const KService::Ptr &applet, offers) {
         QString appletCategory = applet->property("X-KDE-PluginInfo-Category").toString();
@@ -1425,13 +1425,13 @@
     }
 
     QString constraint = QString("[X-KDE-PluginInfo-Name] == '%1'").arg(appletName);
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Applet", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Applet", constraint);
 
     bool isContainment = false;
     if (offers.isEmpty()) {
         //TODO: what would be -really- cool is offer to try and download the applet
         //      from the network at this point
-        offers = KServiceTypeTrader::self()->query("Plasma/Containment", constraint);
+        offers = KServiceTypeTrader::self()->query("AmarokContext/Containment", constraint);
         isContainment = true;
         if (offers.isEmpty()) {
             kDebug() << "offers is empty for " << appletName;
--- trunk/extragear/multimedia/amarok/src/context/plasma/containment.cpp #882727:882728
@@ -823,7 +823,7 @@
         }
     }
 
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Containment", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Containment", constraint);
     //kDebug() << "constraint was" << constraint << "which got us" << offers.count() << "matches";
     return KPluginInfo::fromServices(offers);
 }
@@ -832,7 +832,7 @@
 {
     QString constraint = QString("'%1' in [X-Plasma-DropMimeTypes]").arg(mimetype);
     //kDebug() << mimetype << constraint;
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/Containment", constraint);
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/Containment", constraint);
     return KPluginInfo::fromServices(offers);
 }
 
--- trunk/extragear/multimedia/amarok/src/context/plasma/dataenginemanager.cpp #882727:882728
@@ -118,7 +118,7 @@
 
     // load the engine, add it to the engines
     QString constraint = QString("[X-KDE-PluginInfo-Name] == '%1'").arg(name);
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/DataEngine",
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/DataEngine",
                                                               constraint);
     QString error;
 
@@ -168,7 +168,7 @@
 QStringList DataEngineManager::listAllEngines()
 {
     QStringList engines;
-    KService::List offers = KServiceTypeTrader::self()->query("Plasma/DataEngine");
+    KService::List offers = KServiceTypeTrader::self()->query("AmarokContext/DataEngine");
     foreach (const KService::Ptr &service, offers) {
         QString name = service->property("X-KDE-PluginInfo-Name").toString();
         if (!name.isEmpty()) {
--- trunk/extragear/multimedia/amarok/src/context/plasma/package.cpp #882727:882728
@@ -395,7 +395,7 @@
     KConfigGroup cg = config.desktopGroup();
     const QString type = data.type().isEmpty() ? "Service" : data.type();
     cg.writeEntry("Type", type);
-    const QString serviceTypes = data.serviceType().isNull() ? "Plasma/Applet,Plasma/Containment" : data.serviceType();
+    const QString serviceTypes = data.serviceType().isNull() ? "AmarokContext/Applet,AmarokContext/Containment" : data.serviceType();
     cg.writeEntry("X-KDE-ServiceTypes", serviceTypes);
     cg.writeEntry("X-KDE-PluginInfo-EnabledByDefault", true);
 
--- trunk/extragear/multimedia/amarok/src/context/plasma/tests/packagemetadatatest.cpp #882727:882728
@@ -63,7 +63,7 @@
 
     QCOMPARE(pm->name(), QString("Package metadata test file"));
     QCOMPARE(pm->description(), QString("A test desktop file to test the PackageMetaData class."));
-    QCOMPARE(pm->serviceType(), QString("Plasma/Applet"));
+    QCOMPARE(pm->serviceType(), QString("AmarokContext/Applet"));
     QCOMPARE(pm->author(), QString("Bertjan Broeksema"));
     QCOMPARE(pm->email(), QString("b.broeksema at kdemail.net"));
     QCOMPARE(pm->version(), QString("pre0.1"));
@@ -78,7 +78,7 @@
 {
     pm->setName(QString("Package metadata test file copy"));
     pm->setDescription(QString("Some other fancy test description"));
-    pm->setServiceType(QString("Plasma/Applet"));
+    pm->setServiceType(QString("AmarokContext/Applet"));
     pm->setAuthor(QString("Bertjan Broeksema"));
     pm->setEmail(QString("b.broeksema at kdemail.net"));
     pm->setVersion(QString("pre0.1"));
@@ -94,7 +94,7 @@
 
     QCOMPARE(pm->name(), QString("Package metadata test file copy"));
     QCOMPARE(pm->description(), QString("Some other fancy test description"));
-    QCOMPARE(pm->serviceType(), QString("Plasma/Applet"));
+    QCOMPARE(pm->serviceType(), QString("AmarokContext/Applet"));
     QCOMPARE(pm->author(), QString("Bertjan Broeksema"));
     QCOMPARE(pm->email(), QString("b.broeksema at kdemail.net"));
     QCOMPARE(pm->version(), QString("pre0.1"));
--- trunk/extragear/multimedia/amarok/src/context/plasma/tests/packagemetadatatest.desktop #882727:882728
@@ -96,7 +96,7 @@
 
 Icon=test
 Type=Service
-X-KDE-ServiceTypes=Plasma/Applet
+X-KDE-ServiceTypes=AmarokContext/Applet
 
 X-KDE-Screenshot=a_not_default_file.svg
 X-KDE-Library=some_test_library
--- trunk/extragear/multimedia/amarok/src/context/servicetypes/amarok_animator.desktop #882727:882728
@@ -1,6 +1,6 @@
 [Desktop Entry]
 Type=ServiceType
-X-KDE-ServiceType=Plasma/Animator
+X-KDE-ServiceType=AmarokContext/Animator
 
 Comment=Plasma Animation Engine
 Comment[af]=Plasma animasie-enjin


More information about the Amarok-devel mailing list