┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/panels/information/nfotranslator.h
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2010-02-26 18:03:13 +0000
committerPeter Penz <[email protected]>2010-02-26 18:03:13 +0000
commit4e370297de110dbb5c6c231dd460e2a7d46e496b (patch)
tree1a264ca70444ffde425441015e29d8feac80123b /src/panels/information/nfotranslator.h
parent5dee68a0615db33b4607567e28e3638a9e085786 (diff)
Show meta information also for files, which are not indexed (or in the case if Nepomuk is turned off).
Beside the new translations the fix is based on several other fixes in kdelibs + strigi and cannot be backported to KDE SC 4.4.x. As soon as the meta data widget has been moved to kdelibs, this meta data information will also be available in the properties dialog. BUG: 193592 svn path=/trunk/KDE/kdebase/apps/; revision=1096472
Diffstat (limited to 'src/panels/information/nfotranslator.h')
-rw-r--r--src/panels/information/nfotranslator.h47
1 files changed, 47 insertions, 0 deletions
diff --git a/src/panels/information/nfotranslator.h b/src/panels/information/nfotranslator.h
new file mode 100644
index 000000000..4a51c60f3
--- /dev/null
+++ b/src/panels/information/nfotranslator.h
@@ -0,0 +1,47 @@
+/*****************************************************************************
+ * Copyright (C) 2010 by Peter Penz <[email protected]> *
+ * *
+ * This library is free software; you can redistribute it and/or *
+ * modify it under the terms of the GNU Library General Public *
+ * License version 2 as published by the Free Software Foundation. *
+ * *
+ * This library is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Library General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Library General Public License *
+ * along with this library; see the file COPYING.LIB. If not, write to *
+ * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, *
+ * Boston, MA 02110-1301, USA. *
+ *****************************************************************************/
+
+#ifndef NFOTRANSLATOR_H
+#define NFOTRANSLATOR_H
+
+#include <QHash>
+#include <QString>
+
+class QUrl;
+
+/**
+ * @brief Returns translations for Nepomuk File Ontology URIs.
+ *
+ * See http://www.semanticdesktop.org/ontologies/nfo/.
+ */
+class NfoTranslator
+{
+public:
+ static NfoTranslator& instance();
+ QString translation(const QUrl& uri) const;
+
+protected:
+ NfoTranslator();
+ virtual ~NfoTranslator();
+ friend class NfoTranslatorSingleton;
+
+private:
+ QHash<QString, QString> m_hash;
+};
+
+#endif // NFO_TRANSLATOR_H