diff options
author | Saturn&Eric <[email protected]> | 2024-05-11 17:18:36 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2024-05-11 17:18:36 +0000 |
commit | f909f2c4c35b187eb165ec5545e35d54c6d92bf3 (patch) | |
tree | 428fe9e63ecae6bb93be6f20cd2b1ee9b29ffd8d /src/core/utils/LocalizedUtils.cpp | |
parent | Merge pull request #145 from jermanuts/jermanuts-wizard-links-update (diff) | |
parent | fix: remove qt5compat and redirect dll output path of modules (diff) | |
download | GpgFrontend-f909f2c4c35b187eb165ec5545e35d54c6d92bf3.tar.gz GpgFrontend-f909f2c4c35b187eb165ec5545e35d54c6d92bf3.zip |
Merge pull request #148 from saturneric/develop
Develop 2.1.3.1
Diffstat (limited to 'src/core/utils/LocalizedUtils.cpp')
-rw-r--r-- | src/core/utils/LocalizedUtils.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/utils/LocalizedUtils.cpp b/src/core/utils/LocalizedUtils.cpp index 6c020ed7..e5c9b434 100644 --- a/src/core/utils/LocalizedUtils.cpp +++ b/src/core/utils/LocalizedUtils.cpp @@ -32,7 +32,12 @@ namespace GpgFrontend { -auto GetFormatedDateByTimestamp(time_t timestamp) -> QString { +auto GetLocalizedDateByTimestamp(time_t timestamp) -> QString { return QLocale().toString(QDateTime::fromSecsSinceEpoch(timestamp)); } + +auto GetUTCDateByTimestamp(time_t timestamp) -> QString { + return QLocale().toString(QDateTime::fromSecsSinceEpoch(timestamp).toUTC()); +} + } // namespace GpgFrontend |