diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2013-01-08 16:49:31 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2013-01-08 16:49:31 +0100 |
commit | 14299bca34712251a215a7d20feecab44426632b (patch) | |
tree | c5786687daf755bb488ca9dbaa156ca45eefe8a5 /src/urlbar | |
parent | Restore Tab Windows when Restoring the Session (diff) | |
download | rekonq-14299bca34712251a215a7d20feecab44426632b.tar.xz |
Revert "Rekonq Migration to Nepomuk2"
This reverts commit 6d2519d373350b5e904fb421d688a665dd42c0c1.
This let rekonq compile again. Nepomuk2 will be added back
when KDE 4.10 will be released.
Diffstat (limited to 'src/urlbar')
-rw-r--r-- | src/urlbar/bookmarkwidget.cpp | 16 | ||||
-rw-r--r-- | src/urlbar/bookmarkwidget.h | 13 | ||||
-rw-r--r-- | src/urlbar/newresourcedialog.cpp | 30 | ||||
-rw-r--r-- | src/urlbar/newresourcedialog.h | 6 | ||||
-rw-r--r-- | src/urlbar/resourcelinkdialog.cpp | 162 | ||||
-rw-r--r-- | src/urlbar/resourcelinkdialog.h | 4 |
6 files changed, 115 insertions, 116 deletions
diff --git a/src/urlbar/bookmarkwidget.cpp b/src/urlbar/bookmarkwidget.cpp index a0e5cd44..e266a071 100644 --- a/src/urlbar/bookmarkwidget.cpp +++ b/src/urlbar/bookmarkwidget.cpp @@ -153,8 +153,8 @@ BookmarkWidget::BookmarkWidget(const KBookmark &bookmark, QWidget *parent) m_tagLine->setPlaceholderText(i18n("add tags(comma separated)")); - QList<Nepomuk2::Tag> tagList = Nepomuk2::Tag::allTags(); - Q_FOREACH(const Nepomuk2::Tag &t, tagList) + QList<Nepomuk::Tag> tagList = Nepomuk::Tag::allTags(); + Q_FOREACH(const Nepomuk::Tag &t, tagList) { m_tList.append(t.label()); } @@ -287,9 +287,9 @@ void BookmarkWidget::removeBookmark() #ifdef HAVE_NEPOMUK -void BookmarkWidget::addTags(QList<Nepomuk2::Tag> tagList) +void BookmarkWidget::addTags(QList<Nepomuk::Tag> tagList) { - Q_FOREACH(const Nepomuk2::Tag & tag, tagList) + Q_FOREACH(const Nepomuk::Tag & tag, tagList) { if (!m_nfoResource.tags().contains(tag)) { @@ -297,7 +297,7 @@ void BookmarkWidget::addTags(QList<Nepomuk2::Tag> tagList) } } - Q_FOREACH(Nepomuk2::Tag tag, m_nfoResource.tags()) + Q_FOREACH(Nepomuk::Tag tag, m_nfoResource.tags()) { if (!tagList.contains(tag)) { @@ -308,7 +308,7 @@ void BookmarkWidget::addTags(QList<Nepomuk2::Tag> tagList) void BookmarkWidget::parseTags() { - QList<Nepomuk2::Tag> tagList; + QList<Nepomuk::Tag> tagList; if (m_tagLine->text().contains(',')) { QString text = m_tagLine->text(); @@ -334,7 +334,7 @@ void BookmarkWidget::loadTags() QString list; if (!m_nfoResource.tags().isEmpty()) { - Q_FOREACH(const Nepomuk2::Tag & tag, m_nfoResource.tags()) + Q_FOREACH(const Nepomuk::Tag & tag, m_nfoResource.tags()) { list.append(tag.genericLabel()); list.append(","); @@ -358,7 +358,7 @@ void BookmarkWidget::addCommentSlot() void BookmarkWidget::linkToResourceSlot() { - QPointer<Nepomuk2::ResourceLinkDialog> r = new Nepomuk2::ResourceLinkDialog(m_nfoResource); + QPointer<Nepomuk::ResourceLinkDialog> r = new Nepomuk::ResourceLinkDialog(m_nfoResource); r->exec(); r->deleteLater(); diff --git a/src/urlbar/bookmarkwidget.h b/src/urlbar/bookmarkwidget.h index e6021c90..39f6fbd4 100644 --- a/src/urlbar/bookmarkwidget.h +++ b/src/urlbar/bookmarkwidget.h @@ -34,11 +34,14 @@ #include <QGridLayout> #include <QPlainTextEdit> +// Nepomuk config include +#include <config-nepomuk.h> + // Nepomuk Includes #ifdef HAVE_NEPOMUK -#include <Nepomuk2/Resource> -#include <Nepomuk2/Tag> -#include <Nepomuk2/Vocabulary/NFO> +#include <Nepomuk/Resource> +#include <Nepomuk/Tag> +#include <Nepomuk/Vocabulary/NFO> #endif // Forward Declarations @@ -58,7 +61,7 @@ public: void showAt(const QPoint &pos); #ifdef HAVE_NEPOMUK - void addTags(QList<Nepomuk2::Tag>); + void addTags(QList<Nepomuk::Tag>); void parseTags(); void loadTags(); #endif @@ -88,7 +91,7 @@ private: QStringList m_tList; #ifdef HAVE_NEPOMUK - Nepomuk2::Resource m_nfoResource; + Nepomuk::Resource m_nfoResource; bool m_isNepomukEnabled; #endif }; diff --git a/src/urlbar/newresourcedialog.cpp b/src/urlbar/newresourcedialog.cpp index 592d1b31..39cffc36 100644 --- a/src/urlbar/newresourcedialog.cpp +++ b/src/urlbar/newresourcedialog.cpp @@ -29,10 +29,10 @@ #include "newresourcedialog.moc" // Nepomuk Includes -#include <Nepomuk2/Vocabulary/NCO> -#include <Nepomuk2/Vocabulary/PIMO> -#include <Nepomuk2/Resource> -#include <Nepomuk2/Tag> +#include <Nepomuk/Vocabulary/NCO> +#include <Nepomuk/Vocabulary/PIMO> +#include <Nepomuk/Resource> +#include <Nepomuk/Tag> // Qt Includes #include <QPlainTextEdit> @@ -40,20 +40,20 @@ #include <QLabel> -class Nepomuk2::NewResourceDialog::Private +class Nepomuk::NewResourceDialog::Private { public: KLineEdit *m_resourceName; QPlainTextEdit *m_description; QLabel *m_titleResource; QLabel *m_desResource; - Nepomuk2::NewResourceDialog *q; - Nepomuk2::Resource m_nofResource; + Nepomuk::NewResourceDialog *q; + Nepomuk::Resource m_nofResource; int m_index; }; -Nepomuk2::NewResourceDialog::NewResourceDialog(int index, Nepomuk2::Resource& nfoResource, QWidget* parent): +Nepomuk::NewResourceDialog::NewResourceDialog(int index, Nepomuk::Resource& nfoResource, QWidget* parent): KDialog(parent), d(new Private()) { @@ -80,41 +80,41 @@ Nepomuk2::NewResourceDialog::NewResourceDialog(int index, Nepomuk2::Resource& nf } -Nepomuk2::NewResourceDialog::~NewResourceDialog() +Nepomuk::NewResourceDialog::~NewResourceDialog() { delete d; } -void Nepomuk2::NewResourceDialog::newResourceSlot() +void Nepomuk::NewResourceDialog::newResourceSlot() { if (d->m_index == 1) { - Nepomuk2::Resource newResource(d->m_resourceName->text(), Nepomuk2::Vocabulary::PIMO::Person()); + Nepomuk::Resource newResource(d->m_resourceName->text(), Nepomuk::Vocabulary::PIMO::Person()); newResource.addSymbol("user-identity"); d->m_nofResource.addIsRelated(newResource); } else if (d->m_index == 2) { - Nepomuk2::Resource newResource(d->m_resourceName->text(), Nepomuk2::Vocabulary::PIMO::Project()); + Nepomuk::Resource newResource(d->m_resourceName->text(), Nepomuk::Vocabulary::PIMO::Project()); newResource.addSymbol("project-development"); d->m_nofResource.addIsRelated(newResource); } else if (d->m_index == 3) { - Nepomuk2::Resource newResource(d->m_resourceName->text(), Nepomuk2::Vocabulary::PIMO::Task()); + Nepomuk::Resource newResource(d->m_resourceName->text(), Nepomuk::Vocabulary::PIMO::Task()); newResource.addSymbol("view-pim-tasks"); d->m_nofResource.addIsRelated(newResource); } else if (d->m_index == 4) { - Nepomuk2::Resource newResource(d->m_resourceName->text(), Nepomuk2::Vocabulary::PIMO::Location()); + Nepomuk::Resource newResource(d->m_resourceName->text(), Nepomuk::Vocabulary::PIMO::Location()); newResource.addSymbol("user-location"); d->m_nofResource.addIsRelated(newResource); } else if (d->m_index == 5) { - Nepomuk2::Resource newResource(d->m_resourceName->text(), Nepomuk2::Vocabulary::PIMO::Note()); + Nepomuk::Resource newResource(d->m_resourceName->text(), Nepomuk::Vocabulary::PIMO::Note()); newResource.addSymbol("knotes"); d->m_nofResource.addIsRelated(newResource); } diff --git a/src/urlbar/newresourcedialog.h b/src/urlbar/newresourcedialog.h index 7aacb358..651c631c 100644 --- a/src/urlbar/newresourcedialog.h +++ b/src/urlbar/newresourcedialog.h @@ -32,17 +32,17 @@ #include <KDialog> #include <KLineEdit> -#include <Nepomuk2/Resource> +#include <Nepomuk/Resource> -namespace Nepomuk2 +namespace Nepomuk { class NewResourceDialog : public KDialog { Q_OBJECT public: - explicit NewResourceDialog(int index, Nepomuk2::Resource& nfoResource, QWidget* parent = 0); + explicit NewResourceDialog(int index, Nepomuk::Resource& nfoResource, QWidget* parent = 0); virtual ~NewResourceDialog(); private Q_SLOTS: diff --git a/src/urlbar/resourcelinkdialog.cpp b/src/urlbar/resourcelinkdialog.cpp index dbff77b8..799171f2 100644 --- a/src/urlbar/resourcelinkdialog.cpp +++ b/src/urlbar/resourcelinkdialog.cpp @@ -54,22 +54,18 @@ #include <KIcon> // Nepomuk Includes -#include <Nepomuk2/Query/Term> -#include <Nepomuk2/Query/Result> -#include <Nepomuk2/Query/ResourceTypeTerm> -#include <Nepomuk2/Query/QueryServiceClient> -#include <Nepomuk2/Vocabulary/PIMO> -#include <Nepomuk2/Vocabulary/NCO> -#include <Nepomuk2/Query/QueryParser> -#include <Nepomuk2/Variant> - -// Nepomuk Ported Classes -#include "nepomuk/utils/simpleresourcemodel.h" - -// Soprano Includes -#include <Soprano/Vocabulary/NAO> - -class Nepomuk2::ResourceLinkDialog::Private +#include <Nepomuk/Utils/SimpleResourceModel> +#include <Nepomuk/Query/Term> +#include <Nepomuk/Query/Result> +#include <Nepomuk/Query/ResourceTypeTerm> +#include <Nepomuk/Query/QueryServiceClient> +#include <Nepomuk/Vocabulary/PIMO> +#include <Nepomuk/Vocabulary/NCO> +#include <Nepomuk/Query/QueryParser> +#include <Nepomuk/Variant> + + +class Nepomuk::ResourceLinkDialog::Private { public: void _k_selectionChanged(); @@ -86,20 +82,20 @@ public: QPushButton *m_newResourceButton; Utils::SimpleResourceModel *m_resourceModel; Utils::SimpleResourceModel *m_linkedResourceModel; - Nepomuk2::ResourceLinkDialog *q; + Nepomuk::ResourceLinkDialog *q; - Nepomuk2::Resource m_nfoResource; + Nepomuk::Resource m_nfoResource; }; -void Nepomuk2::ResourceLinkDialog::Private::_k_selectionChanged() +void Nepomuk::ResourceLinkDialog::Private::_k_selectionChanged() { q->enableButton(KDialog::User1, !m_resourceView->selectionModel()->selectedRows().isEmpty()); } -Nepomuk2::ResourceLinkDialog::ResourceLinkDialog(Nepomuk2::Resource &nfoResource, QWidget* parent): +Nepomuk::ResourceLinkDialog::ResourceLinkDialog(Nepomuk::Resource &nfoResource, QWidget* parent): KDialog(parent), d(new Private()) { @@ -186,21 +182,21 @@ Nepomuk2::ResourceLinkDialog::ResourceLinkDialog(Nepomuk2::Resource &nfoResource } -Nepomuk2::ResourceLinkDialog::~ResourceLinkDialog() +Nepomuk::ResourceLinkDialog::~ResourceLinkDialog() { delete d; } -void Nepomuk2::ResourceLinkDialog::setRelatedResources() +void Nepomuk::ResourceLinkDialog::setRelatedResources() { - QList<Nepomuk2::Resource> relatedResourceList = d->m_nfoResource.isRelateds(); + QList<Nepomuk::Resource> relatedResourceList = d->m_nfoResource.isRelateds(); d->m_linkedResourceModel->setResources(relatedResourceList); } -void Nepomuk2::ResourceLinkDialog::linkResourceSlot() +void Nepomuk::ResourceLinkDialog::linkResourceSlot() { QModelIndexList selectedResourceList; selectedResourceList << d->m_resourceView->selectionModel()->selectedIndexes(); @@ -213,16 +209,16 @@ void Nepomuk2::ResourceLinkDialog::linkResourceSlot() } -void Nepomuk2::ResourceLinkDialog::unlinkResourceSlot() +void Nepomuk::ResourceLinkDialog::unlinkResourceSlot() { - d->m_nfoResource.removeProperty(Soprano::Vocabulary::NAO::isRelated().toString(), + d->m_nfoResource.removeProperty(Nepomuk::Resource::isRelatedUri(), d->m_linkedResourceModel->resourceForIndex( d->m_linkedResources->selectionModel()->currentIndex())); setRelatedResources(); } -void Nepomuk2::ResourceLinkDialog::showContextMenu(const QPoint &pos) +void Nepomuk::ResourceLinkDialog::showContextMenu(const QPoint &pos) { d->m_removeResourceAction = new KAction(this); d->m_removeResourceAction->setText(i18n("&Unlink ")); @@ -236,9 +232,9 @@ void Nepomuk2::ResourceLinkDialog::showContextMenu(const QPoint &pos) } -void Nepomuk2::ResourceLinkDialog::createNewResourceSlot() +void Nepomuk::ResourceLinkDialog::createNewResourceSlot() { - QPointer<Nepomuk2::NewResourceDialog> r = new Nepomuk2::NewResourceDialog(d->m_resourceSelect->currentIndex(), d->m_nfoResource); + QPointer<Nepomuk::NewResourceDialog> r = new Nepomuk::NewResourceDialog(d->m_resourceSelect->currentIndex(), d->m_nfoResource); r->exec(); setRelatedResources(); @@ -247,60 +243,60 @@ void Nepomuk2::ResourceLinkDialog::createNewResourceSlot() } -void Nepomuk2::ResourceLinkDialog::dynamicSearchingSlot() +void Nepomuk::ResourceLinkDialog::dynamicSearchingSlot() { - Nepomuk2::Query::Query query; - Nepomuk2::Query::QueryServiceClient *test; + Nepomuk::Query::Query query; + Nepomuk::Query::QueryServiceClient *test; switch (d->m_resourceSelect->currentIndex()) { case 1: - query = Nepomuk2::Query::QueryParser::parseQuery(d->m_searchBox->text()); - query = query && Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Person()); - test = new Nepomuk2::Query::QueryServiceClient(this); + query = Nepomuk::Query::QueryParser::parseQuery(d->m_searchBox->text()); + query = query && Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Person()); + test = new Nepomuk::Query::QueryServiceClient(this); test->query(query); d->m_resourceModel->clear(); - connect(test, SIGNAL(newEntries(QList<Nepomuk2::Query::Result>)), - d->m_resourceModel, SLOT(addResults(QList<Nepomuk2::Query::Result>))); + connect(test, SIGNAL(newEntries(QList<Nepomuk::Query::Result>)), + d->m_resourceModel, SLOT(addResults(QList<Nepomuk::Query::Result>))); break; case 2: - query = Nepomuk2::Query::QueryParser::parseQuery(d->m_searchBox->text()); - query = query && Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Project()); - test = new Nepomuk2::Query::QueryServiceClient(this); + query = Nepomuk::Query::QueryParser::parseQuery(d->m_searchBox->text()); + query = query && Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Project()); + test = new Nepomuk::Query::QueryServiceClient(this); test->query(query); d->m_resourceModel->clear(); - connect(test, SIGNAL(newEntries(QList<Nepomuk2::Query::Result>)), - d->m_resourceModel, SLOT(addResults(QList<Nepomuk2::Query::Result>))); + connect(test, SIGNAL(newEntries(QList<Nepomuk::Query::Result>)), + d->m_resourceModel, SLOT(addResults(QList<Nepomuk::Query::Result>))); break; case 3: - query = Nepomuk2::Query::QueryParser::parseQuery(d->m_searchBox->text()); - query = query && Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Task()); - test = new Nepomuk2::Query::QueryServiceClient(this); + query = Nepomuk::Query::QueryParser::parseQuery(d->m_searchBox->text()); + query = query && Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Task()); + test = new Nepomuk::Query::QueryServiceClient(this); test->query(query); d->m_resourceModel->clear(); - connect(test, SIGNAL(newEntries(QList<Nepomuk2::Query::Result>)), - d->m_resourceModel, SLOT(addResults(QList<Nepomuk2::Query::Result>))); + connect(test, SIGNAL(newEntries(QList<Nepomuk::Query::Result>)), + d->m_resourceModel, SLOT(addResults(QList<Nepomuk::Query::Result>))); break; case 4: - query = Nepomuk2::Query::QueryParser::parseQuery(d->m_searchBox->text()); - query = query && Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Location()); - test = new Nepomuk2::Query::QueryServiceClient(this); + query = Nepomuk::Query::QueryParser::parseQuery(d->m_searchBox->text()); + query = query && Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Location()); + test = new Nepomuk::Query::QueryServiceClient(this); test->query(query); d->m_resourceModel->clear(); - connect(test, SIGNAL(newEntries(QList<Nepomuk2::Query::Result>)), - d->m_resourceModel, SLOT(addResults(QList<Nepomuk2::Query::Result>))); + connect(test, SIGNAL(newEntries(QList<Nepomuk::Query::Result>)), + d->m_resourceModel, SLOT(addResults(QList<Nepomuk::Query::Result>))); break; case 5: - query = Nepomuk2::Query::QueryParser::parseQuery(d->m_searchBox->text()); - query = query && Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Note()); - test = new Nepomuk2::Query::QueryServiceClient(this); + query = Nepomuk::Query::QueryParser::parseQuery(d->m_searchBox->text()); + query = query && Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Note()); + test = new Nepomuk::Query::QueryServiceClient(this); test->query(query); d->m_resourceModel->clear(); - connect(test, SIGNAL(newEntries(QList<Nepomuk2::Query::Result>)), - d->m_resourceModel, SLOT(addResults(QList<Nepomuk2::Query::Result>))); + connect(test, SIGNAL(newEntries(QList<Nepomuk::Query::Result>)), + d->m_resourceModel, SLOT(addResults(QList<Nepomuk::Query::Result>))); break; default: @@ -309,7 +305,7 @@ void Nepomuk2::ResourceLinkDialog::dynamicSearchingSlot() } -void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) +void Nepomuk::ResourceLinkDialog::resourceSelectedSlot(int index) { enableButton(User1, true); d->m_newResourceButton->setEnabled(true); @@ -321,12 +317,12 @@ void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) //List Personal Contacts if (index == 1) { - Nepomuk2::Query::Term term = Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Person()); - Nepomuk2::Query::Query query(term); + Nepomuk::Query::Term term = Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Person()); + Nepomuk::Query::Query query(term); query.setLimit(20); - QList<Nepomuk2::Query::Result>results = Nepomuk2::Query::QueryServiceClient::syncQuery(query); - QList <Nepomuk2::Resource> resource; - Q_FOREACH(const Nepomuk2::Query::Result & result, results) + QList<Nepomuk::Query::Result>results = Nepomuk::Query::QueryServiceClient::syncQuery(query); + QList <Nepomuk::Resource> resource; + Q_FOREACH(const Nepomuk::Query::Result & result, results) { resource.append(result.resource()); } @@ -335,12 +331,12 @@ void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) //List Projects else if (index == 2) { - Nepomuk2::Query::Term term = Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Project()); - Nepomuk2::Query::Query query(term); + Nepomuk::Query::Term term = Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Project()); + Nepomuk::Query::Query query(term); query.setLimit(20); - QList<Nepomuk2::Query::Result>results = Nepomuk2::Query::QueryServiceClient::syncQuery(query); - QList <Nepomuk2::Resource> resource; - Q_FOREACH(const Nepomuk2::Query::Result & result, results) + QList<Nepomuk::Query::Result>results = Nepomuk::Query::QueryServiceClient::syncQuery(query); + QList <Nepomuk::Resource> resource; + Q_FOREACH(const Nepomuk::Query::Result & result, results) { resource.append(result.resource()); } @@ -349,12 +345,12 @@ void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) //List Tasks else if (index == 3) { - Nepomuk2::Query::Term term = Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Task()); - Nepomuk2::Query::Query query(term); + Nepomuk::Query::Term term = Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Task()); + Nepomuk::Query::Query query(term); query.setLimit(20); - QList<Nepomuk2::Query::Result>results = Nepomuk2::Query::QueryServiceClient::syncQuery(query); - QList <Nepomuk2::Resource> resource; - Q_FOREACH(const Nepomuk2::Query::Result & result, results) + QList<Nepomuk::Query::Result>results = Nepomuk::Query::QueryServiceClient::syncQuery(query); + QList <Nepomuk::Resource> resource; + Q_FOREACH(const Nepomuk::Query::Result & result, results) { resource.append(result.resource()); } @@ -363,12 +359,12 @@ void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) //List Places else if (index == 4) { - Nepomuk2::Query::Term term = Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Location()); - Nepomuk2::Query::Query query(term); + Nepomuk::Query::Term term = Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Location()); + Nepomuk::Query::Query query(term); query.setLimit(20); - QList<Nepomuk2::Query::Result>results = Nepomuk2::Query::QueryServiceClient::syncQuery(query); - QList <Nepomuk2::Resource> resource; - Q_FOREACH(const Nepomuk2::Query::Result & result, results) + QList<Nepomuk::Query::Result>results = Nepomuk::Query::QueryServiceClient::syncQuery(query); + QList <Nepomuk::Resource> resource; + Q_FOREACH(const Nepomuk::Query::Result & result, results) { resource.append(result.resource()); } @@ -377,12 +373,12 @@ void Nepomuk2::ResourceLinkDialog::resourceSelectedSlot(int index) //List Notes else if (index == 5) { - Nepomuk2::Query::Term term = Nepomuk2::Query::ResourceTypeTerm(Nepomuk2::Vocabulary::PIMO::Note()); - Nepomuk2::Query::Query query(term); + Nepomuk::Query::Term term = Nepomuk::Query::ResourceTypeTerm(Nepomuk::Vocabulary::PIMO::Note()); + Nepomuk::Query::Query query(term); query.setLimit(20); - QList<Nepomuk2::Query::Result>results = Nepomuk2::Query::QueryServiceClient::syncQuery(query); - QList <Nepomuk2::Resource> resource; - Q_FOREACH(const Nepomuk2::Query::Result & result, results) + QList<Nepomuk::Query::Result>results = Nepomuk::Query::QueryServiceClient::syncQuery(query); + QList <Nepomuk::Resource> resource; + Q_FOREACH(const Nepomuk::Query::Result & result, results) { resource.append(result.resource()); } diff --git a/src/urlbar/resourcelinkdialog.h b/src/urlbar/resourcelinkdialog.h index 689ef4fe..e628aa10 100644 --- a/src/urlbar/resourcelinkdialog.h +++ b/src/urlbar/resourcelinkdialog.h @@ -36,7 +36,7 @@ #include <KConfigDialog> -namespace Nepomuk2 +namespace Nepomuk { class Resource; @@ -50,7 +50,7 @@ class ResourceLinkDialog : public KDialog Q_OBJECT public: - explicit ResourceLinkDialog(Nepomuk2::Resource& nfoResource, QWidget* parent = 0); + explicit ResourceLinkDialog(Nepomuk::Resource& nfoResource, QWidget* parent = 0); virtual ~ResourceLinkDialog(); void setRelatedResources(); |