diff -Nru 2048-qt-0.1.5/2048-qt.desktop 2048-qt-0.1.6/2048-qt.desktop --- 2048-qt-0.1.5/2048-qt.desktop 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/2048-qt.desktop 1970-01-01 00:00:00.000000000 +0000 @@ -1,10 +0,0 @@ -#!/usr/bin/env xdg-open -[Desktop Entry] -Name=2048-Qt -GenericName=2048-Qt -Comment=The 2048 number game implemented in Qt -Exec=2048-qt -Icon=2048-qt -Terminal=false -Type=Application -Categories=Game;Math;Qt; diff -Nru 2048-qt-0.1.5/2048-qt.pro 2048-qt-0.1.6/2048-qt.pro --- 2048-qt-0.1.5/2048-qt.pro 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/2048-qt.pro 2015-09-19 05:25:17.000000000 +0000 @@ -2,9 +2,10 @@ QT += qml quick widgets -SOURCES += main.cpp \ - myclass.cpp \ - settings.cpp +SOURCES += \ + src/main.cpp \ + src/myclass.cpp \ + src/settings.cpp lupdate_only { SOURCES += qml/main.qml \ @@ -22,15 +23,15 @@ include(deployment.pri) # Setting the application icon -win32: RC_ICONS = icons/2048-qt.ico # On Windows -macx: ICON = icons/2048-qt.ico # On Mac OSX +win32: RC_ICONS = res/icons/2048-qt.ico # On Windows +macx: ICON = res/icons/2048-qt.ico # On Mac OSX HEADERS += \ - myclass.h \ - settings.h + src/settings.h \ + src/myclass.h -TRANSLATIONS = ts/2048-qt_zh_CN.ts ts/2048-qt_ru_RU.ts +TRANSLATIONS = ts/2048-qt_de_DE.ts ts/2048-qt_fr_FR.ts ts/2048-qt_pl_PL.ts ts/2048-qt_ru_RU.ts ts/2048-qt_zh_CN.ts -VERSION = 0.1.5 +VERSION = 0.1.6 DEFINES += APP_VERSION=\\\"$${VERSION}\\\" diff -Nru 2048-qt-0.1.5/Changelog.md 2048-qt-0.1.6/Changelog.md --- 2048-qt-0.1.5/Changelog.md 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/Changelog.md 2015-09-19 05:25:17.000000000 +0000 @@ -1,5 +1,9 @@ # Changelog +## 2015-09-19 0.1.6 +* added French, German, Polish translation +* put config file in `~/.config/2048-qt/` instead of `~/.config/xiaoyong/` + ## 2014-05-29 0.1.5 * fixed the VERSION issue for Visual Studio * do not translate the language names diff -Nru 2048-qt-0.1.5/debian/2048-qt.desktop 2048-qt-0.1.6/debian/2048-qt.desktop --- 2048-qt-0.1.5/debian/2048-qt.desktop 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/2048-qt.desktop 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -[Desktop Entry] -Type=Application -Version=0.1.5 -Exec=2048-qt -Name=2048-qt -GenericName=2048-qt -Comment=mathematics based puzzle game -Icon=/usr/share/pixmaps/2048-qt.xpm -Terminal=false -StartupNotify=true -Keywords=game;puzzle -Categories=Game;LogicGame diff -Nru 2048-qt-0.1.5/debian/2048-qt.install 2048-qt-0.1.6/debian/2048-qt.install --- 2048-qt-0.1.5/debian/2048-qt.install 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/2048-qt.install 2015-11-26 15:08:52.000000000 +0000 @@ -1,2 +1,2 @@ debian/2048-qt.xpm /usr/share/pixmaps -debian/2048-qt.desktop /usr/share/applications/ +res/2048-qt.desktop /usr/share/applications/ diff -Nru 2048-qt-0.1.5/debian/2048-qt.manpages 2048-qt-0.1.6/debian/2048-qt.manpages --- 2048-qt-0.1.5/debian/2048-qt.manpages 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/2048-qt.manpages 2015-11-26 15:08:52.000000000 +0000 @@ -1 +1 @@ -man/2048-qt.6 +res/man/2048-qt.6 diff -Nru 2048-qt-0.1.5/debian/changelog 2048-qt-0.1.6/debian/changelog --- 2048-qt-0.1.5/debian/changelog 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/changelog 2015-11-26 15:08:52.000000000 +0000 @@ -1,3 +1,25 @@ +2048-qt (0.1.6-1) unstable; urgency=low + + * New upstream release to unstable. (Closes: #781689, #781690) + * Removed patches/FixConfigDir.diff, fixed in upstream release. + * 2048-qt.manpages: Update the manpage location + * Remove 2048-qt.desktop, now it's included within upstream tarball + * Update Copyright dates inside d/copyright + * Create patches/FixDesktop.diff to fix desktop. + + -- Alejandro Garrido Mota Thu, 26 Nov 2015 13:40:03 +0000 + +2048-qt (0.1.5-3) experimental; urgency=medium + + * d/control: + - replace qt5-default metapackage to qtbase5-dev in BDI. + - Push Standards-Version field. + * Set user dir configuration to from ~/.config/xiaoyong/ to + /.config/2048-qt/ (Closes: #767151). + * d/rules: export QT_SELECT=qt5 variable to set QT version. + + -- Alejandro Garrido Mota Sat, 24 Jan 2015 19:33:11 -0430 + 2048-qt (0.1.5-2) unstable; urgency=medium * Add freedesktop menu (d/2048-qt.desktop) (Closes: #759137) diff -Nru 2048-qt-0.1.5/debian/control 2048-qt-0.1.6/debian/control --- 2048-qt-0.1.5/debian/control 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/control 2015-11-26 15:08:52.000000000 +0000 @@ -3,9 +3,9 @@ Priority: optional Maintainer: Alejandro Garrido Mota Build-Depends: debhelper (>= 9), - qt5-default, + qtbase5-dev, qtdeclarative5-dev -Standards-Version: 3.9.5 +Standards-Version: 3.9.6 Homepage: https://github.com/xiaoyong/2048-Qt Vcs-Git: git://github.com/mogaal/2048-qt.git Vcs-Browser: https://github.com/mogaal/2048-qt diff -Nru 2048-qt-0.1.5/debian/copyright 2048-qt-0.1.6/debian/copyright --- 2048-qt-0.1.5/debian/copyright 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/copyright 2015-11-26 15:08:52.000000000 +0000 @@ -23,7 +23,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -Files: fonts/DroidSansFallback.ttf +Files: res/fonts/DroidSansFallback.ttf Copyright: 2005-2012, The Android Open Source Project License: Apache-2.0 Licensed under the Apache License, Version 2.0 (the "License"); you may @@ -39,7 +39,7 @@ '/usr/share/common-licenses/Apache-2.0'. Files: debian/* -Copyright: 2014 Alejandro Garrido Mota +Copyright: 2014-2015 Alejandro Garrido Mota License: GPL-3+ This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by diff -Nru 2048-qt-0.1.5/debian/patches/FixDesktop.diff 2048-qt-0.1.6/debian/patches/FixDesktop.diff --- 2048-qt-0.1.5/debian/patches/FixDesktop.diff 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/debian/patches/FixDesktop.diff 2015-11-26 15:08:52.000000000 +0000 @@ -0,0 +1,20 @@ +Description: Adjust desktop file to debian policy +Author: Alejandro Garrido Mota +Origin: vendor + +Add "Keywords" and remove the interpreter for Desktop file + +Index: 2048-qt/res/2048-qt.desktop +=================================================================== +--- 2048-qt.orig/res/2048-qt.desktop ++++ 2048-qt/res/2048-qt.desktop +@@ -1,4 +1,3 @@ +-#!/usr/bin/env xdg-open + [Desktop Entry] + Name=2048-Qt + GenericName=2048-Qt +@@ -9,3 +8,4 @@ Icon=2048-qt + Terminal=false + Type=Application + Categories=Game;Math;Qt; ++Keywords=game;puzzle;2048;sliding-block-puzzle diff -Nru 2048-qt-0.1.5/debian/patches/series 2048-qt-0.1.6/debian/patches/series --- 2048-qt-0.1.5/debian/patches/series 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/patches/series 2015-11-26 15:08:52.000000000 +0000 @@ -1 +1,2 @@ +FixDesktop.diff FixPathBinary.diff diff -Nru 2048-qt-0.1.5/debian/rules 2048-qt-0.1.6/debian/rules --- 2048-qt-0.1.5/debian/rules 2014-08-31 17:21:45.000000000 +0000 +++ 2048-qt-0.1.6/debian/rules 2015-11-26 15:08:52.000000000 +0000 @@ -1,4 +1,5 @@ #!/usr/bin/make -f +export QT_SELECT=qt5 %: dh $@ diff -Nru 2048-qt-0.1.5/deploy_on_windows.bat 2048-qt-0.1.6/deploy_on_windows.bat --- 2048-qt-0.1.5/deploy_on_windows.bat 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/deploy_on_windows.bat 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -windeployqt.exe --release --qmldir qml/ --no-translations --compiler-runtime release/2048-qt.exe Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/fonts/DroidSansFallback.ttf and /tmp/HM1azNPy1l/2048-qt-0.1.6/fonts/DroidSansFallback.ttf differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/icons/16x16/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/icons/16x16/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/icons/2048-qt.ico and /tmp/HM1azNPy1l/2048-qt-0.1.6/icons/2048-qt.ico differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/icons/256x256/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/icons/256x256/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/icons/32x32/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/icons/32x32/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/icons/48x48/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/icons/48x48/apps/2048-qt.png differ diff -Nru 2048-qt-0.1.5/icons/scalable/apps/2048-qt.svg 2048-qt-0.1.6/icons/scalable/apps/2048-qt.svg --- 2048-qt-0.1.5/icons/scalable/apps/2048-qt.svg 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/icons/scalable/apps/2048-qt.svg 1970-01-01 00:00:00.000000000 +0000 @@ -1,101 +0,0 @@ - - - - - - - - - - - - - image/svg+xml - - - - - - - - - - - 2048 - - - - Qt - - - - diff -Nru 2048-qt-0.1.5/icons/svg2png.sh 2048-qt-0.1.6/icons/svg2png.sh --- 2048-qt-0.1.5/icons/svg2png.sh 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/icons/svg2png.sh 1970-01-01 00:00:00.000000000 +0000 @@ -1,9 +0,0 @@ -#!/bin/bash - -sizes=(16 32 48 256) - -for size in ${sizes[@]}; do - inkscape -z -e 2048-qt_${size}x${size}.png -w $size -h $size scalable/apps/2048-qt.svg - mkdir -p ${size}x${size}/apps - mv 2048-qt_${size}x${size}.png ${size}x${size}/apps/2048-qt.png -done diff -Nru 2048-qt-0.1.5/LICENSE 2048-qt-0.1.6/LICENSE --- 2048-qt-0.1.5/LICENSE 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/LICENSE 2015-09-19 05:25:17.000000000 +0000 @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2014 Qiaoyong Zhong +Copyright (c) 2015 Qiaoyong Zhong Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -18,4 +18,4 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file +SOFTWARE. diff -Nru 2048-qt-0.1.5/main.cpp 2048-qt-0.1.6/main.cpp --- 2048-qt-0.1.5/main.cpp 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/main.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,48 +0,0 @@ -#include -#include -#include -#include -#include -#include "myclass.h" -#include "settings.h" - -int main(int argc, char *argv[]) -{ - QApplication app(argc, argv); - Settings settings(0, "xiaoyong", "2048-Qt"); - settings.setVersion(QString(APP_VERSION)); - - // Localization - QString locale; - if (settings.contains("language")) { - locale = settings.value("language").toString(); - } else { - locale = QLocale::system().name(); - settings.setValue("language", locale); - } - - QTranslator translator; - if (! locale.startsWith("en")) { - QString tsFile = "2048-qt_" + locale; - - if (translator.load(tsFile, ":/ts")) { - qDebug() << "Successfully loaded " + tsFile; - app.installTranslator(&translator); - } else { - qDebug() << "Failed to load " + tsFile; - } - } - - QQmlApplicationEngine engine; - - // Access C++ object "myClass" from QML as "myClass" - MyClass myClass; - engine.rootContext()->setContextProperty("myClass", &myClass); - - // Access C++ object "settings" from QML as "settings" - engine.rootContext()->setContextProperty("settings", &settings); - - engine.load(QUrl(QStringLiteral("qrc:///qml/main.qml"))); - - return app.exec(); -} diff -Nru 2048-qt-0.1.5/man/2048-qt.6 2048-qt-0.1.6/man/2048-qt.6 --- 2048-qt-0.1.5/man/2048-qt.6 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/man/2048-qt.6 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -.TH 2048-QT 6 2014-05-03 -.SH NAME -2048-qt \- the 2048 number game implemented in Qt -.SH SYNOPSIS -.B 2048-qt -.SH DESCRIPTION -Move the number tiles using arrow keys and merge the same numbers. Once a 2048 tile is achieved, you win. -.SH OPTIONS -2048-QT is configured graphically and does not have any commandline options. -.SH FILES -~/.config/xiaoyong/2048-Qt.conf -.RS -Per user configuration file. -.RE -.SH BUGS -If you find a bug, please notify the author. -.SH AUTHOR -Qiaoyong Zhong diff -Nru 2048-qt-0.1.5/myclass.cpp 2048-qt-0.1.6/myclass.cpp --- 2048-qt-0.1.5/myclass.cpp 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/myclass.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,11 +0,0 @@ -#include "myclass.h" -#include - -MyClass::MyClass(QObject *parent) : - QObject(parent) -{ -} - -void MyClass::aboutQt() { - QApplication::aboutQt(); -} diff -Nru 2048-qt-0.1.5/myclass.h 2048-qt-0.1.6/myclass.h --- 2048-qt-0.1.5/myclass.h 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/myclass.h 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -#ifndef MYCLASS_H -#define MYCLASS_H - -#include - -class MyClass : public QObject -{ - Q_OBJECT -public: - explicit MyClass(QObject *parent = 0); - -signals: - -public slots: - void aboutQt(); -}; - -#endif // MYCLASS_H diff -Nru 2048-qt-0.1.5/qml/main.qml 2048-qt-0.1.6/qml/main.qml --- 2048-qt-0.1.5/qml/main.qml 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/qml/main.qml 2015-09-19 05:25:17.000000000 +0000 @@ -102,6 +102,18 @@ } } MenuItem { + text: "Français" + checkable: true + exclusiveGroup: languageSettingsGroup + checked: settings.value("language") === "fr_FR" ? true : false + onTriggered: { + if (settings.value("language") !== "fr_FR") { + settings.setValue("language", "fr_FR"); + changeLanguageDialog.open(); + } + } + } + MenuItem { text: "简体中文" checkable: true exclusiveGroup: languageSettingsGroup @@ -114,6 +126,19 @@ } } MenuItem { + text: "Polski" + checkable: true + exclusiveGroup: languageSettingsGroup + checked: settings.value("language") === "pl_PL" ? true : false + onTriggered: { + if (settings.value("language") !== "pl_PL") { + settings.setValue("language", "pl_PL"); + changeLanguageDialog.open(); + } + } + } + + MenuItem { text: "Русский" checkable: true exclusiveGroup: languageSettingsGroup @@ -125,6 +150,18 @@ } } } + MenuItem { + text: "German" + checkable: true + exclusiveGroup: languageSettingsGroup + checked: settings.value("language") == "de_DE" ? true : false + onTriggered: { + if (settings.value("language") != "de_DE") { + settings.setValue("language", "de_DE"); + changeLanguageDialog.open(); + } + } + } } } @@ -170,7 +207,7 @@ onClicked: parent.forceActiveFocus() } - FontLoader { id: localFont; source: "qrc:///fonts/DroidSansFallback.ttf" } + FontLoader { id: localFont; source: "qrc:///res/fonts/DroidSansFallback.ttf" } Text { id: gameName @@ -319,7 +356,7 @@ MessageDialog { id: aboutDialog title: qsTr("About 2048-Qt") - text: qsTr("

2048-Qt

Version " + settings.getVersion() + "

2014 Qiaoyong Zhong <solary.sh@gmail.com>

") + text: qsTr("

2048-Qt

Version " + settings.getVersion() + "

2015 Qiaoyong Zhong <solary.sh@gmail.com>

") standardButtons: StandardButton.Ok } diff -Nru 2048-qt-0.1.5/qml/Tile.qml 2048-qt-0.1.6/qml/Tile.qml --- 2048-qt-0.1.5/qml/Tile.qml 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/qml/Tile.qml 2015-09-19 05:25:17.000000000 +0000 @@ -14,7 +14,7 @@ property bool runNewTileAnim: false property bool destroyFlag: false - FontLoader { id: localFont; source: "qrc:///fonts/DroidSansFallback.ttf" } + FontLoader { id: localFont; source: "qrc:///res/fonts/DroidSansFallback.ttf" } Text { id: tileLabel diff -Nru 2048-qt-0.1.5/README.md 2048-qt-0.1.6/README.md --- 2048-qt-0.1.5/README.md 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/README.md 2015-09-19 05:25:17.000000000 +0000 @@ -13,6 +13,9 @@ - PRC (天朝) - Multi-language support, currently - English + - French (by [Rémi Verschelde](https://github.com/akien-mga)) + - German (by [Jens John](https://github.com/2ion)) + - Polish (by [Michał Radwański](https://github.com/enedil)) - Russian (by [Sergey Basalaev](https://github.com/SBasalaev)) - Simplified Chinese @@ -51,6 +54,13 @@ sudo apt-get install 2048-qt ``` +### Gentoo +2048-Qt is available from the overlay maintained by [Jorge Pizarro Callejas](https://github.com/jorgicio): +``` +layman -a jorgicio +emerge 2048-qt +``` + ### Ubuntu From Ubuntu 14.10 on, install it through: diff -Nru 2048-qt-0.1.5/res/2048-qt.desktop 2048-qt-0.1.6/res/2048-qt.desktop --- 2048-qt-0.1.5/res/2048-qt.desktop 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/res/2048-qt.desktop 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,11 @@ +#!/usr/bin/env xdg-open +[Desktop Entry] +Name=2048-Qt +GenericName=2048-Qt +Comment=The 2048 number game implemented in Qt +Comment[fr]=Jeu de réflexion et de mathématique +Exec=2048-qt +Icon=2048-qt +Terminal=false +Type=Application +Categories=Game;Math;Qt; Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/fonts/DroidSansFallback.ttf and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/fonts/DroidSansFallback.ttf differ diff -Nru 2048-qt-0.1.5/res/fonts/LICENSE 2048-qt-0.1.6/res/fonts/LICENSE --- 2048-qt-0.1.5/res/fonts/LICENSE 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/res/fonts/LICENSE 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,18 @@ +Copyright (C) 2008 The Android Open Source Project + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + +########## + +This directory contains the fonts for the platform. They are licensed +under the Apache 2 license. Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/icons/16x16/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/icons/16x16/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/icons/2048-qt.ico and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/icons/2048-qt.ico differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/icons/256x256/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/icons/256x256/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/icons/32x32/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/icons/32x32/apps/2048-qt.png differ Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/res/icons/48x48/apps/2048-qt.png and /tmp/HM1azNPy1l/2048-qt-0.1.6/res/icons/48x48/apps/2048-qt.png differ diff -Nru 2048-qt-0.1.5/res/icons/scalable/apps/2048-qt.svg 2048-qt-0.1.6/res/icons/scalable/apps/2048-qt.svg --- 2048-qt-0.1.5/res/icons/scalable/apps/2048-qt.svg 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/res/icons/scalable/apps/2048-qt.svg 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,101 @@ + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + 2048 + + + + Qt + + + + diff -Nru 2048-qt-0.1.5/res/man/2048-qt.6 2048-qt-0.1.6/res/man/2048-qt.6 --- 2048-qt-0.1.5/res/man/2048-qt.6 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/res/man/2048-qt.6 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,18 @@ +.TH 2048-QT 6 2015-09-13 +.SH NAME +2048-qt \- the 2048 number game implemented in Qt +.SH SYNOPSIS +.B 2048-qt +.SH DESCRIPTION +Move the number tiles using arrow keys and merge the same numbers. Once a 2048 tile is achieved, you win. +.SH OPTIONS +2048-QT is configured graphically and does not have any commandline options. +.SH FILES +~/.config/2048-qt/2048-Qt.conf +.RS +Per user configuration file. +.RE +.SH BUGS +If you find a bug, please notify the author. +.SH AUTHOR +Qiaoyong Zhong diff -Nru 2048-qt-0.1.5/resources.qrc 2048-qt-0.1.6/resources.qrc --- 2048-qt-0.1.5/resources.qrc 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/resources.qrc 2015-09-19 05:25:17.000000000 +0000 @@ -1,10 +1,13 @@ - ts/2048-qt_zh_CN.qm + ts/2048-qt_de_DE.qm + ts/2048-qt_fr_FR.qm + ts/2048-qt_pl_PL.qm ts/2048-qt_ru_RU.qm + ts/2048-qt_zh_CN.qm qml/main.qml qml/2048.js qml/Tile.qml - fonts/DroidSansFallback.ttf + res/fonts/DroidSansFallback.ttf diff -Nru 2048-qt-0.1.5/scripts/deploy_on_windows.bat 2048-qt-0.1.6/scripts/deploy_on_windows.bat --- 2048-qt-0.1.5/scripts/deploy_on_windows.bat 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/scripts/deploy_on_windows.bat 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1 @@ +windeployqt.exe --release --qmldir qml/ --no-translations --compiler-runtime release/2048-qt.exe diff -Nru 2048-qt-0.1.5/scripts/svg2png.sh 2048-qt-0.1.6/scripts/svg2png.sh --- 2048-qt-0.1.5/scripts/svg2png.sh 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/scripts/svg2png.sh 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,9 @@ +#!/bin/bash + +sizes=(16 32 48 256) + +for size in ${sizes[@]}; do + inkscape -z -e 2048-qt_${size}x${size}.png -w $size -h $size scalable/apps/2048-qt.svg + mkdir -p ${size}x${size}/apps + mv 2048-qt_${size}x${size}.png ${size}x${size}/apps/2048-qt.png +done diff -Nru 2048-qt-0.1.5/settings.cpp 2048-qt-0.1.6/settings.cpp --- 2048-qt-0.1.5/settings.cpp 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/settings.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,29 +0,0 @@ -#include "settings.h" - -Settings::Settings(QObject *parent, const QString &organization, const QString &application) : - QObject(parent), settings_(new QSettings(organization, application)) { -} - -Settings::~Settings() { - delete settings_; -} - -bool Settings::contains(const QString & key) const { - return settings_->contains(key); -} - -void Settings::setValue(const QString &key, const QVariant &value) { - settings_->setValue(key, value); -} - -QVariant Settings::value(const QString &key, const QVariant &defaultValue) const { - return settings_->value(key, defaultValue); -} - -void Settings::setVersion(QString version) { - appVersion = version; -} - -QString Settings::getVersion() { - return appVersion; -} diff -Nru 2048-qt-0.1.5/settings.h 2048-qt-0.1.6/settings.h --- 2048-qt-0.1.5/settings.h 2014-05-29 14:23:10.000000000 +0000 +++ 2048-qt-0.1.6/settings.h 1970-01-01 00:00:00.000000000 +0000 @@ -1,30 +0,0 @@ -#ifndef SETTINGS_H -#define SETTINGS_H - -#include -#include - -class Settings : public QObject -{ - Q_OBJECT -public: - explicit Settings(QObject *parent = 0, const QString &organization = QString(), const QString &application = QString()); - ~Settings(); - - Q_INVOKABLE void setValue(const QString &key, const QVariant &value); - Q_INVOKABLE QVariant value(const QString &key, const QVariant &defaultValue = QVariant()) const; - Q_INVOKABLE QString getVersion(); - - void setVersion(const QString version); - bool contains(const QString & key) const; - -signals: - -public slots: - -private: - QSettings *settings_; - QString appVersion; -}; - -#endif // SETTINGS_H diff -Nru 2048-qt-0.1.5/src/main.cpp 2048-qt-0.1.6/src/main.cpp --- 2048-qt-0.1.5/src/main.cpp 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/src/main.cpp 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,48 @@ +#include +#include +#include +#include +#include +#include "myclass.h" +#include "settings.h" + +int main(int argc, char *argv[]) +{ + QApplication app(argc, argv); + Settings settings(0, "2048-qt", "2048-Qt"); + settings.setVersion(QString(APP_VERSION)); + + // Localization + QString locale; + if (settings.contains("language")) { + locale = settings.value("language").toString(); + } else { + locale = QLocale::system().name(); + settings.setValue("language", locale); + } + + QTranslator translator; + if (! locale.startsWith("en")) { + QString tsFile = "2048-qt_" + locale; + + if (translator.load(tsFile, ":/ts")) { + qDebug() << "Successfully loaded " + tsFile; + app.installTranslator(&translator); + } else { + qDebug() << "Failed to load " + tsFile; + } + } + + QQmlApplicationEngine engine; + + // Access C++ object "myClass" from QML as "myClass" + MyClass myClass; + engine.rootContext()->setContextProperty("myClass", &myClass); + + // Access C++ object "settings" from QML as "settings" + engine.rootContext()->setContextProperty("settings", &settings); + + engine.load(QUrl(QStringLiteral("qrc:///qml/main.qml"))); + + return app.exec(); +} diff -Nru 2048-qt-0.1.5/src/myclass.cpp 2048-qt-0.1.6/src/myclass.cpp --- 2048-qt-0.1.5/src/myclass.cpp 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/src/myclass.cpp 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,11 @@ +#include "myclass.h" +#include + +MyClass::MyClass(QObject *parent) : + QObject(parent) +{ +} + +void MyClass::aboutQt() { + QApplication::aboutQt(); +} diff -Nru 2048-qt-0.1.5/src/myclass.h 2048-qt-0.1.6/src/myclass.h --- 2048-qt-0.1.5/src/myclass.h 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/src/myclass.h 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,18 @@ +#ifndef MYCLASS_H +#define MYCLASS_H + +#include + +class MyClass : public QObject +{ + Q_OBJECT +public: + explicit MyClass(QObject *parent = 0); + +signals: + +public slots: + void aboutQt(); +}; + +#endif // MYCLASS_H diff -Nru 2048-qt-0.1.5/src/settings.cpp 2048-qt-0.1.6/src/settings.cpp --- 2048-qt-0.1.5/src/settings.cpp 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/src/settings.cpp 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,29 @@ +#include "settings.h" + +Settings::Settings(QObject *parent, const QString &organization, const QString &application) : + QObject(parent), settings_(new QSettings(organization, application)) { +} + +Settings::~Settings() { + delete settings_; +} + +bool Settings::contains(const QString & key) const { + return settings_->contains(key); +} + +void Settings::setValue(const QString &key, const QVariant &value) { + settings_->setValue(key, value); +} + +QVariant Settings::value(const QString &key, const QVariant &defaultValue) const { + return settings_->value(key, defaultValue); +} + +void Settings::setVersion(QString version) { + appVersion = version; +} + +QString Settings::getVersion() { + return appVersion; +} diff -Nru 2048-qt-0.1.5/src/settings.h 2048-qt-0.1.6/src/settings.h --- 2048-qt-0.1.5/src/settings.h 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/src/settings.h 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,30 @@ +#ifndef SETTINGS_H +#define SETTINGS_H + +#include +#include + +class Settings : public QObject +{ + Q_OBJECT +public: + explicit Settings(QObject *parent = 0, const QString &organization = QString(), const QString &application = QString()); + ~Settings(); + + Q_INVOKABLE void setValue(const QString &key, const QVariant &value); + Q_INVOKABLE QVariant value(const QString &key, const QVariant &defaultValue = QVariant()) const; + Q_INVOKABLE QString getVersion(); + + void setVersion(const QString version); + bool contains(const QString & key) const; + +signals: + +public slots: + +private: + QSettings *settings_; + QString appVersion; +}; + +#endif // SETTINGS_H Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/ts/2048-qt_de_DE.qm and /tmp/HM1azNPy1l/2048-qt-0.1.6/ts/2048-qt_de_DE.qm differ diff -Nru 2048-qt-0.1.5/ts/2048-qt_de_DE.ts 2048-qt-0.1.6/ts/2048-qt_de_DE.ts --- 2048-qt-0.1.5/ts/2048-qt_de_DE.ts 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/ts/2048-qt_de_DE.ts 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,136 @@ + + + + + main + + + 2048 Game + 2048 + + + + File + &Datei + + + + + New Game + Neues Spiel + + + + Exit + &Beenden + + + + Settings + &Einstellungen + + + + Labeling + &Beschriftung + + + + 2048 + 2048 + + + + Degree + Grad + + + + Military Rank + Militärsränge + + + + PRC + PRC + + + + Language + &Sprache + + + English + Englisch + + + Simplified Chinese + Vereinfachtes Chinesisch + + + + Help + &Hilfe + + + + About + Über + + + + About Qt + Über &Qt + + + + SCORE + Punkte + + + + BEST + Rekord + + + + Join the numbers and get to the <b>2048 tile</b>! + Kombiniere bis zu einer Summe von <b>2048</b>! + + + + Language Setting Hint + Hinweis zur Spracheinstellung + + + + Please restart the program to make the language setting take effect. + Starten Sie das Programm erneut, um die geänderten Spracheinstellungen zu übernehmen. + + + + About 2048-Qt + Über &2048-Qt + + + + Game Over + Game Over + + + + Game Over! + Game Over! + + + + You Win + Sie gewinnen! + + + + You win! Continue playing? + Sie haben gewonnen! Weiterspielen? + + + Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/ts/2048-qt_fr_FR.qm and /tmp/HM1azNPy1l/2048-qt-0.1.6/ts/2048-qt_fr_FR.qm differ diff -Nru 2048-qt-0.1.5/ts/2048-qt_fr_FR.ts 2048-qt-0.1.6/ts/2048-qt_fr_FR.ts --- 2048-qt-0.1.5/ts/2048-qt_fr_FR.ts 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/ts/2048-qt_fr_FR.ts 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,128 @@ + + + + + main + + + 2048 Game + 2048 + + + + File + Fichier + + + + + New Game + Nouvelle partie + + + + Exit + Quitter + + + + Settings + Paramètres + + + + Labeling + Variante + + + + 2048 + 2048 + + + + Degree + Diplôme (chinois) + + + + Military Rank + Rang militaire (chinois) + + + + PRC + RPC (chinois) + + + + Language + Langue + + + + Help + Aide + + + + About + À propos + + + + About Qt + À propos de Qt + + + + SCORE + SCORE + + + + BEST + RECORD + + + + Join the numbers and get to the <b>2048 tile</b>! + Combinez les nombres pour atteindre <b>2048</b> ! + + + + Language Setting Hint + Information sur le paramétrage de la langue + + + + Please restart the program to make the language setting take effect. + Veuillez redémarrer le programme pour que le changement de langue soit pris en compte. + + + + About 2048-Qt + À propos de 2048-Qt + + + + Game Over + Fin de la partie + + + + Game Over! + Vous avez perdu ! + + + + You Win + Vous avez gagné + + + + You win! Continue playing? + Vous avez atteint l'objectif ! Voulez-vous continuer ? + + + Binary files /tmp/CUInIdu48V/2048-qt-0.1.5/ts/2048-qt_pl_PL.qm and /tmp/HM1azNPy1l/2048-qt-0.1.6/ts/2048-qt_pl_PL.qm differ diff -Nru 2048-qt-0.1.5/ts/2048-qt_pl_PL.ts 2048-qt-0.1.6/ts/2048-qt_pl_PL.ts --- 2048-qt-0.1.5/ts/2048-qt_pl_PL.ts 1970-01-01 00:00:00.000000000 +0000 +++ 2048-qt-0.1.6/ts/2048-qt_pl_PL.ts 2015-09-19 05:25:17.000000000 +0000 @@ -0,0 +1,145 @@ + + + + + main + + + 2048 Game + Gra 2048 + + + + File + Plik + + + + + New Game + Nowa gra + + + + Exit + Wyjdź + + + + Settings + Ustawienia + + + + Labeling + Etykiety + + + + 2048 + 2048 + + + + Degree + Stopień + + + + Military Rank + Ranga wojskowa + + + + PRC + PRC + + + + Language + Język + + + English + Angielski + + + Polish + Polski + + + Russian + Rosyjski + + + Simplified Chinese + Chiński uproszczony + + + + + Help + Pomoc + + + + About + O programie + + + + About Qt + O Qt + + + + SCORE + WYNIK + + + + BEST + NAJLEPSZY + + + + Join the numbers and get to the <b>2048 tile</b>! + Łącz liczby i dotrzyj do <b>kafelka 2048</b>! + + + + Language Setting Hint + Wskazówka odnośnie ustawiania języka + + + + Please restart the program to make the language setting take effect. + Aby zmiana języka była widoczna, proszę uruchomić ponownie program. + + + + About 2048-Qt + O programie 2048-Qt + + + + Game Over + Игра окончена + + + + Game Over! + Gra skończona! + + + + You Win + Wygrałeś + + + + You win! Continue playing? + Wygrałeś! Kontynuować grę? + + +