source: smplayer/trunk/src/version.cpp@ 188

Last change on this file since 188 was 188, checked in by Silvan Scherrer, 8 years ago

SMPlayer: update trunk to version 17.1.0

  • Property svn:eol-style set to LF
File size: 1.8 KB
Line 
1/* smplayer, GUI front-end for mplayer.
2 Copyright (C) 2006-2017 Ricardo Villalba <rvm@users.sourceforge.net>
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 "version.h"
20#include <QObject>
21
22#define USE_SVN_VERSIONS 1
23#define DEVELOPMENT_VERSION 0
24
25#define VERSION "17.1.0"
26
27#if USE_SVN_VERSIONS && DEVELOPMENT_VERSION
28#include <svn_revision.h>
29#else
30#define SVN_REVISION "8380"
31#endif
32
33#ifdef Q_OS_WIN
34#if defined(_WIN64)
35#define SMPWIN_ARCH "(64-bit)"
36#elif defined(_WIN32) && !defined(_WIN64)
37#define SMPWIN_ARCH "(32-bit)"
38#endif
39#endif
40
41QString Version::printable() {
42#if USE_SVN_VERSIONS
43#ifdef Q_OS_WIN
44 return QObject::tr("%1 (revision %2) %3").arg(VERSION).arg(SVN_REVISION).arg(SMPWIN_ARCH);
45#else
46 return QObject::tr("%1 (revision %2)").arg(VERSION).arg(SVN_REVISION);
47#endif
48#else
49#ifdef Q_OS_WIN
50 return QString(QString(VERSION) + " " + QString(SMPWIN_ARCH));
51#else
52 return QString(VERSION);
53#endif
54#endif
55}
56
57QString Version::stable() {
58 return QString(VERSION);
59}
60
61QString Version::revision() {
62 return QString(SVN_REVISION);
63}
64
65bool Version::is_unstable() {
66 return (DEVELOPMENT_VERSION == 1);
67}
Note: See TracBrowser for help on using the repository browser.