~ubuntu-branches/ubuntu/oneiric/kde-runtime/oneiric-updates

« back to all changes in this revision

Viewing changes to nepomuk/services/storage/test/fakedatamanagementservice.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Philip Muškovac, Romain Perier, Philip Muškovac
  • Date: 2011-07-26 22:28:56 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20110726222856-p4wgvqr2jy03gmac
Tags: 4:4.7.0a-0ubuntu1
[ Romain Perier ]
* Remove dont_show_netattach_outside_kde.diff, applied on upstream
* Refresh kubuntu_nodisplay_knetattach.diff

[ Philip Muškovac ]
* New upstream release
* Bump various breaks/replaces to catch the package version from the
  kubuntu-ppa.

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
#include <KCmdLineArgs>
39
39
#include <KCmdLineOptions>
40
40
 
41
 
#include <Nepomuk/ResourceManager>
42
 
 
43
41
#include <QtDBus>
44
42
 
45
43
#include <signal.h>
93
91
    QDBusConnection::sessionBus().registerObject(QLatin1String("/datamanagement"), m_dmAdaptor, QDBusConnection::ExportScriptableContents);
94
92
 
95
93
    // register the dm model itself - simply to let the test case have access to the updateTypeCachesAndSoOn() method
96
 
    QDBusConnection::sessionBus().registerObject(QLatin1String("/fakedms"), m_dmModel, QDBusConnection::ExportAllSlots);
 
94
    QDBusConnection::sessionBus().registerObject(QLatin1String("/fakedms"), this, QDBusConnection::ExportAllSlots);
97
95
 
98
 
    // register under the service name used by the Nepomuk service stub
99
 
    QDBusConnection::sessionBus().registerService(QLatin1String("org.kde.nepomuk.DataManagement"));
 
96
    // register the service itself
 
97
    QDBusConnection::sessionBus().registerService(QLatin1String("org.kde.nepomuk.FakeDataManagement"));
100
98
 
101
99
    // register our base model via dbus so the test case can access it
102
100
    Soprano::Server::DBusExportModel* dbusModel = new Soprano::Server::DBusExportModel(m_model);
103
101
    dbusModel->setParent(this);
104
102
    dbusModel->registerModel(QLatin1String("/model"));
105
 
 
106
 
    // the resourcemerger still depends on the ResourceManager - this is very bad!
107
 
    ResourceManager::instance()->setOverrideMainModel( m_nrlModel );
108
103
}
109
104
 
110
105
FakeDataManagementService::~FakeDataManagementService()
117
112
}
118
113
 
119
114
 
 
115
void FakeDataManagementService::updateClassAndPropertyTree()
 
116
{
 
117
    m_classAndPropertyTree->rebuildTree(m_model);
 
118
}
 
119
 
 
120
 
120
121
int main( int argc, char** argv )
121
122
{
122
123
    KAboutData aboutData( "fakedms", "fakedms",