diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ed3ba87d5..838c32f58 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -131,6 +131,7 @@ set(keepassx_FORMS gui/entry/EditEntryWidgetHistory.ui gui/entry/EditEntryWidgetMain.ui gui/entry/EditEntryWidgetNotes.ui + gui/group/EditGroupWidgetAdvanced.ui gui/group/EditGroupWidgetMain.ui ) diff --git a/src/gui/group/EditGroupWidget.cpp b/src/gui/group/EditGroupWidget.cpp index 2f7282a80..15ab1e65b 100644 --- a/src/gui/group/EditGroupWidget.cpp +++ b/src/gui/group/EditGroupWidget.cpp @@ -16,6 +16,7 @@ */ #include "EditGroupWidget.h" +#include "ui_EditGroupWidgetAdvanced.h" #include "ui_EditGroupWidgetMain.h" #include "ui_EditWidget.h" @@ -25,14 +26,18 @@ EditGroupWidget::EditGroupWidget(QWidget* parent) : EditWidget(parent) , m_mainUi(new Ui::EditGroupWidgetMain()) + , m_advancedUi(new Ui::EditGroupWidgetAdvanced()) , m_editGroupWidgetMain(new QWidget()) , m_editGroupWidgetIcons(new EditWidgetIcons()) + , m_editGroupWidgetAdvanced(new QWidget()) , m_group(0) { m_mainUi->setupUi(m_editGroupWidgetMain); + m_advancedUi->setupUi(m_editGroupWidgetAdvanced); add(tr("Group"), m_editGroupWidgetMain); add(tr("Icon"), m_editGroupWidgetIcons); + add(tr("Advanced"), m_editGroupWidgetAdvanced); QFont labelHeaderFont = headlineLabel()->font(); labelHeaderFont.setBold(true); @@ -65,6 +70,14 @@ void EditGroupWidget::loadGroup(Group* group, bool create, Database* database) m_mainUi->editNotes->setPlainText(m_group->notes()); m_mainUi->expireCheck->setChecked(group->timeInfo().expires()); m_mainUi->expireDatePicker->setDateTime(group->timeInfo().expiryTime().toLocalTime()); + QString timeFormat("d MMM yyyy HH:mm:ss"); + m_advancedUi->modifiedEdit->setText( + group->timeInfo().lastModificationTime().toLocalTime().toString(timeFormat)); + m_advancedUi->createdEdit->setText( + group->timeInfo().creationTime().toLocalTime().toString(timeFormat)); + m_advancedUi->accessedEdit->setText( + group->timeInfo().lastAccessTime().toLocalTime().toString(timeFormat)); + m_advancedUi->uuidEdit->setText(group->uuid().toHex()); IconStruct iconStruct; iconStruct.uuid = group->iconUuid(); diff --git a/src/gui/group/EditGroupWidget.h b/src/gui/group/EditGroupWidget.h index 934d08424..761869ff3 100644 --- a/src/gui/group/EditGroupWidget.h +++ b/src/gui/group/EditGroupWidget.h @@ -26,6 +26,7 @@ class EditWidgetIcons; namespace Ui { + class EditGroupWidgetAdvanced; class EditGroupWidgetMain; class EditWidget; } @@ -49,8 +50,10 @@ private Q_SLOTS: private: const QScopedPointer m_mainUi; + const QScopedPointer m_advancedUi; QWidget* const m_editGroupWidgetMain; EditWidgetIcons* const m_editGroupWidgetIcons; + QWidget* const m_editGroupWidgetAdvanced; Group* m_group; Database* m_database; diff --git a/src/gui/group/EditGroupWidgetAdvanced.ui b/src/gui/group/EditGroupWidgetAdvanced.ui new file mode 100644 index 000000000..e8dc22e57 --- /dev/null +++ b/src/gui/group/EditGroupWidgetAdvanced.ui @@ -0,0 +1,104 @@ + + + EditGroupWidgetAdvanced + + + + 0 + 0 + 614 + 328 + + + + Form + + + + QFormLayout::ExpandingFieldsGrow + + + + + + 0 + 0 + + + + false + + + true + + + + + + + + 0 + 0 + + + + false + + + true + + + + + + + Created: + + + + + + + Modified: + + + + + + + Accessed: + + + + + + + false + + + true + + + + + + + Uuid: + + + + + + + false + + + true + + + + + + + +