diff --git a/src/forms/EditEntryDlg.ui b/src/forms/EditEntryDlg.ui
index 823efb3..95272c3 100644
--- a/src/forms/EditEntryDlg.ui
+++ b/src/forms/EditEntryDlg.ui
@@ -20,18 +20,12 @@
true
-
- 6
-
-
+
6
-
-
- 6
-
-
+
6
-
@@ -240,6 +234,12 @@
-
+
+
+ 0
+ 40
+
+
true
@@ -282,7 +282,9 @@
-
+
+
+
@@ -298,7 +300,9 @@
-
+
+
+
@@ -314,7 +318,9 @@
-
+
+
+
@@ -424,7 +430,7 @@
QSizePolicy::Fixed
-
+
100
20
@@ -460,7 +466,7 @@
Qt::Horizontal
- QDialogButtonBox::Cancel|QDialogButtonBox::NoButton|QDialogButtonBox::Ok
+ QDialogButtonBox::Cancel|QDialogButtonBox::Ok
@@ -472,7 +478,7 @@
QSizePolicy::Minimum
-
+
20
50
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index d3a80ee..5162e9a 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -660,7 +660,7 @@ void KeepassMainWindow::updateDetailView(){
templ.replace("%lastmod%",entry->lastMod().toString(Qt::DefaultLocaleShortDate));
templ.replace("%lastaccess%",entry->lastAccess().toString(Qt::DefaultLocaleShortDate));
templ.replace("%expire%",entry->expire().toString(Qt::DefaultLocaleShortDate));
- templ.replace("%comment%",entry->comment());
+ templ.replace("%comment%",entry->comment().replace("\n","
"));
templ.replace("%attachment%",entry->binaryDesc());
if(entry->expire()!=Date_Never){
@@ -715,100 +715,105 @@ void KeepassMainWindow::updateDetailView(){
void KeepassMainWindow::setStateEntrySelected(SelectionState s){
-EntrySelection=s;
-if(GroupSelection == NONE || GroupSelection == SINGLE)
-switch(EntrySelection){
- case NONE:
- EditPasswordToClipboardAction->setEnabled(false);
- EditUsernameToClipboardAction->setEnabled(false);
- EditOpenUrlAction->setEnabled(false);
- EditSaveAttachmentAction->setEnabled(false);
- EditEditEntryAction->setEnabled(false);
- EditCloneEntryAction->setEnabled(false);
- EditCloneEntryAction->setText(tr("Clone Entry"));
- EditDeleteEntryAction->setEnabled(false);
- EditDeleteEntryAction->setText(tr("Delete Entry"));
+ EntrySelection = s;
+ if (GroupSelection == NONE || GroupSelection == SINGLE){
+ switch (EntrySelection){
+ case NONE:
+ EditPasswordToClipboardAction->setEnabled(false);
+ EditUsernameToClipboardAction->setEnabled(false);
+ EditOpenUrlAction->setEnabled(false);
+ EditSaveAttachmentAction->setEnabled(false);
+ EditEditEntryAction->setEnabled(false);
+ EditCloneEntryAction->setEnabled(false);
+ EditCloneEntryAction->setText(tr("Clone Entry"));
+ EditDeleteEntryAction->setEnabled(false);
+ EditDeleteEntryAction->setText(tr("Delete Entry"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(false);
+ EditAutoTypeAction->setEnabled(false);
#endif
- break;
- case SINGLE:
- EditPasswordToClipboardAction->setEnabled(true);
- EditUsernameToClipboardAction->setEnabled(true);
- EditOpenUrlAction->setEnabled(true);
- EditSaveAttachmentAction->setEnabled(((EntryViewItem*)(EntryView->selectedItems()[0]))->EntryHandle->binarySize() > 0);
- EditEditEntryAction->setEnabled(true);
- EditCloneEntryAction->setEnabled(true);
- EditCloneEntryAction->setText(tr("Clone Entry"));
- EditDeleteEntryAction->setEnabled(true);
- EditDeleteEntryAction->setText(tr("Delete Entry"));
+ break;
+ case SINGLE:
+ EditPasswordToClipboardAction->setEnabled(true);
+ EditUsernameToClipboardAction->setEnabled(true);
+ EditOpenUrlAction->setEnabled(true);
+ EditSaveAttachmentAction->setEnabled(((EntryViewItem*)(EntryView->selectedItems()[0]))->EntryHandle->binarySize() > 0);
+ EditEditEntryAction->setEnabled(true);
+ EditCloneEntryAction->setEnabled(true);
+ EditCloneEntryAction->setText(tr("Clone Entry"));
+ EditDeleteEntryAction->setEnabled(true);
+ EditDeleteEntryAction->setText(tr("Delete Entry"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(true);
+ EditAutoTypeAction->setEnabled(true);
#endif
- break;
- case MULTIPLE:
- EditPasswordToClipboardAction->setEnabled(false);
- EditUsernameToClipboardAction->setEnabled(false);
- EditOpenUrlAction->setEnabled(false);
- EditSaveAttachmentAction->setEnabled(false);
- EditEditEntryAction->setEnabled(false);
- EditCloneEntryAction->setEnabled(true);
- EditCloneEntryAction->setText(tr("Clone Entries"));
- EditDeleteEntryAction->setEnabled(true);
- EditDeleteEntryAction->setText(tr("Delete Entries"));
+ break;
+ case MULTIPLE:
+ EditPasswordToClipboardAction->setEnabled(false);
+ EditUsernameToClipboardAction->setEnabled(false);
+ EditOpenUrlAction->setEnabled(false);
+ EditSaveAttachmentAction->setEnabled(false);
+ EditEditEntryAction->setEnabled(false);
+ EditCloneEntryAction->setEnabled(true);
+ EditCloneEntryAction->setText(tr("Clone Entries"));
+ EditDeleteEntryAction->setEnabled(true);
+ EditDeleteEntryAction->setText(tr("Delete Entries"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(false);
+ EditAutoTypeAction->setEnabled(false);
#endif
- break;
- default: Q_ASSERT(false);
-}
-else if(GroupSelection == SEARCHGROUP)
-switch(EntrySelection){
- case NONE:
- EditUsernameToClipboardAction->setEnabled(false);
- EditPasswordToClipboardAction->setEnabled(false);
- EditOpenUrlAction->setEnabled(false);
- EditSaveAttachmentAction->setEnabled(false);
- EditEditEntryAction->setEnabled(false);
- EditCloneEntryAction->setEnabled(false);
- EditCloneEntryAction->setText(tr("Clone Entry"));
- EditDeleteEntryAction->setEnabled(false);
- EditDeleteEntryAction->setText(tr("Delete Entry"));
+ break;
+ default:
+ Q_ASSERT(false);
+ }
+ }
+ else if (GroupSelection == SEARCHGROUP){
+ switch(EntrySelection){
+ case NONE:
+ EditUsernameToClipboardAction->setEnabled(false);
+ EditPasswordToClipboardAction->setEnabled(false);
+ EditOpenUrlAction->setEnabled(false);
+ EditSaveAttachmentAction->setEnabled(false);
+ EditEditEntryAction->setEnabled(false);
+ EditCloneEntryAction->setEnabled(false);
+ EditCloneEntryAction->setText(tr("Clone Entry"));
+ EditDeleteEntryAction->setEnabled(false);
+ EditDeleteEntryAction->setText(tr("Delete Entry"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(false);
+ EditAutoTypeAction->setEnabled(false);
#endif
- break;
- case SINGLE:
- EditUsernameToClipboardAction->setEnabled(true);
- EditPasswordToClipboardAction->setEnabled(true);
- EditOpenUrlAction->setEnabled(true);
- EditSaveAttachmentAction->setEnabled(((EntryViewItem*)(EntryView->selectedItems()[0]))->EntryHandle->binarySize() > 0);
- EditEditEntryAction->setEnabled(true);
- EditCloneEntryAction->setEnabled(false);
- EditCloneEntryAction->setText(tr("Clone Entry"));
- EditDeleteEntryAction->setEnabled(true);
- EditDeleteEntryAction->setText(tr("Delete Entry"));
+ break;
+ case SINGLE:
+ EditUsernameToClipboardAction->setEnabled(true);
+ EditPasswordToClipboardAction->setEnabled(true);
+ EditOpenUrlAction->setEnabled(true);
+ EditSaveAttachmentAction->setEnabled(((EntryViewItem*)(EntryView->selectedItems()[0]))->EntryHandle->binarySize() > 0);
+ EditEditEntryAction->setEnabled(true);
+ EditCloneEntryAction->setEnabled(false);
+ EditCloneEntryAction->setText(tr("Clone Entry"));
+ EditDeleteEntryAction->setEnabled(true);
+ EditDeleteEntryAction->setText(tr("Delete Entry"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(true);
+ EditAutoTypeAction->setEnabled(true);
#endif
- break;
- case MULTIPLE:
- EditUsernameToClipboardAction->setEnabled(false);
- EditPasswordToClipboardAction->setEnabled(false);
- EditOpenUrlAction->setEnabled(false);
- EditSaveAttachmentAction->setEnabled(false);
- EditEditEntryAction->setEnabled(false);
- EditCloneEntryAction->setEnabled(false);
- EditCloneEntryAction->setText(tr("Clone Entries"));
- EditDeleteEntryAction->setEnabled(true);
- EditDeleteEntryAction->setText(tr("Delete Entries"));
+ break;
+ case MULTIPLE:
+ EditUsernameToClipboardAction->setEnabled(false);
+ EditPasswordToClipboardAction->setEnabled(false);
+ EditOpenUrlAction->setEnabled(false);
+ EditSaveAttachmentAction->setEnabled(false);
+ EditEditEntryAction->setEnabled(false);
+ EditCloneEntryAction->setEnabled(false);
+ EditCloneEntryAction->setText(tr("Clone Entries"));
+ EditDeleteEntryAction->setEnabled(true);
+ EditDeleteEntryAction->setText(tr("Delete Entries"));
#ifdef AUTOTYPE
- EditAutoTypeAction->setEnabled(false);
+ EditAutoTypeAction->setEnabled(false);
#endif
- break;
- default: Q_ASSERT(false);
-}
-else Q_ASSERT(false);
+ break;
+ default:
+ Q_ASSERT(false);
+ }
+ }
+ else
+ Q_ASSERT(false);
}