~ubuntu-branches/ubuntu/wily/smplayer/wily

« back to all changes in this revision

Viewing changes to src/old-code/aboutdialog.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Maia Kozheva
  • Date: 2009-03-31 23:05:43 UTC
  • mfrom: (1.2.2 upstream)
  • mto: This revision was merged to the branch mainline in revision 14.
  • Revision ID: james.westby@ubuntu.com-20090331230543-0h2hfwpwlu9opbv2
* New upstream release. (Closes: #523791)
  - Reworked subtitle font preferences. (Closes: #503295)
  - No longer installs qt_fr.qm. (Closes: #486314)
* debian/control:
  - Bumped Standards-Version to 3.8.1.
  - Changed maintainer name (still the same person and GPG key).
  - Changed section to video.
  - Build-depend on zlib1g-dev for findsubtitles.
  - Require Qt >= 4.3 per readme.
  - Added ${misc:Depends}.
  - Make smplayer-translations depend on smplayer and smplayer recommend
    smplayer-translations, not the other way round. (Closes: #489375)
* debian/copyright:
  - Significantly expanded per-file with new upstream authors.
* debian/rules:
  - Make make use correct uic in install.
  - Clean svn_revision.
  - Removed get-orig-source - not needed with uscan --repack.
* debian/patches/01_gl_translation.patch:
  - Added patch to fix lrelease error on smplayer_gl.ts.
* Added debian/README.source for simple-patchsys.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*  smplayer, GUI front-end for mplayer.
2
 
    Copyright (C) 2006-2008 Ricardo Villalba <rvm@escomposlinux.org>
3
 
 
4
 
    This program is free software; you can redistribute it and/or modify
5
 
    it under the terms of the GNU General Public License as published by
6
 
    the Free Software Foundation; either version 2 of the License, or
7
 
    (at your option) any later version.
8
 
 
9
 
    This program is distributed in the hope that it will be useful,
10
 
    but WITHOUT ANY WARRANTY; without even the implied warranty of
11
 
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
 
    GNU General Public License for more details.
13
 
 
14
 
    You should have received a copy of the GNU General Public License
15
 
    along with this program; if not, write to the Free Software
16
 
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17
 
*/
18
 
 
19
 
#include "aboutdialog.h"
20
 
 
21
 
#include <QLabel>
22
 
#include <QTextEdit>
23
 
#include <QPushButton>
24
 
#include <QLayout>
25
 
#include <QDialogButtonBox>
26
 
 
27
 
#include "images.h"
28
 
#include "version.h"
29
 
 
30
 
AboutDialog::AboutDialog(QWidget * parent, Qt::WindowFlags f)
31
 
        : QDialog(parent, f) 
32
 
{
33
 
        setWindowTitle( tr("About SMPlayer") );
34
 
 
35
 
        logo = new QLabel(this);
36
 
        logo->setPixmap( Images::icon("logo", 64) );
37
 
 
38
 
        intro = new QLabel(this);
39
 
        intro->setWordWrap(true);
40
 
 
41
 
        foot = new QLabel(this);
42
 
        foot->setOpenExternalLinks(true);
43
 
 
44
 
        credits = new QTextEdit(this);
45
 
        credits->setReadOnly(true);
46
 
        credits->setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Preferred );
47
 
 
48
 
        ok_button = new QDialogButtonBox( QDialogButtonBox::Ok );
49
 
        connect( ok_button, SIGNAL(accepted()), this, SLOT(accept()) );
50
 
 
51
 
        QVBoxLayout * lright = new QVBoxLayout;
52
 
        lright->addWidget( intro );
53
 
        lright->addWidget( credits );
54
 
        lright->addWidget( foot );
55
 
 
56
 
        QVBoxLayout * lleft = new QVBoxLayout;
57
 
        lleft->addWidget( logo );
58
 
        lleft->addStretch(1);
59
 
        
60
 
        QHBoxLayout * lmain = new QHBoxLayout;
61
 
        lmain->addLayout( lleft );
62
 
        lmain->addLayout( lright );
63
 
 
64
 
        QHBoxLayout * lbutton = new QHBoxLayout;
65
 
        lbutton->addStretch(1);
66
 
        lbutton->addWidget( ok_button );
67
 
        lbutton->addStretch(1);
68
 
 
69
 
        QVBoxLayout * lwidget = new QVBoxLayout(this);
70
 
        lwidget->addLayout( lmain );
71
 
        //lwidget->addWidget( foot );
72
 
        lwidget->addLayout( lbutton );
73
 
 
74
 
        intro->setText( 
75
 
                "<b>SMPlayer</b> &copy; 2006-2008 RVM &lt;rvm@escomposlinux.org&gt;<br><br>"
76
 
                "<b>" + tr("Version: %1").arg(smplayerVersion()) + "</b><br>" +
77
 
/*
78
 
#if KDE_SUPPORT
79
 
        tr("Compiled with KDE support") + "<br>" +
80
 
#endif
81
 
*/
82
 
        "<br>" +
83
 
        tr("Compiled with Qt %1").arg(QT_VERSION_STR) + "<br><br>" 
84
 
                "<i>" +
85
 
                tr("This program is free software; you can redistribute it and/or modify "
86
 
            "it under the terms of the GNU General Public License as published by "
87
 
            "the Free Software Foundation; either version 2 of the License, or "
88
 
            "(at your option) any later version.") + "</i>");
89
 
 
90
 
        credits->setText(
91
 
                 tr("Translators:") + 
92
 
         "<ul>" +
93
 
         trad(tr("German"), "Henrikx") + 
94
 
                 trad(tr("Slovak"), "Sweto &lt;peter.mendel@gmail.com&gt;") +
95
 
                 trad(tr("Italian"), "Giancarlo Scola &lt;giancarlo@codexcoop.it&gt;") +
96
 
         trad(tr("French"), tr("%1, %2 and %3")
97
 
                        .arg("Olivier g &lt;1got@caramail.com&gt;")
98
 
                        .arg("Temet &lt;goondy@free.fr&gt;")
99
 
                        .arg("Kud Gray &lt;kud.gray@gmail.com&gt;") ) +
100
 
                 trad(tr("Simplified-Chinese"), "Tim Green &lt;iamtimgreen@gmail.com&gt;") +
101
 
         trad(tr("Russian"), tr("%1 and %2")
102
 
            .arg("Yurkovsky Andrey &lt;anyr@tut.by&gt;")
103
 
            .arg(QString::fromUtf8("Белый Владимир &lt;wiselord1983@gmail.com&gt;")))+ 
104
 
         trad(tr("Hungarian"), "Charles Barcza &lt;kbarcza@blackpanther.hu&gt;") + 
105
 
         trad(tr("Polish"), tr("%1 and %2")
106
 
            .arg("qla &lt;qla0@vp.pl&gt;")
107
 
            .arg("Jarek &lt;ajep9691@wp.pl&gt;") ) +
108
 
         trad(tr("Japanese"), "Nardog &lt;nardog@e2umail.com&gt;") + 
109
 
         trad(tr("Dutch"), "Wesley S. &lt;wesley@ubuntu-nl.org&gt;") + 
110
 
         trad(tr("Ukrainian"), "Motsyo Gennadi &lt;drool@altlinux.ru&gt;") + 
111
 
         trad(tr("Portuguese - Brazil"), "Ventura &lt;ventura.barbeiro@terra.com.br&gt;") + 
112
 
         trad(tr("Georgian"), "George Machitidze &lt;giomac@gmail.com&gt;") + 
113
 
         trad(tr("Czech"), QString::fromUtf8("Martin Dvořák &lt;martin.dvorak@centrum.cz&gt;")) +
114
 
         trad(tr("Bulgarian"), "&lt;marzeliv@mail.bg&gt;") +
115
 
         trad(tr("Turkish"), "alper er &lt;alperer@gmail.com&gt;") +
116
 
         trad(tr("Swedish"), "Leif Larsson &lt;leif.larsson@gmail.com&gt;") +
117
 
         trad(tr("Serbian"), "Kunalagon Umuhanik &lt;kunalagon@gmail.com&gt;") + 
118
 
         trad(tr("Traditional Chinese"), "Hoopoe &lt;dai715.tw@yahoo.com.tw&gt;") + 
119
 
         trad(tr("Romanian"), "DoruH &lt;doruhushhush@hotmail.com&gt;") + 
120
 
         trad(tr("Portuguese - Portugal"), "Waxman &lt;waxman.pt@gmail.com&gt;") +
121
 
         trad(tr("Greek"), "my80s &lt;wamy80s@gmail.com&gt;") +
122
 
         trad(tr("Finnish"), "peeaivo &lt;peeaivo@gmail.com&gt;") +
123
 
         "</ul>" +
124
 
                 tr("Logo designed by %1").arg("Charles Barcza &lt;kbarcza@blackpanther.hu&gt;") +
125
 
         "<br>"
126
 
                );
127
 
 
128
 
        QString url;
129
 
        /*
130
 
        #ifdef Q_OS_WIN
131
 
        url = tr("http://smplayer.sourceforge.net/en/windows/download.php",
132
 
          "If the web page is translated into your language you can "
133
 
          "change the URL so it points to the download page in the translation."
134
 
          "Otherwise leave as is.");
135
 
        #else
136
 
        url = tr("http://smplayer.sourceforge.net/en/linux/download.php",
137
 
          "If the web page is translated into your language you can "
138
 
          "change the URL so it points to the download page in the translation."
139
 
          "Otherwise leave as is.");
140
 
        #endif
141
 
        */
142
 
        url = "http://smplayer.sourceforge.net";
143
 
        foot->setText(
144
 
                 tr("Get updates at: %1")
145
 
         .arg("<br><a href=\"" + url + "\">" + url +"</a>") );
146
 
 
147
 
        /*
148
 
        adjustSize();
149
 
        setFixedSize( sizeHint() );
150
 
        */
151
 
}
152
 
 
153
 
AboutDialog::~AboutDialog() {
154
 
}
155
 
 
156
 
QString AboutDialog::trad(const QString & lang, const QString & author) {
157
 
        return "<li>"+ tr("<b>%1</b>: %2").arg(lang).arg(author) + "</li>";
158
 
}
159
 
 
160
 
#include "moc_aboutdialog.cpp"