[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdeutils/kgpg
From:       Jean-Baptiste Mardelle <bj () altern ! org>
Date:       2005-02-03 14:20:54
Message-ID: 20050203142054.D52461D04D () office ! kde ! org
[Download RAW message or body]

CVS commit by mardelle: 

fix key selection issue in file mode


  M +7 -12     popuppublic.cpp   1.53


--- kdeutils/kgpg/popuppublic.cpp  #1.52:1.53
@@ -344,21 +344,16 @@ void popupPublic::refreshkeys()
 void popupPublic::slotpreselect()
 {
-QListViewItem *it;
+QListViewItem *it=NULL;
+if (!keysList->firstChild()) return;
         if (fmode) it=keysList->findItem(KGpgSettings::defaultKey(),2);
-        else {
-                it=keysList->firstChild();
-                if (it==NULL)
-                        return;
-                while (!it->isVisible()) {
-                        it=it->nextSibling();
-                        if (it==NULL)
-                                return;
-                }
-        }
 if (!trusted)
               sort();
+if (fmode) 
+{
+        keysList->clearSelection();
         keysList->setSelected(it,true);
         keysList->setCurrentItem(it);
         keysList->ensureItemVisible(it);
+}       
 emit keyListFilled();
 }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic