From 52089355a8e65f00fb31bdc8e0c2882c6c331eff Mon Sep 17 00:00:00 2001 From: tariq Date: Fri, 17 Feb 2006 10:13:32 +0000 Subject: [PATCH] clear entry selection after current group changed, keep unkown metastreams git-svn-id: https://svn.code.sf.net/p/keepassx/code/trunk@46 b624d157-de02-0410-bad0-e51aec6abb33 --- src/PwManager.cpp | 20 ++++++++------------ src/PwManager.h | 2 ++ src/mainwindow.cpp | 4 ++++ 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/src/PwManager.cpp b/src/PwManager.cpp index 4d18461..865f3bb 100755 --- a/src/PwManager.cpp +++ b/src/PwManager.cpp @@ -217,7 +217,8 @@ delete [] buffer; for(int i=0;iAdd Metastreams +Entries+=UnkownMetaStreams; ///@FIXME ID conflicts??? + FileSize=DB_HEADER_SIZE; // Get the size of all groups (94 Byte + length of the name string) for(int i = 0; i < Groups.size(); i++){ diff --git a/src/PwManager.h b/src/PwManager.h index 87c2347..cd68b52 100755 --- a/src/PwManager.h +++ b/src/PwManager.h @@ -78,6 +78,7 @@ public: private: bool IsMetaStream(CEntry& Entry); + bool parseMetaStream(const CEntry& Entry); void transformKey(Q_UINT8* src,Q_UINT8* dst,Q_UINT8* seed,int rounds); bool readHeader(char* raw); bool isGroupIdInUse(Q_UINT32 GroupID); @@ -86,6 +87,7 @@ private: Q_UINT32 getNewEntrySid(); bool convHexToBinaryKey(char* HexKey, char* dst); QStringList Errors; + QList UnkownMetaStreams; }; diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 620399e..7f68992 100755 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -563,6 +563,10 @@ if(EntryView->selectedItems().size()>1) void KeepassMainWindow::OnGroupSelectionChanged(){ Q_ASSERT(GroupView->selectedItems().size()<=1); + +while(EntryView->selectedItems().size()){ + EntryView->setItemSelected(EntryView->selectedItems()[0],false);} + if(GroupView->selectedItems().size()==0) setStateGroupSelected(NONE); if(GroupView->selectedItems().size()==1){