summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <montel@kde.org>2015-08-04 13:22:41 (GMT)
committerMontel Laurent <montel@kde.org>2015-08-04 13:22:41 (GMT)
commite03e6f6863a5771bb244ff2c9296c00a58308adc (patch)
tree2b85da87570502aff2debc09414c069ea36d57aa
parenta8c13a9e1dd58e2a13e98a8b966bedc41cea1ffd (diff)
Use Q_DECL_OVERRIDE
-rw-r--r--generators/chm/generator_chm.h16
-rw-r--r--generators/comicbook/generator_comicbook.h8
-rw-r--r--generators/djvu/generator_djvu.h12
-rw-r--r--generators/epub/converter.h2
-rw-r--r--generators/fax/generator_fax.h8
-rw-r--r--generators/poppler/formfields.h8
-rw-r--r--generators/poppler/generator_pdf.h16
-rw-r--r--generators/tiff/generator_tiff.h8
-rw-r--r--generators/txt/converter.h2
-rw-r--r--shell/main.cpp12
-rw-r--r--shell/shell.h8
11 files changed, 50 insertions, 50 deletions
diff --git a/generators/chm/generator_chm.h b/generators/chm/generator_chm.h
index fc9f00d..516a15b 100644
--- a/generators/chm/generator_chm.h
+++ b/generators/chm/generator_chm.h
@@ -35,22 +35,22 @@ class CHMGenerator : public Okular::Generator
public:
CHMGenerator( QObject *parent, const QVariantList &args );
~CHMGenerator();
- bool loadDocument( const QString & fileName, QVector< Okular::Page * > & pagesVector );
+ bool loadDocument( const QString & fileName, QVector< Okular::Page * > & pagesVector ) Q_DECL_OVERRIDE;
- Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const;
- const Okular::DocumentSynopsis * generateDocumentSynopsis();
+ Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const Q_DECL_OVERRIDE;
+ const Okular::DocumentSynopsis * generateDocumentSynopsis() Q_DECL_OVERRIDE;
- bool canGeneratePixmap() const;
- void generatePixmap( Okular::PixmapRequest * request );
+ bool canGeneratePixmap() const Q_DECL_OVERRIDE;
+ void generatePixmap( Okular::PixmapRequest * request ) Q_DECL_OVERRIDE;
- QVariant metaData( const QString & key, const QVariant & option ) const;
+ QVariant metaData( const QString & key, const QVariant & option ) const Q_DECL_OVERRIDE;
public slots:
void slotCompleted();
protected:
- bool doCloseDocument();
- Okular::TextPage* textPage( Okular::Page *page );
+ bool doCloseDocument() Q_DECL_OVERRIDE;
+ Okular::TextPage* textPage( Okular::Page *page ) Q_DECL_OVERRIDE;
private:
void additionalRequestData();
diff --git a/generators/comicbook/generator_comicbook.h b/generators/comicbook/generator_comicbook.h
index 6375640..daa2db1 100644
--- a/generators/comicbook/generator_comicbook.h
+++ b/generators/comicbook/generator_comicbook.h
@@ -24,14 +24,14 @@ class ComicBookGenerator : public Okular::Generator
virtual ~ComicBookGenerator();
// [INHERITED] load a document and fill up the pagesVector
- bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector );
+ bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector ) Q_DECL_OVERRIDE;
// [INHERITED] print document using already configured kprinter
- bool print( QPrinter& printer );
+ bool print( QPrinter& printer ) Q_DECL_OVERRIDE;
protected:
- bool doCloseDocument();
- QImage image( Okular::PixmapRequest * request );
+ bool doCloseDocument() Q_DECL_OVERRIDE;
+ QImage image( Okular::PixmapRequest * request ) Q_DECL_OVERRIDE;
private:
ComicBook::Document mDocument;
diff --git a/generators/djvu/generator_djvu.h b/generators/djvu/generator_djvu.h
index 8800165..cf95798 100644
--- a/generators/djvu/generator_djvu.h
+++ b/generators/djvu/generator_djvu.h
@@ -28,21 +28,21 @@ class DjVuGenerator : public Okular::Generator
public:
DjVuGenerator( QObject *parent, const QVariantList &args );
~DjVuGenerator();
- bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector );
+ bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector ) Q_DECL_OVERRIDE;
// document information
- Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const;
- const Okular::DocumentSynopsis * generateDocumentSynopsis();
+ Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const Q_DECL_OVERRIDE;
+ const Okular::DocumentSynopsis * generateDocumentSynopsis() Q_DECL_OVERRIDE;
// printing
- bool print( QPrinter& printer );
+ bool print( QPrinter& printer ) Q_DECL_OVERRIDE;
- QVariant metaData( const QString & key, const QVariant & option ) const;
+ QVariant metaData( const QString & key, const QVariant & option ) const Q_DECL_OVERRIDE;
protected:
bool doCloseDocument();
// pixmap generation
- QImage image( Okular::PixmapRequest *request );
+ QImage image( Okular::PixmapRequest *request ) Q_DECL_OVERRIDE;
Okular::TextPage* textPage( Okular::Page *page );
private:
diff --git a/generators/epub/converter.h b/generators/epub/converter.h
index d368c70..43613a2 100644
--- a/generators/epub/converter.h
+++ b/generators/epub/converter.h
@@ -24,7 +24,7 @@ namespace Epub {
Converter();
~Converter();
- virtual QTextDocument *convert( const QString &fileName );
+ QTextDocument *convert( const QString &fileName ) Q_DECL_OVERRIDE;
private:
diff --git a/generators/fax/generator_fax.h b/generators/fax/generator_fax.h
index 094eff5..c1e8623 100644
--- a/generators/fax/generator_fax.h
+++ b/generators/fax/generator_fax.h
@@ -25,15 +25,15 @@ class FaxGenerator : public Okular::Generator
FaxGenerator( QObject *parent, const QVariantList &args );
virtual ~FaxGenerator();
- bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector );
+ bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector ) Q_DECL_OVERRIDE;
- Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const;
+ Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const Q_DECL_OVERRIDE;
- bool print( QPrinter& printer );
+ bool print( QPrinter& printer ) Q_DECL_OVERRIDE;
protected:
bool doCloseDocument();
- QImage image( Okular::PixmapRequest * request );
+ QImage image( Okular::PixmapRequest * request ) Q_DECL_OVERRIDE;
private:
QImage m_img;
diff --git a/generators/poppler/formfields.h b/generators/poppler/formfields.h
index 245b8ce..258833c 100644
--- a/generators/poppler/formfields.h
+++ b/generators/poppler/formfields.h
@@ -20,10 +20,10 @@ class PopplerFormFieldButton : public Okular::FormFieldButton
virtual ~PopplerFormFieldButton();
// inherited from Okular::FormField
- virtual Okular::NormalizedRect rect() const;
- virtual int id() const;
- virtual QString name() const;
- virtual QString uiName() const;
+ Okular::NormalizedRect rect() const Q_DECL_OVERRIDE;
+ int id() const Q_DECL_OVERRIDE;
+ QString name() const Q_DECL_OVERRIDE;
+ QString uiName() const Q_DECL_OVERRIDE;
virtual bool isReadOnly() const;
virtual bool isVisible() const;
diff --git a/generators/poppler/generator_pdf.h b/generators/poppler/generator_pdf.h
index 4b9619f..c1df30b 100644
--- a/generators/poppler/generator_pdf.h
+++ b/generators/poppler/generator_pdf.h
@@ -62,20 +62,20 @@ class PDFGenerator : public Okular::Generator, public Okular::ConfigInterface, p
Okular::Document::OpenResult loadDocumentFromDataWithPassword( const QByteArray & fileData, QVector<Okular::Page*> & pagesVector, const QString & password );
void loadPages(QVector<Okular::Page*> &pagesVector, int rotation=-1, bool clear=false);
// [INHERITED] document information
- Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const;
- const Okular::DocumentSynopsis * generateDocumentSynopsis();
- Okular::FontInfo::List fontsForPage( int page );
- const QList<Okular::EmbeddedFile*> * embeddedFiles() const;
- PageSizeMetric pagesSizeMetric() const { return Pixels; }
+ Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const Q_DECL_OVERRIDE;
+ const Okular::DocumentSynopsis * generateDocumentSynopsis() Q_DECL_OVERRIDE;
+ Okular::FontInfo::List fontsForPage( int page ) Q_DECL_OVERRIDE;
+ const QList<Okular::EmbeddedFile*> * embeddedFiles() const Q_DECL_OVERRIDE;
+ PageSizeMetric pagesSizeMetric() const Q_DECL_OVERRIDE{ return Pixels; }
// [INHERITED] document information
- bool isAllowed( Okular::Permission permission ) const;
+ bool isAllowed( Okular::Permission permission ) const Q_DECL_OVERRIDE;
// [INHERITED] perform actions on document / pages
- QImage image( Okular::PixmapRequest *page );
+ QImage image( Okular::PixmapRequest *page ) Q_DECL_OVERRIDE;
// [INHERITED] print page using an already configured kprinter
- bool print( QPrinter& printer );
+ bool print( QPrinter& printer ) Q_DECL_OVERRIDE;
// [INHERITED] reply to some metadata requests
QVariant metaData( const QString & key, const QVariant & option ) const;
diff --git a/generators/tiff/generator_tiff.h b/generators/tiff/generator_tiff.h
index 827a1b5..1122a46 100644
--- a/generators/tiff/generator_tiff.h
+++ b/generators/tiff/generator_tiff.h
@@ -23,12 +23,12 @@ class TIFFGenerator : public Okular::Generator
TIFFGenerator( QObject *parent, const QVariantList &args );
virtual ~TIFFGenerator();
- bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector );
- bool loadDocumentFromData( const QByteArray & fileData, QVector< Okular::Page * > & pagesVector );
+ bool loadDocument( const QString & fileName, QVector<Okular::Page*> & pagesVector ) Q_DECL_OVERRIDE;
+ bool loadDocumentFromData( const QByteArray & fileData, QVector< Okular::Page * > & pagesVector ) Q_DECL_OVERRIDE;
- Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const;
+ Okular::DocumentInfo generateDocumentInfo( const QSet<Okular::DocumentInfo::Key> &keys ) const Q_DECL_OVERRIDE;
- bool print( QPrinter& printer );
+ bool print( QPrinter& printer ) Q_DECL_OVERRIDE;
protected:
bool doCloseDocument();
diff --git a/generators/txt/converter.h b/generators/txt/converter.h
index e6ff2c4..1848c04 100644
--- a/generators/txt/converter.h
+++ b/generators/txt/converter.h
@@ -21,7 +21,7 @@ namespace Txt
Converter();
~Converter();
- virtual QTextDocument *convert( const QString &fileName );
+ QTextDocument *convert( const QString &fileName ) Q_DECL_OVERRIDE;
};
}
diff --git a/shell/main.cpp b/shell/main.cpp
index 0a3e919..77847ba 100644
--- a/shell/main.cpp
+++ b/shell/main.cpp
@@ -36,7 +36,7 @@ int main(int argc, char** argv)
app.setApplicationName(aboutData.applicationData().componentName());
app.setApplicationDisplayName(aboutData.applicationData().displayName());
app.setApplicationVersion(aboutData.version());
- app.setOrganizationDomain("kde.org");
+ app.setOrganizationDomain(QStringLiteral("kde.org"));
QCommandLineParser parser;
KAboutData::setApplicationData(aboutData);
@@ -44,11 +44,11 @@ int main(int argc, char** argv)
parser.addHelpOption();
aboutData.setupCommandLine(&parser);
- parser.addOption(QCommandLineOption(QStringList() << QLatin1String("p") << QLatin1String("page"), i18n("Page of the document to be shown"), QLatin1String("number")));
- parser.addOption(QCommandLineOption(QStringList() << QLatin1String("presentation"), i18n("Start the document in presentation mode")));
- parser.addOption(QCommandLineOption(QStringList() << QLatin1String("print"), i18n("Start with print dialog")));
- parser.addOption(QCommandLineOption(QStringList() << QLatin1String("unique"), i18n("\"Unique instance\" control")));
- parser.addOption(QCommandLineOption(QStringList() << QLatin1String("noraise"), i18n("Not raise window")));
+ parser.addOption(QCommandLineOption(QStringList() << QStringLiteral("p") << QStringLiteral("page"), i18n("Page of the document to be shown"), QStringLiteral("number")));
+ parser.addOption(QCommandLineOption(QStringList() << QStringLiteral("presentation"), i18n("Start the document in presentation mode")));
+ parser.addOption(QCommandLineOption(QStringList() << QStringLiteral("print"), i18n("Start with print dialog")));
+ parser.addOption(QCommandLineOption(QStringList() << QStringLiteral("unique"), i18n("\"Unique instance\" control")));
+ parser.addOption(QCommandLineOption(QStringList() << QStringLiteral("noraise"), i18n("Not raise window")));
parser.addPositionalArgument(QStringLiteral("urls"), i18n("Documents to open. Specify '-' to read from stdin."));
parser.process(app);
diff --git a/shell/shell.h b/shell/shell.h
index 43bd3e1..c16a0b2 100644
--- a/shell/shell.h
+++ b/shell/shell.h
@@ -77,14 +77,14 @@ protected:
* This method is called when it is time for the app to save its
* properties for session management purposes.
*/
- void saveProperties(KConfigGroup&);
+ void saveProperties(KConfigGroup&) Q_DECL_OVERRIDE;
/**
* This method is called when this app is restored. The KConfig
* object points to the session management config file that was saved
* with @ref saveProperties
*/
- void readProperties(const KConfigGroup&);
+ void readProperties(const KConfigGroup&) Q_DECL_OVERRIDE;
/**
* Expose internal functions for session restore testing
@@ -95,9 +95,9 @@ protected:
void readSettings();
void writeSettings();
void setFullScreen( bool );
- bool queryClose();
+ bool queryClose() Q_DECL_OVERRIDE;
- void showEvent(QShowEvent *event);
+ void showEvent(QShowEvent *event) Q_DECL_OVERRIDE;
private slots:
void fileOpen();