Commit c95a44a3 authored by Johannes Zarl-Zierl's avatar Johannes Zarl-Zierl

Fix warning on launch from QCommandLineParser

This fixes the following warnings when starting kphotoalbum:
QCommandLineParser: already having an option named "h"
QCommandLineParser: already having an option named "help-all"
QCommandLineParser: already having an option named "v"

These options are already added by KAboutData::setupCommandLine().
parent 717d69a6
/* Copyright (C) 2016-2019 The KPhotoAlbum Development Team
/* Copyright (C) 2016-2020 The KPhotoAlbum Development Team
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
......@@ -132,8 +132,6 @@ bool MainWindow::Options::searchForImagesOnStart() const
MainWindow::Options::Options()
: d(new OptionsPrivate)
{
d->parser.addVersionOption();
d->parser.addHelpOption();
d->configFile.setFlags(QCommandLineOption::HiddenFromHelp);
d->parser.addOptions(
QList<QCommandLineOption>()
......
......@@ -80,8 +80,6 @@ int main(int argc, char **argv)
// initialize the commandline parser
QCommandLineParser parser;
parser.addHelpOption();
parser.addVersionOption();
parser.addPositionalArgument(QString::fromUtf8("imageDir"), i18nc("@info:shell", "The directory containing the .thumbnail directory."));
QCommandLineOption infoOption { QString::fromUtf8("info"), i18nc("@info:shell", "Print information about thumbnail cache.") };
parser.addOption(infoOption);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment