From kfm-devel Mon Jul 15 08:01:28 2002 From: David Faure Date: Mon, 15 Jul 2002 08:01:28 +0000 To: kfm-devel Subject: Re: MMB opens in new tab X-MARC-Message: https://marc.info/?l=kfm-devel&m=102672018617754 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Sunday 14 July 2002 18:22, Doug Hanley wrote: > KMimeType::Ptr mimeType = KMimeType::findByURL( url ); Ouch. That's not good at all. This function doesn't give reliable results, in particular over HTTP. You work around that by assuming HTML, but there is more than HTML that one can get over HTTP. Think images, for instance. Hmm, ok, I see you use a KonqRun if the mimetype was unknown, but.... the danger of the code that was posted here is more precisely in case findByURL does a wrong assumption (as it does on some protocols). Why does addTab need to know the mimetype? Can't it create an empty tab, and let openView (directly via openURL, or via KonqRun), take care of creating the right part into it? - -- David FAURE, david@mandrakesoft.com, faure@kde.org http://people.mandrakesoft.com/~david/ Contributing to: http://www.konqueror.org/, http://www.koffice.org/ KOffice-1.2-beta2 is out! http://dot.kde.org/1025176121/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE9MoFY72KcVAmwbhARAq2WAJ9RhBfyY+q+yWR/f24bhiMQuj4DNwCdGCdw 5UNyLgqjwRYMJl4/ZWRN77I= =FhGc -----END PGP SIGNATURE-----