diff --git a/rssguard.pro b/rssguard.pro index c237750a1..929a6940c 100644 --- a/rssguard.pro +++ b/rssguard.pro @@ -50,7 +50,17 @@ TEMPLATE = app TARGET = rssguard -INCLUDEPATH += . +CODECFORTR = UTF-8 +CODECFORSRC = UTF-8 + +message(rssguard: Welcome to RSS Guard qmake script.) +message(rssguard: Detected Qt version: $$QT_VERSION) + +lessThan(QT_MAJOR_VERSION, 5)|lessThan(QT_MINOR_VERSION, 4) { + error(rssguard: At least Qt 5.4.0 is required.) +} + +QT += core gui widgets sql network xml printsupport HEADERS += src/core/feeddownloader.h \ src/core/feedsmodel.h \ @@ -371,7 +381,7 @@ SOURCES += src/main.cpp \ src/services/tt-rss/gui/formeditaccount.cpp \ src/services/tt-rss/gui/formttrssfeeddetails.cpp \ src/services/tt-rss/network/ttrssnetworkfactory.cpp - + FORMS += src/gui/messagepreviewer.ui \ src/gui/newspaperpreviewer.ui \ src/gui/toolbareditor.ui \ @@ -390,7 +400,7 @@ FORMS += src/gui/messagepreviewer.ui \ src/services/standard/gui/formstandardcategorydetails.ui \ src/services/standard/gui/formstandardimportexport.ui \ src/services/tt-rss/gui/formeditaccount.ui - + TRANSLATIONS += localization/qtbase-cs_CZ.ts \ localization/qtbase-da_DK.ts \ localization/qtbase-de_DE.ts \ @@ -412,4 +422,22 @@ TRANSLATIONS += localization/qtbase-cs_CZ.ts \ localization/rssguard-lt_LT.ts \ localization/rssguard-nl_NL.ts \ localization/rssguard-pt_BR.ts \ - localization/rssguard-sv_SE.ts \ No newline at end of file + localization/rssguard-sv_SE.ts + +INCLUDEPATH += . \ + src \ + src/gui \ + src/gui/dialogs \ + src/dynamic-shortcuts + +win { +# Install all files on Windows. +} + +unix:!mac { +# Install all files on Linux. +} + +mac { +# Install all files on Mac OS X. +} diff --git a/src/definitions/definitions.h.in b/src/definitions/definitions.h old mode 100755 new mode 100644 similarity index 87% rename from src/definitions/definitions.h.in rename to src/definitions/definitions.h index 9f27f0ca3..bc0071988 --- a/src/definitions/definitions.h.in +++ b/src/definitions/definitions.h @@ -20,22 +20,19 @@ #include -#define CMAKE_VERSION "@CMAKE_VERSION@" -#define CMAKE_SYSTEM "@CMAKE_SYSTEM@" - -#define APP_NAME "@APP_NAME@" -#define APP_LOW_NAME "@APP_LOW_NAME@" -#define APP_LOW_H_NAME ".@APP_LOW_NAME@" -#define APP_LONG_NAME "@APP_NAME@ @APP_VERSION@" -#define APP_AUTHOR "@APP_AUTHOR@" -#define APP_EMAIL "@APP_EMAIL@" -#define APP_URL "@APP_URL@" -#define APP_URL_ISSUES "@APP_URL_ISSUES@" -#define APP_URL_ISSUES_NEW_GITHUB "@APP_URL_ISSUES_NEW_GITHUB@" -#define APP_URL_ISSUES_NEW_BITBUCKET "@APP_URL_ISSUES_NEW_BITBUCKET@" -#define APP_URL_WIKI "@APP_URL_WIKI@" -#define APP_VERSION "@APP_VERSION@" -#define APP_USERAGENT QString("@APP_NAME@/@APP_VERSION@ (@APP_URL@) on @CMAKE_SYSTEM@") +#define APP_NAME "RSS Guard" +#define APP_LOW_NAME "rssguard" +#define APP_LOW_H_NAME ".rssguard" +#define APP_LONG_NAME "RSS Guard 3.3.0" +#define APP_AUTHOR "Martin Rotter" +#define APP_EMAIL "rotter.martinos@gmail.com" +#define APP_URL "http://bitbucket.org/skunkos/rssguard" +#define APP_URL_ISSUES "http://bitbucket.org/skunkos/rssguard/issues" +#define APP_URL_ISSUES_NEW_GITHUB "https://github.com/martinrotter/rssguard/issues/new" +#define APP_URL_ISSUES_NEW_BITBUCKET "http://bitbucket.org/skunkos/rssguard/issues/new" +#define APP_URL_WIKI "https://bitbucket.org/skunkos/rssguard/wiki/Home" +#define APP_VERSION "3.3.0" +#define APP_USERAGENT QString("RSS Guuard/3.3.0 (http://bitbucket.org/skunkos/rssguard)") #define APP_DONATE_URL "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=XMWPLPK893VH4" #define SERVICE_CODE_STD_RSS "std-rss" @@ -72,8 +69,8 @@ #define DEFAULT_DAYS_TO_DELETE_MSG 14 #define ELLIPSIS_LENGTH 3 #define MIN_CATEGORY_NAME_LENGTH 3 -#define INTERNAL_URL_NEWSPAPER "@APP_LOW_NAME@:newspaper" -#define INTERNAL_URL_EMPTY "@APP_LOW_NAME@:empty" +#define INTERNAL_URL_NEWSPAPER "rssguard:newspaper" +#define INTERNAL_URL_EMPTY "rssguard:empty" #define INTERNAL_URL_BLANK "about:blank" #define DEFAULT_AUTO_UPDATE_INTERVAL 15 #define AUTO_UPDATE_INTERVAL 60000 @@ -89,7 +86,7 @@ #define FILTER_RIGHT_MARGIN 5 #define FEEDS_VIEW_INDENTATION 10 #define ACCEPT_HEADER_FOR_FEED_DOWNLOADER "application/atom+xml,application/xml;q=0.9,text/xml;q=0.8,*/*;q=0.7" -#define MIME_TYPE_ITEM_POINTER "@APP_LOW_NAME@/itempointer" +#define MIME_TYPE_ITEM_POINTER "rssguard/itempointer" #define DOWNLOADER_ICON_SIZE 48 #define NOTIFICATION_ICON_SIZE 32 #define GOOGLE_SEARCH_URL "https://www.google.com/search?q=%1&ie=utf-8&oe=utf-8" @@ -134,12 +131,11 @@ #define APP_LOG_FILE "log.txt" #if defined(Q_OS_OSX) -#define APP_PREFIX "@CMAKE_INSTALL_PREFIX@/@APP_LOW_NAME@.app/Contents/Resources" +#define APP_PREFIX "rssguard.app/Contents/Resources" #else -#define APP_PREFIX "@CMAKE_INSTALL_PREFIX@" +#define APP_PREFIX ".." #endif -#define APP_REVISION "@APP_REVISION@" #define APP_QUIT_INSTANCE "app_quit" #define APP_IS_RUNNING "app_is_running" #define APP_SKIN_DEFAULT "base/vergilius.xml" diff --git a/src/gui/dialogs/formabout.cpp b/src/gui/dialogs/formabout.cpp index d5b8f2ba9..1d9924f75 100755 --- a/src/gui/dialogs/formabout.cpp +++ b/src/gui/dialogs/formabout.cpp @@ -99,13 +99,9 @@ void FormAbout::loadLicenseAndInformation() { // Set other informative texts. m_ui->m_lblDesc->setText(tr("%8
" - "Version: %1 (build on %2 with CMake %3)
" - "Revision: %4
" - "Build date: %5
" - "Qt: %6 (compiled against %7)
").arg(qApp->applicationVersion(), - CMAKE_SYSTEM, - CMAKE_VERSION, - APP_REVISION, + "Version: %1
" + "Build date: %2
" + "Qt: %3 (compiled against %4)
").arg(qApp->applicationVersion(), TextFactory::parseDateTime(QString("%1 %2").arg(__DATE__, __TIME__)).toString(Qt::DefaultLocaleShortDate), qVersion(), diff --git a/src/gui/timespinbox.cpp b/src/gui/timespinbox.cpp index addea9ee3..b7b76544f 100644 --- a/src/gui/timespinbox.cpp +++ b/src/gui/timespinbox.cpp @@ -82,5 +82,7 @@ void TimeSpinBox::fixup(QString &input) const { } QValidator::State TimeSpinBox::validate(QString &input, int &pos) const { + Q_UNUSED(pos) + return (valueFromText(input) != -1.0) ? QValidator::Acceptable : QValidator::Intermediate; } diff --git a/src/miscellaneous/iofactory.cpp b/src/miscellaneous/iofactory.cpp index 398cc0ce4..ea23a0ab4 100755 --- a/src/miscellaneous/iofactory.cpp +++ b/src/miscellaneous/iofactory.cpp @@ -89,6 +89,8 @@ QByteArray IOFactory::readTextFile(const QString &file_path) { } void IOFactory::writeTextFile(const QString &file_path, const QByteArray &data, const QString &encoding) { + Q_UNUSED(encoding) + QFile input_file(file_path); QTextStream stream(&input_file); diff --git a/src/services/abstract/rootitem.cpp b/src/services/abstract/rootitem.cpp index 0d0f080ef..05e0901eb 100755 --- a/src/services/abstract/rootitem.cpp +++ b/src/services/abstract/rootitem.cpp @@ -201,6 +201,8 @@ Qt::ItemFlags RootItem::additionalFlags() const { } bool RootItem::performDragDropChange(RootItem *target_item) { + Q_UNUSED(target_item) + return false; }