Bug#602140: konqueror: Cookie policy editor's Delete button wipes out most of the policy entries

2010-11-03 Thread David Fries
Any plans to include some version of the fix in squeeze?  With 8 bug
reports and 20 votes there are multiple people wanting it fixed.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#602140: konqueror: Cookie policy editor's Delete button wipes out most of the policy entries

2010-11-02 Thread David Fries
I have been bitten by the same bug, and I've tracked it down after
restoring the polcy file from backup.  Konqueror is saving only the
entries currently selected by the site policy search instead of all of
them.

Type something in the search like google, modify something in the
dialog so apply is enabled, click apply, look at kcookiejarrc and only
the current list is saved.  Clear the site policy search (as long as
you haven't exited the dialog all the entries are still there), press
apply and all the entries are saved.  

Here's a patch.

From c1604cb669e16a8f08894a79935510351f68f47a Mon Sep 17 00:00:00 2001
From: David Fries da...@fries.net
Date: Tue, 2 Nov 2010 23:48:59 -0500
Subject: [PATCH] kcookiespolicies, save all cookie polcy entries

Without this patch konqueror would only save the cookie polcy entries
that were visible (the first was always saved).  This is because
QTreeWidget-itemBelow() Returns the item visually below the given item.
Hidden items are not visible, but clearly all items should be saved, so
get the item count and save all top level items.
---
 apps/konqueror/settings/kio/kcookiespolicies.cpp |5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/apps/konqueror/settings/kio/kcookiespolicies.cpp 
b/apps/konqueror/settings/kio/kcookiespolicies.cpp
index 17dfe10..d314af4 100644
--- a/apps/konqueror/settings/kio/kcookiespolicies.cpp
+++ b/apps/konqueror/settings/kio/kcookiespolicies.cpp
@@ -397,10 +397,11 @@ void KCookiesPolicies::save()
   QStringList domainConfig;
   QTreeWidgetItem *at = dlg-lvDomainPolicy-topLevelItem(0);
 
-  while( at )
+  // QTreeWidget-itemBelow() skips hidden items, save all of them
+  for(int i=0, stop=dlg-lvDomainPolicy-topLevelItemCount(); istop; ++i)
   {
+at = dlg-lvDomainPolicy-topLevelItem(i);
 
domainConfig.append(QString::fromLatin1(%1:%2).arg(QString(tolerantToAce(at-text(0.arg(m_pDomainPolicy[at]));
-at = dlg-lvDomainPolicy-itemBelow(at);
   }
 
   group.writeEntry(CookieDomainAdvice, domainConfig);
-- 
1.7.1




-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#602140: konqueror: Cookie policy editor's Delete button wipes out most of the policy entries

2010-11-01 Thread Michael Deegan
Package: konqueror
Version: 4:4.4.5-1
Severity: normal

Clicking the Delete button on the site policy editor doesn't just delete
one entry. All-but-one is more likely.

Steps to reproduce:
- Default policy: ask for confirmation
- visit lots of sites
- notice that the list contains lots of entries
- type something in the site policy config's handy Search field
- delete just one of the results
- OK
- go back to cookie site policy settings
- wonder where most of the site policy entries went

-- System Information:
Debian Release: squeeze/sid
  APT prefers stable
  APT policy: (500, 'stable'), (490, 'testing'), (470, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_AU, LC_CTYPE=en_AU (charmap=ISO-8859-1)
Shell: /bin/sh linked to /bin/bash

Versions of packages konqueror depends on:
ii  install-info   4.13a.dfsg.1-6Manage installed documentation in 
ii  kdebase-bin4:4.4.5-1 core binaries for the KDE base app
ii  kdebase-data   4:4.4.5-1 shared data files for the KDE base
ii  kdebase-runtime4:4.4.5-1 runtime components from the offici
ii  libc6  2.11.2-6+squeeze1 Embedded GNU C Library: Shared lib
ii  libkde3support44:4.4.5-1 the KDE 3 Support Library for the 
ii  libkdecore54:4.4.5-1 the KDE Platform Core Library
ii  libkdesu5  4:4.4.5-1 the Console-mode Authentication Li
ii  libkdeui5  4:4.4.5-1 the KDE Platform User Interface Li
ii  libkhtml5  4:4.4.5-1 the KHTML Web Content Rendering En
ii  libkio54:4.4.5-1 the Network-enabled File Managemen
ii  libkonq5   4:4.4.5-1 core libraries for Konqueror
ii  libkonqsidebarplugin4a 4:4.4.5-1 konqueror sidebar plugin library
ii  libkparts4 4:4.4.5-1 the Framework for the KDE Platform
ii  libkutils4 4:4.4.5-1 various utility classes for the KD
ii  libqt4-dbus4:4.6.3-4 Qt 4 D-Bus module
ii  libqt4-qt3support  4:4.6.3-4 Qt 3 compatibility library for Qt 
ii  libqt4-xml 4:4.6.3-4 Qt 4 XML module
ii  libqtcore4 4:4.6.3-4 Qt 4 core module
ii  libqtgui4  4:4.6.3-4 Qt 4 GUI module
ii  libstdc++6 4.4.5-4   The GNU Standard C++ Library v3
ii  libx11-6   2:1.3.3-3 X11 client-side library

Versions of packages konqueror recommends:
ii  dolphin   4:4.4.5-1  file manager
pn  konqueror-nsplugins   none (no description available)

Versions of packages konqueror suggests:
ii  konq-plugins  4:4.4.0-2  plugins for Konqueror, the KDE fil

-- no debconf information

-MD

-- 
---
Michael DeeganHugaholichttp://www.deegan.id.au/
- Guvax bs vg nf ribyhgvba va npgvba. -



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org