Skip to content

Commit

Permalink
Improve project configuration files.
Browse files Browse the repository at this point in the history
Set the TS file to update automatically.
Set to automatically generate QM files.
Adjust the configuration file reading path.
Fix the refresh logic of the configuration file.
Set icon for executable file
Improve the about page.
Adjust the configuration file reading and setting related to Key Server.
  • Loading branch information
saturneric committed Jun 18, 2021
1 parent c551649 commit 4bd6e0a
Show file tree
Hide file tree
Showing 36 changed files with 7,497 additions and 12,636 deletions.
2 changes: 1 addition & 1 deletion .idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ find_package(Git QUIET)
if(GIT_FOUND)
execute_process(
COMMAND ${GIT_EXECUTABLE} log -1 --pretty=format:%H
OUTPUT_VARIABLE COMMIT_HASH
OUTPUT_VARIABLE GIT_COMMIT_HASH
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
)
execute_process(
COMMAND ${GIT_EXECUTABLE} symbolic-ref --short -q HEAD
OUTPUT_VARIABLE BRANCH_NAME
OUTPUT_VARIABLE GIT_BRANCH_NAME
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
Expand All @@ -48,10 +48,10 @@ endif()


set(BUILD_VERSION ${PROJECT_VERSION}_${CMAKE_SYSTEM}_${CMAKE_SYSTEM_PROCESSOR}_${CMAKE_BUILD_TYPE})
set(GIT_VERSION ${PROJECT_NAME}_${GIT_COMMIT_HASH}_${GIT_COMMIT_HASH})
set(GIT_VERSION ${GIT_BRANCH_NAME}_${GIT_COMMIT_HASH})
string(TIMESTAMP BUILD_TIMESTAMP "%Y-%m-%d %H:%M:%S")

message("Build Timestamp ${BUILD_TIMESTAMP}")
message(STATUS "Build Timestamp ${BUILD_TIMESTAMP}")
message(STATUS "Build Version ${BUILD_VERSION}")
message(STATUS "Git Version ${GIT_VERSION}")

Expand Down Expand Up @@ -110,7 +110,7 @@ if(LINUX)

endif()

find_package(Qt5 COMPONENTS Core Test Widgets PrintSupport Network REQUIRED)
find_package(Qt5 COMPONENTS Core Test Widgets PrintSupport Network LinguistTools REQUIRED)

add_subdirectory(src)

Expand Down
487 changes: 0 additions & 487 deletions gpg4usb_class_dependencies.graphml

This file was deleted.

Binary file modified gpgfrontend.ico
Binary file not shown.
1 change: 1 addition & 0 deletions gpgfrontend.qrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!DOCTYPE RCC>
<RCC>
<qresource prefix="/">
<file alias="keymgmt.png">resource/icons/keymgmt.png</file>
Expand Down
1 change: 1 addition & 0 deletions gpgfrontend.rc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
IDI_ICON1 ICON DISCARDABLE "gpgfrontend.ico"
8 changes: 4 additions & 4 deletions include/GpgFrontend.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@

#define PROJECT_NAME "GPGFrontend"
#define BUILD_VERSION "1.0.0_Windows-10.0.19042_AMD64_Debug"
#define GIT_VERSION "GPGFrontend__"
#define GIT_VERSION "develop_8d6aad31ebdd6dcf953cba87c5e79d49e48fcf6c"

#define VERSION_MAJOR 1
#define VERSION_MINOR 0
#define VERSION_PATCH 0

#define BUILD_TIMESTAMP "2021-06-18 01:49:12"
#define BUILD_TIMESTAMP "2021-06-18 16:18:23"

#define GIT_BRANCH_NAME ""
#define GIT_COMMIT_HASH ""
#define GIT_BRANCH_NAME "develop"
#define GIT_COMMIT_HASH "8d6aad31ebdd6dcf953cba87c5e79d49e48fcf6c"

#endif //GPGFRONTEND_H_IN
7 changes: 5 additions & 2 deletions include/MainWindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -352,8 +352,11 @@ private slots:
QAction *addPgpHeaderAct; /** Action for adding the PGP header */

QLabel *statusBarIcon; /**< TODO */
QSettings settings; /**< TODO */
KeyList *mKeyList; /**< TODO */

QString appPath;
QSettings settings;
KeyList *mKeyList;

InfoBoardWidget *infoBoard;
Attachments *mAttachments; /**< TODO */
GpgME::GpgContext *mCtx; /**< TODO */
Expand Down
23 changes: 23 additions & 0 deletions include/ui/SettingsDialog.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ Q_OBJECT
void applySettings();

private:

QString appPath;
QSettings settings;

QCheckBox *rememberPasswordCheckBox;
[[maybe_unused]] QCheckBox *importConfirmationcheckBox{};
QCheckBox *saveCheckedKeysCheckBox;
Expand Down Expand Up @@ -73,6 +77,10 @@ Q_OBJECT
void applySettings();

private:

QString appPath;
QSettings settings;

QCheckBox *mimeParseCheckBox;
QCheckBox *mimeQPCheckBox;
QCheckBox *mimeOpenAttachmentCheckBox;
Expand All @@ -95,6 +103,10 @@ Q_OBJECT
void applySettings();

private:

QString appPath;
QSettings settings;

QButtonGroup *iconStyleGroup;
QRadioButton *iconSizeSmall;
QRadioButton *iconSizeMedium;
Expand Down Expand Up @@ -122,6 +134,10 @@ Q_OBJECT
void applySettings();

private:

QString appPath;
QSettings settings;

QComboBox *comboBox;
QLineEdit *newKeyServerEdit;

Expand All @@ -146,6 +162,10 @@ Q_OBJECT
void applySettings();

private:

QString appPath;
QSettings settings;

QCheckBox *steganoCheckBox;

signals:
Expand All @@ -164,6 +184,9 @@ Q_OBJECT
private:
static QString getRelativePath(const QString& dir1, const QString& dir2);

QString appPath;
QSettings settings;

QString defKeydbPath; /** The default keydb path used by gpg4usb */
QString accKeydbPath; /** The currently used keydb path */
QLabel *keydbLabel;
Expand Down
9 changes: 9 additions & 0 deletions include/ui/Wizard.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ Q_OBJECT
private:
GpgME::GpgContext *mCtx;
KeyMgmt *mKeyMgmt;
QString appPath;
QSettings settings;

private slots:

Expand All @@ -75,6 +77,10 @@ Q_OBJECT

[[nodiscard]] int nextId() const override;

private:
QString appPath;
QSettings settings;

private slots:

void slotLangChange(const QString& lang);
Expand Down Expand Up @@ -114,6 +120,9 @@ private slots:
private:
[[nodiscard]] int nextId() const override;

QString appPath;
QSettings settings;

KeyMgmt *mKeyMgmt;
GpgME::GpgContext *mCtx;
QCheckBox *gpg4usbKeyCheckBox;
Expand Down
15 changes: 0 additions & 15 deletions resource/css/default.css

This file was deleted.

Empty file added resource/css/default.qss
Empty file.
Binary file modified resource/icons/key_import.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified resource/icons/keymgmt.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 4bd6e0a

Please sign in to comment.