From f032f001f32c62cbbb2ec8d1fc3f9ec1eedc66ab Mon Sep 17 00:00:00 2001 From: Florian Geyer Date: Fri, 18 May 2012 15:45:19 +0200 Subject: [PATCH] Remove frames from edit boxes when showing a history entry. --- src/gui/entry/EditEntryWidget.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/gui/entry/EditEntryWidget.cpp b/src/gui/entry/EditEntryWidget.cpp index 7b0f0e8e4..3622fc096 100644 --- a/src/gui/entry/EditEntryWidget.cpp +++ b/src/gui/entry/EditEntryWidget.cpp @@ -140,13 +140,25 @@ void EditEntryWidget::loadEntry(Entry* entry, bool create, bool history, const Q } m_mainUi->titleEdit->setReadOnly(history); + m_mainUi->titleEdit->setFrame(!history); m_mainUi->usernameEdit->setReadOnly(history); + m_mainUi->usernameEdit->setFrame(!history); m_mainUi->urlEdit->setReadOnly(history); + m_mainUi->urlEdit->setFrame(!history); m_mainUi->passwordEdit->setReadOnly(history); + m_mainUi->passwordEdit->setFrame(!history); m_mainUi->passwordRepeatEdit->setReadOnly(history); + m_mainUi->passwordRepeatEdit->setFrame(!history); m_mainUi->expireCheck->setEnabled(!history); m_mainUi->expireDatePicker->setReadOnly(history); + m_mainUi->expireDatePicker->setFrame(!history); m_notesUi->notesEdit->setReadOnly(history); + if (history) { + m_notesUi->notesEdit->setFrameShape(QFrame::NoFrame); + } + else { + m_notesUi->notesEdit->setFrameShape(QFrame::StyledPanel); + } m_advancedUi->addAttachmentButton->setEnabled(!history); m_advancedUi->removeAttachmentButton->setEnabled(!history); m_advancedUi->addAttributeButton->setEnabled(!history);