Browse Source

Bitcoin-Qt: better copyright year handling in AboutDialog

- this change allows us to keep the translation without the need to
  re-translate any string, when we update the copyright year
- copyright symbol is changed to HTML to ensure we get no encoding
  issues and it's removed from the translation string so translators don't
  break it by mistake
miguelfreitas
Philip Kaufmann 12 years ago
parent
commit
8823b4ac3b
  1. 8
      src/qt/aboutdialog.cpp
  2. 1
      src/qt/aboutdialog.h
  3. 5
      src/qt/forms/aboutdialog.ui

8
src/qt/aboutdialog.cpp

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

1
src/qt/aboutdialog.h

@ -18,6 +18,7 @@ public: @@ -18,6 +18,7 @@ public:
~AboutDialog();
void setModel(ClientModel *model);
private:
Ui::AboutDialog *ui;

5
src/qt/forms/aboutdialog.ui

@ -91,7 +91,10 @@ @@ -91,7 +91,10 @@
<cursorShape>IBeamCursor</cursorShape>
</property>
<property name="text">
<string>Copyright © 2009-2012 The Bitcoin developers</string>
<string notr="true">Copyright &amp;copy; 2009-YYYY The Bitcoin developers</string>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set>

Loading…
Cancel
Save