X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fcommon%2Fmain.cpp;h=6552598487ff84b196f0abbcf72b12908c7e5707;hb=c52a94cb937654bf06d5074bf0736a52ec94a52d;hp=7884dfa686e0716e08b17f856d251154ebe661cf;hpb=c3c6809d89bd860cb74c7cc1336f190cfe97a3b9;p=quassel.git diff --git a/src/common/main.cpp b/src/common/main.cpp index 7884dfa6..65525984 100644 --- a/src/common/main.cpp +++ b/src/common/main.cpp @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2014 by the Quassel Project * + * Copyright (C) 2005-2015 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -32,11 +32,11 @@ #endif // We don't want quasselcore to depend on KDE -#if defined HAVE_KDE && defined BUILD_CORE -# undef HAVE_KDE +#if defined HAVE_KDE4 && defined BUILD_CORE +# undef HAVE_KDE4 #endif -#ifdef HAVE_KDE +#ifdef HAVE_KDE4 # include # include "kcmdlinewrapper.h" #endif @@ -67,24 +67,23 @@ int main(int argc, char **argv) Q_INIT_RESOURCE(sql); #endif #ifndef BUILD_CORE - Q_INIT_RESOURCE(pics); // always in a resource, for now + Q_INIT_RESOURCE(pics); + Q_INIT_RESOURCE(hicolor); #endif #ifdef EMBED_DATA Q_INIT_RESOURCE(i18n); # ifndef BUILD_CORE Q_INIT_RESOURCE(data); - Q_INIT_RESOURCE(hicolor); - Q_INIT_RESOURCE(oxygen); # ifdef WITH_OXYGEN - Q_INIT_RESOURCE(oxygen_kde); + Q_INIT_RESOURCE(oxygen); # endif # endif #endif AbstractCliParser *cliParser; -#ifdef HAVE_KDE +#ifdef HAVE_KDE4 // We need to init KCmdLineArgs first // TODO: build an AboutData compat class to replace our aboutDlg strings KAboutData aboutData("quassel", "kdelibs4", ki18n("Quassel IRC"), Quassel::buildInfo().plainVersionString.toUtf8(), @@ -117,6 +116,7 @@ int main(int argc, char **argv) #ifndef BUILD_CORE // put client-only arguments here + cliParser->addOption("icontheme ", 0, "Override the system icon theme ('oxygen' is recommended)"); cliParser->addOption("qss ", 0, "Load a custom application stylesheet"); cliParser->addSwitch("debugbufferswitches", 0, "Enables debugging for bufferswitches"); cliParser->addSwitch("debugmodel", 0, "Enables debugging for models"); @@ -143,7 +143,7 @@ int main(int argc, char **argv) cliParser->addSwitch("enable-experimental-dcc", 0, "Enable highly experimental and unfinished support for CTCP DCC (DANGEROUS)"); #endif -#ifdef HAVE_KDE +#ifdef HAVE_KDE4 // the KDE version needs this extra call to parse argc/argv before app is instantiated if (!cliParser->init()) { cliParser->usage(); @@ -159,7 +159,7 @@ int main(int argc, char **argv) MonolithicApplication app(argc, argv); # endif -#ifndef HAVE_KDE +#ifndef HAVE_KDE4 // the non-KDE version parses after app has been instantiated if (!cliParser->init(app.arguments())) { cliParser->usage();