Browse Source

move COPYRIGHT_YEAR to clientversion.h

- this allows usage of that information also in other places (e.g. splash
  screen)
0.8
Philip Kaufmann 12 years ago
parent
commit
ec3cac6631
  1. 6
      src/clientversion.h
  2. 7
      src/qt/aboutdialog.cpp

6
src/clientversion.h

@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
#define CLIENTVERSION_H
//
// client versioning
// client versioning and copyright year
//
// These need to be macros, as version.cpp's and bitcoin-qt.rc's voodoo requires it
@ -14,6 +14,10 @@ @@ -14,6 +14,10 @@
// Set to true for release, false for prerelease or test build
#define CLIENT_VERSION_IS_RELEASE false
// Copyright year (2009-this)
// Todo: update this when changing our copyright comments in the source
#define COPYRIGHT_YEAR 2013
// Converts the parameter X to a string after macro replacement on X has been performed.
// Don't merge these into one macro!
#define STRINGIZE(X) DO_STRINGIZE(X)

7
src/qt/aboutdialog.cpp

@ -2,10 +2,7 @@ @@ -2,10 +2,7 @@
#include "ui_aboutdialog.h"
#include "clientmodel.h"
// Copyright year (2009-this)
// Todo: update this when changing our copyright comments in the source
const int ABOUTDIALOG_COPYRIGHT_YEAR = 2013;
#include "clientversion.h"
AboutDialog::AboutDialog(QWidget *parent) :
QDialog(parent),
@ -14,7 +11,7 @@ AboutDialog::AboutDialog(QWidget *parent) : @@ -14,7 +11,7 @@ AboutDialog::AboutDialog(QWidget *parent) :
ui->setupUi(this);
// Set current copyright year
ui->copyrightLabel->setText(tr("Copyright") + QString(" © ") + tr("2009-%1 The Bitcoin developers").arg(ABOUTDIALOG_COPYRIGHT_YEAR));
ui->copyrightLabel->setText(tr("Copyright") + QString(" © ") + tr("2009-%1 The Bitcoin developers").arg(COPYRIGHT_YEAR));
}
void AboutDialog::setModel(ClientModel *model)

Loading…
Cancel
Save