in-place-editing patch for konqueror bookmarks

David Faure dfaure at klaralvdalens-datakonsult.se
Thu Jan 16 17:07:23 GMT 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thursday 16 January 2003 16:54, Oelewapperke wrote:
> On Wednesday 15 January 2003 16:23, David Faure wrote:
> > On Wednesday 15 January 2003 15:08, Oelewapperke wrote:
> > > indeed. I will post an additional patch to do that later. (btw I never
> > > ever use the menu except to get to "edit bookmarks").
> >
> > But what matters is that it's implemented in a consistent and generic way.
> > Both KBookmarkBar and the bookmark menu use KBookmarkMenu - it's the
> > class for _any_ bookmark popupmenu (main menu or submenu). So I would
> > expect that most of the code goes in there.
> 
> I have made a subclass of QPopupmenu to do this. I could easily make it
> inherit from KBookmarkMenu, but it would only introduce overhead as I'm
> not using any functionality of that class.

Ok, we were both wrong here.
Yes you don't need to touch KBookmarkMenu itself, but rather the KPopupMenu*
that's been given to it.
At the moment it gets it from KActionMenu::popupMenu().
It appears that there is no way to create a subclass of KPopupMenu in that method,
therefore KActionMenu would need to be changed (to create it on demand,
and to have a setPopupMenu() so that you can pass your own popupmenu instance).

Please reconsider this. You rewrote a complete bookmarkbar implementation
just to change the menus! There is much duplicated code in your patch, which
I'm strongly against. This will become a maintainance hell.

All you need is to pass KBookmarkMenu your own popupmenu class,
and this will work both for the bookmarkbar and for the toplevel bookmarks menu.
I can do the KActionMenu part of the work if you agree to rework the rest
around it.
Thanks.

- -- 
David Faure -- faure at kde.org, dfaure at klaralvdalens-datakonsult.se
Klarälvdalens Datakonsult AB, Platform-independent software solutions
Contributing to: http://www.konqueror.org/, http://www.koffice.org/
KOffice-1.2.1 is available - http://download.kde.org/stable/koffice-1.2.1/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE+JubL72KcVAmwbhARAlndAJ4z96r6lcQUmEFSkNjOkQej9rsEuQCdGzJQ
zssKxZpt6+jX34PpYdQ8XbE=
=Kl8B
-----END PGP SIGNATURE-----





More information about the kde-core-devel mailing list