From kfm-devel Tue Oct 05 09:45:48 2004 From: David Faure Date: Tue, 05 Oct 2004 09:45:48 +0000 To: kfm-devel Subject: Re: Intergrating mht file to konqueror Message-Id: <200410051145.51508.faure () kde ! org> X-MARC-Message: https://marc.info/?l=kfm-devel&m=109696946721557 On Tuesday 05 October 2004 11:38, Thiago Macieira wrote: > Spiros Georgaras wrote: > >My mhtProtocol::listDir function adds a UDSEntry for each of the files > >contained in the mht file. Is this the right thing to do? > > I believe so. That's how all listDirs report their files. > > >What exactly is the function of mhtProtocol::stat? I mean what arguments > > could it take and what should it return? > > Cf. man stat This is about SlaveBase::stat, not about the system stat :) See any other kioslave, or the ioslave howto on developer.kde.org > It's checking the status of the file or directory to see if it exists. That part is true, but the return value of an ioslave's stat is a UDSEntry. > >3. I also want to ask if writing a kioslave is self contained. I mean does > >konqueror need to have a corresponding part of code in order to know that > > it should display ' mht:/d/292 Euro.mht/' as a directory listing, etc? > > No, Konqueror doesn't need any more code than it currently has. That's unfortunately not true either, if you want konqueror to open an archive-like file using an ioslave like it does for tar files. This currently needs a hack in konq_mainwindow.cc but I plan on fixing that soon, now that Joseph has added some mimetype properties which will allow to do this in a generic way (not sure why Joseph didn't proceed and change konq_mainwindow as well at the same time, after we discussed the solution :) -- David Faure, faure@kde.org, sponsored by Trolltech to work on KDE, Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).