icon added, about dialog added, translation updated
This commit is contained in:
parent
6c55773dbc
commit
7e8dd80a74
13 changed files with 248 additions and 13 deletions
BIN
5sync.ico
Executable file
BIN
5sync.ico
Executable file
Binary file not shown.
After Width: | Height: | Size: 21 KiB |
BIN
5sync.png
Executable file
BIN
5sync.png
Executable file
Binary file not shown.
After Width: | Height: | Size: 963 B |
40
AboutDialog.cpp
Executable file
40
AboutDialog.cpp
Executable file
|
@ -0,0 +1,40 @@
|
||||||
|
/*****************************************************************************
|
||||||
|
* gta5sync GRAND THEFT AUTO V SYNC
|
||||||
|
* Copyright (C) 2016 Syping
|
||||||
|
*
|
||||||
|
* 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
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include "AboutDialog.h"
|
||||||
|
#include "ui_AboutDialog.h"
|
||||||
|
|
||||||
|
AboutDialog::AboutDialog(QWidget *parent) :
|
||||||
|
QDialog(parent),
|
||||||
|
ui(new Ui::AboutDialog)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
this->setWindowIcon(QIcon(":/img/5sync.png"));
|
||||||
|
aboutStr = ui->labAbout->text();
|
||||||
|
ui->labAbout->setText(aboutStr.arg(qApp->applicationVersion(), QT_VERSION_STR, qVersion()));
|
||||||
|
}
|
||||||
|
|
||||||
|
AboutDialog::~AboutDialog()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
||||||
|
|
||||||
|
void AboutDialog::on_cmdClose_clicked()
|
||||||
|
{
|
||||||
|
this->close();
|
||||||
|
}
|
44
AboutDialog.h
Executable file
44
AboutDialog.h
Executable file
|
@ -0,0 +1,44 @@
|
||||||
|
/*****************************************************************************
|
||||||
|
* gta5sync GRAND THEFT AUTO V SYNC
|
||||||
|
* Copyright (C) 2016 Syping
|
||||||
|
*
|
||||||
|
* 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
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#ifndef ABOUTDIALOG_H
|
||||||
|
#define ABOUTDIALOG_H
|
||||||
|
|
||||||
|
#include <QDialog>
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class AboutDialog;
|
||||||
|
}
|
||||||
|
|
||||||
|
class AboutDialog : public QDialog
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit AboutDialog(QWidget *parent = 0);
|
||||||
|
~AboutDialog();
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void on_cmdClose_clicked();
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::AboutDialog *ui;
|
||||||
|
QString aboutStr;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // ABOUTDIALOG_H
|
114
AboutDialog.ui
Executable file
114
AboutDialog.ui
Executable file
|
@ -0,0 +1,114 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>AboutDialog</class>
|
||||||
|
<widget class="QDialog" name="AboutDialog">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>375</width>
|
||||||
|
<height>250</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>About gta5sync</string>
|
||||||
|
</property>
|
||||||
|
<property name="modal">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="vlAbout">
|
||||||
|
<item>
|
||||||
|
<widget class="QScrollArea" name="saAbout">
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::NoFrame</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Plain</enum>
|
||||||
|
</property>
|
||||||
|
<property name="lineWidth">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="widgetResizable">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<widget class="QWidget" name="saAboutContent">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>357</width>
|
||||||
|
<height>201</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="vlAboutContent">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="labAbout">
|
||||||
|
<property name="text">
|
||||||
|
<string><span style=" font-weight:600;">gta5sync</span><br/><br/>A project for viewing and sync Grand Theft Auto 5 Snapmatic Pictures and Savegames<br/><br/>Project version: %1<br/>Compiled with Qt %2<br/>Running with Qt %3<br/><br/>Copyright © <a href="https://github.com/Syping/">Syping</a> 2016<br/>gta5sync is licensed under <a href="https://www.gnu.org/licenses/gpl-3.0.html#content">GNU GPLv3</a></string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="openExternalLinks">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<spacer name="vsAboutContent">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Vertical</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>0</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="hlButtons">
|
||||||
|
<item>
|
||||||
|
<spacer name="hsButtons">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="cmdClose">
|
||||||
|
<property name="text">
|
||||||
|
<string>Close</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
|
@ -42,6 +42,7 @@ PictureDialog::PictureDialog(ProfileDatabase *profileDB, QWidget *parent) :
|
||||||
ui(new Ui::PictureDialog)
|
ui(new Ui::PictureDialog)
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
this->setWindowIcon(QIcon(":/img/5sync.png"));
|
||||||
windowTitleStr = this->windowTitle();
|
windowTitleStr = this->windowTitle();
|
||||||
jsonDrawString = ui->labJSON->text();
|
jsonDrawString = ui->labJSON->text();
|
||||||
ui->cmdExport->setEnabled(0);
|
ui->cmdExport->setEnabled(0);
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
#include "UserInterface.h"
|
#include "UserInterface.h"
|
||||||
#include "ui_UserInterface.h"
|
#include "ui_UserInterface.h"
|
||||||
#include "ProfileInterface.h"
|
#include "ProfileInterface.h"
|
||||||
|
#include "AboutDialog.h"
|
||||||
#include <QHBoxLayout>
|
#include <QHBoxLayout>
|
||||||
#include <QSpacerItem>
|
#include <QSpacerItem>
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
|
@ -41,6 +42,7 @@ UserInterface::UserInterface(ProfileDatabase *profileDB, CrewDatabase *crewDB, D
|
||||||
ui(new Ui::UserInterface)
|
ui(new Ui::UserInterface)
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
this->setWindowIcon(QIcon(":/img/5sync.png"));
|
||||||
profileOpen = 0;
|
profileOpen = 0;
|
||||||
profileUI = 0;
|
profileUI = 0;
|
||||||
|
|
||||||
|
@ -174,3 +176,13 @@ void UserInterface::openSelectProfile()
|
||||||
{
|
{
|
||||||
// not needed right now
|
// not needed right now
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void UserInterface::on_actionAbout_gta5sync_triggered()
|
||||||
|
{
|
||||||
|
AboutDialog *aboutDialog = new AboutDialog(this);
|
||||||
|
aboutDialog->setWindowFlags(aboutDialog->windowFlags()^Qt::WindowContextHelpButtonHint);
|
||||||
|
aboutDialog->show();
|
||||||
|
aboutDialog->exec();
|
||||||
|
aboutDialog->deleteLater();
|
||||||
|
delete aboutDialog;
|
||||||
|
}
|
||||||
|
|
|
@ -43,6 +43,7 @@ private slots:
|
||||||
void on_actionExit_triggered();
|
void on_actionExit_triggered();
|
||||||
void on_actionSelect_profile_triggered();
|
void on_actionSelect_profile_triggered();
|
||||||
void on_profileButton_clicked();
|
void on_profileButton_clicked();
|
||||||
|
void on_actionAbout_gta5sync_triggered();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ProfileDatabase *profileDB;
|
ProfileDatabase *profileDB;
|
||||||
|
|
2
app.qrc
2
app.qrc
|
@ -6,5 +6,7 @@
|
||||||
</qresource>
|
</qresource>
|
||||||
<qresource prefix="/img">
|
<qresource prefix="/img">
|
||||||
<file>savegame.png</file>
|
<file>savegame.png</file>
|
||||||
|
<file>5sync.ico</file>
|
||||||
|
<file>5sync.png</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
|
2
app.rc
2
app.rc
|
@ -1,4 +1,4 @@
|
||||||
//IDI_ICON1 ICON DISCARDABLE "gta5sync.ico"
|
IDI_ICON1 ICON DISCARDABLE "5sync.ico"
|
||||||
|
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
|
||||||
|
|
|
@ -38,7 +38,8 @@ SOURCES += main.cpp \
|
||||||
ProfileInterface.cpp \
|
ProfileInterface.cpp \
|
||||||
SnapmaticWidget.cpp \
|
SnapmaticWidget.cpp \
|
||||||
SavegameWidget.cpp \
|
SavegameWidget.cpp \
|
||||||
ProfileLoader.cpp
|
ProfileLoader.cpp \
|
||||||
|
AboutDialog.cpp
|
||||||
|
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
SnapmaticPicture.h \
|
SnapmaticPicture.h \
|
||||||
|
@ -53,7 +54,8 @@ HEADERS += \
|
||||||
ProfileInterface.h \
|
ProfileInterface.h \
|
||||||
SnapmaticWidget.h \
|
SnapmaticWidget.h \
|
||||||
SavegameWidget.h \
|
SavegameWidget.h \
|
||||||
ProfileLoader.h
|
ProfileLoader.h \
|
||||||
|
AboutDialog.h
|
||||||
|
|
||||||
FORMS += \
|
FORMS += \
|
||||||
PictureDialog.ui \
|
PictureDialog.ui \
|
||||||
|
@ -61,7 +63,8 @@ FORMS += \
|
||||||
UserInterface.ui \
|
UserInterface.ui \
|
||||||
ProfileInterface.ui \
|
ProfileInterface.ui \
|
||||||
SnapmaticWidget.ui \
|
SnapmaticWidget.ui \
|
||||||
SavegameWidget.ui
|
SavegameWidget.ui \
|
||||||
|
AboutDialog.ui
|
||||||
|
|
||||||
TRANSLATIONS += \
|
TRANSLATIONS += \
|
||||||
gta5sync_de.ts
|
gta5sync_de.ts
|
||||||
|
|
BIN
gta5sync_de.qm
BIN
gta5sync_de.qm
Binary file not shown.
|
@ -1,6 +1,24 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!DOCTYPE TS>
|
<!DOCTYPE TS>
|
||||||
<TS version="2.0" language="de_DE">
|
<TS version="2.0" language="de_DE">
|
||||||
|
<context>
|
||||||
|
<name>AboutDialog</name>
|
||||||
|
<message>
|
||||||
|
<location filename="AboutDialog.ui" line="14"/>
|
||||||
|
<source>About gta5sync</source>
|
||||||
|
<translation>Über gta5sync</translation>
|
||||||
|
</message>
|
||||||
|
<message utf8="true">
|
||||||
|
<location filename="AboutDialog.ui" line="59"/>
|
||||||
|
<source><span style=" font-weight:600;">gta5sync</span><br/><br/>A project for viewing and sync Grand Theft Auto 5 Snapmatic Pictures and Savegames<br/><br/>Project version: %1<br/>Compiled with Qt %2<br/>Running with Qt %3<br/><br/>Copyright © <a href="https://github.com/Syping/">Syping</a> 2016<br/>gta5sync is licensed under <a href="https://www.gnu.org/licenses/gpl-3.0.html#content">GNU GPLv3</a></source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="AboutDialog.ui" line="101"/>
|
||||||
|
<source>Close</source>
|
||||||
|
<translation>Schließen</translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>PictureDialog</name>
|
<name>PictureDialog</name>
|
||||||
<message>
|
<message>
|
||||||
|
@ -48,28 +66,28 @@
|
||||||
<translation>Keine Crew</translation>
|
<translation>Keine Crew</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="PictureDialog.cpp" line="155"/>
|
<location filename="PictureDialog.cpp" line="158"/>
|
||||||
<source>JPEG picture (*.jpg);;Portable Network Graphics (*.png)</source>
|
<source>JPEG picture (*.jpg);;Portable Network Graphics (*.png)</source>
|
||||||
<translation>JPEG Bild (*.jpg);;Portable Network Graphics (*.png)</translation>
|
<translation>JPEG Bild (*.jpg);;Portable Network Graphics (*.png)</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="PictureDialog.cpp" line="156"/>
|
<location filename="PictureDialog.cpp" line="159"/>
|
||||||
<source>Export picture</source>
|
<source>Export picture</source>
|
||||||
<translation>Bild exportieren</translation>
|
<translation>Bild exportieren</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="PictureDialog.cpp" line="232"/>
|
<location filename="PictureDialog.cpp" line="235"/>
|
||||||
<location filename="PictureDialog.cpp" line="238"/>
|
<location filename="PictureDialog.cpp" line="241"/>
|
||||||
<source>Snapmatic Picture Exporter</source>
|
<source>Snapmatic Picture Exporter</source>
|
||||||
<translation>Snapmatic Bild Exporter</translation>
|
<translation>Snapmatic Bild Exporter</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="PictureDialog.cpp" line="232"/>
|
<location filename="PictureDialog.cpp" line="235"/>
|
||||||
<source>Failed to save the picture</source>
|
<source>Failed to save the picture</source>
|
||||||
<translation>Fehlgeschlagen beim Speichern des Bildes</translation>
|
<translation>Fehlgeschlagen beim Speichern des Bildes</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="PictureDialog.cpp" line="238"/>
|
<location filename="PictureDialog.cpp" line="241"/>
|
||||||
<source>No valid file is selected</source>
|
<source>No valid file is selected</source>
|
||||||
<translation>Keine gültige Datei wurde ausgewählt</translation>
|
<translation>Keine gültige Datei wurde ausgewählt</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -213,7 +231,7 @@
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="UserInterface.ui" line="110"/>
|
<location filename="UserInterface.ui" line="110"/>
|
||||||
<location filename="UserInterface.cpp" line="121"/>
|
<location filename="UserInterface.cpp" line="122"/>
|
||||||
<source>Close</source>
|
<source>Close</source>
|
||||||
<translation>Schließen</translation>
|
<translation>Schließen</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -238,12 +256,12 @@
|
||||||
<translation>Strg+P</translation>
|
<translation>Strg+P</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="UserInterface.cpp" line="74"/>
|
<location filename="UserInterface.cpp" line="75"/>
|
||||||
<source>GTA V Folder not found!</source>
|
<source>GTA V Folder not found!</source>
|
||||||
<translation>GTA V Ordner nicht gefunden!</translation>
|
<translation>GTA V Ordner nicht gefunden!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="UserInterface.cpp" line="74"/>
|
<location filename="UserInterface.cpp" line="75"/>
|
||||||
<source>gta5sync</source>
|
<source>gta5sync</source>
|
||||||
<translation>gta5sync</translation>
|
<translation>gta5sync</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
Loading…
Reference in a new issue