Should CMD_MIMETYPE methods emit mimeType()?

Vlad vladc6 at yahoo.com
Sun Jul 27 09:36:52 BST 2008


Hi,

Am I correct to assume that the KIO slave methods called as a result of CMD_MIMETYPE (ie. sftpProtocol::mimetype(), Ftp::mimetype(), etc) should do an "emit mimeType()"? Right now, sftpProtocol::mimetype() and Ftp::mimetype() don't do that, so I suspect they are broken.

In fact, Ftp::mimetype() for sure doesn't work because it is #if 0'ed.

It seems that sftpProtocol::mimetype() and Ftp::mimetype() call data() instead of "emit mimeType()", and an 8-year-old comment in Ftp::mimetype() mentions KMimeMagic. Is calling data() and relying on KMimeMagic outdated?

Thanks,
Vlad

PS: The File KIO slave doesn't even have a FileProtocol::mimetype(), and nobody seems to miss it. Perhaps CMD_MIMETYPE isn't used at all, especially since mimeType() is emitted in many other places like CMD_GET and CMD_OPEN.


      




More information about the kde-core-devel mailing list