[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Re: fairly bad KFM bug
From: Roberto Alsina <ralsina () unl ! edu ! ar>
Date: 1999-01-27 17:09:47
[Download RAW message or body]
On Wed, 27 Jan 1999, David Faure wrote:
> On Wed, Jan 27, 1999 at 11:18:28AM -0500, Preston Brown wrote:
> > KFM has a somewhat nasty bug. When you bookmark a page that does not set
> > the title, you end up creating a bookmark '.kdelnk'. This shows up as an
> > empty line in the bookmarks menu, etc. I think it might be wise to have
> > it create 'NoTitle.kdelnk' instead, followed by 'NoTitle1.kdelnk', etc.
> True.
> Would the following suit you ?
> (Sorry, no numbering, I don't see how to do it - or with a static int, we
> can do it for the current session, which is a little better than nothing.)
You could iterate over the number until QFile::exists() returns false?
>
> Index: bookmark.cpp
> ===================================================================
> RCS file: /home/kde/kdebase/kfm/bookmark.cpp,v
> retrieving revision 1.16
> diff -u -p -r1.16 bookmark.cpp
> --- bookmark.cpp 1998/11/14 00:14:03 1.16
> +++ bookmark.cpp 1999/01/27 17:03:35
> @@ -281,13 +281,16 @@ KBookmark::KBookmark( KBookmarkManager *
> m_id = g_id++;
> m_pManager = _bm;
> m_lstChildren.setAutoDelete( true );
> - m_text = _text;
> + if (_text[0]=='\0')
> + m_text = i18n("NoTitle");
> + else
> + m_text = _text;
> m_url = _url;
> m_type = URL;
>
> m_file = _parent->file();
> m_file += "/";
> - m_file += encode( _text );
> + m_file += encode( m_text );
> m_file += ".kdelnk";
>
> FILE *f = fopen( m_file, "w" );
>
>
> --
> ____________________________________________________________________
> | |
> | David FAURE |
> | E-mail : David.Faure@insa-lyon.fr, faure@kde.org |
> | http://www.insa-lyon.fr/People/AEDI/dfaure/index.html |
> |____________________________________________________________________|
>
>
("\''/").__..-''"`-. . Roberto Alsina
`9_ 9 ) `-. ( ).`-._.`) ralsina@unl.edu.ar
(_Y_.)' ._ ) `._`. " -.-' Centro de Telematica
_..`-'_..-_/ /-'_.' Universidad Nacional del Litoral
(l)-'' ((i).' ((!.' Santa Fe - Argentina
KDE Developer (MFCH)
Life isn't short. It's just that death is longer.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic