docdjvuplugin.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #include "docdjvuplugin.h"
00021
00022 #include <kurl.h>
00023 #include <kaboutdata.h>
00024 #include <kconfig.h>
00025 #include <klocale.h>
00026 #include <klistview.h>
00027
00028 #include <kdevgenericfactory.h>
00029
00030 static const KAboutData data("docdjvuplugin", I18N_NOOP("Djvu documentation plugin"), "1.0");
00031 typedef KDevGenericFactory<DocDjvuPlugin> DocDjvuPluginFactory;
00032 K_EXPORT_COMPONENT_FACTORY( libdocdjvuplugin, DocDjvuPluginFactory(&data) )
00033
00034 DocDjvuPlugin::DocDjvuPlugin(QObject* parent, const char* name, const QStringList args)
00035 :DocumentationPlugin(DocDjvuPluginFactory::instance()->config(), parent, name)
00036 {
00037 setCapabilities(CustomDocumentationTitles | ProjectUserManual);
00038 autoSetup();
00039 }
00040
00041 DocDjvuPlugin::~DocDjvuPlugin()
00042 {
00043 }
00044
00045 bool DocDjvuPlugin::needRefreshIndex(DocumentationCatalogItem* item)
00046 {
00047 return false;
00048 }
00049
00050 QString DocDjvuPlugin::pluginName() const
00051 {
00052 return i18n("Djvu Documentation Collection");
00053 }
00054
00055 DocumentationCatalogItem* DocDjvuPlugin::createCatalog(KListView* contents, const QString& title, const QString& url)
00056 {
00057 DocumentationCatalogItem *item = new DocumentationCatalogItem(this, contents, title);
00058 item->setURL(KURL(url));
00059 return item;
00060 }
00061
00062 QPair<KFile::Mode, QString> DocDjvuPlugin::catalogLocatorProps()
00063 {
00064 return QPair<KFile::Mode, QString>(KFile::File, "all/allfiles");
00065 }
00066
00067 QString DocDjvuPlugin::catalogTitle(const QString& )
00068 {
00069 return QString::null;
00070 }
00071
00072 QStringList DocDjvuPlugin::fullTextSearchLocations()
00073 {
00074 return QStringList();
00075 }
00076
00077
00078 void DocDjvuPlugin::autoSetupPlugin()
00079 {
00080 return;
00081 }
00082
00083 void DocDjvuPlugin::createIndex(IndexBox* , DocumentationCatalogItem* )
00084 {
00085 return;
00086 }
00087
00088 void DocDjvuPlugin::createTOC(DocumentationCatalogItem* )
00089 {
00090 return;
00091 }
00092
00093 void DocDjvuPlugin::setCatalogURL(DocumentationCatalogItem* )
00094 {
00095 return;
00096 }
00097
00098 ProjectDocumentationPlugin *DocDjvuPlugin::projectDocumentationPlugin(ProjectDocType type)
00099 {
00100 if (type == UserManual)
00101 return new ProjectDocumentationPlugin(this, type);
00102 return DocumentationPlugin::projectDocumentationPlugin(type);
00103 }
This file is part of the documentation for KDevelop Version 3.1.2.