Rob Bayer schrieb: > On Fri, Mar 13, 2009 at 10:42 AM, Christian Ehrlicher > <[email protected]> wrote: >> Rob Bayer schrieb: >>> Hi, >>> Does KFileDialog/KUrl seem broken to anyone else? In particular it >>> seems to add a / in front of C:/path/to/file so that opening the file >>> makes it open /C:/path/to/file and thus fails. At first I thought it >>> was just my code but then for kicks I tried compiling the tutorial at >>> http://techbase.kde.org/Development/Tutorials/Saving_and_loading and >>> get the same error. >>> >>> I looked through the KUrl source and it looks like the initial / is >>> getting added at line 1706 but the comment there says this is >>> intentional. Thoughts? >>> >> You're probably using the wrong function to retrieve the local file. >> You've to use KUrl::toLocalFile() and not KUrl::path() >> I fixed all places I found but there may be others. >> >> Christian >> _______________________________________________ >> Kde-windows mailing list >> [email protected] >> https://mail.kde.org/mailman/listinfo/kde-windows >> > > In my code I do, but the problem is that several KDE functions > apparently don't do this correctly. For example, take a look at the > tutorial I linked to above. In that case, the app itself only calls > KIO::NetAccess::download(fileNameFromDialog, tmpFile, this) and it's > that call that makes it fail. I've encountered similar things with > other API calls, so I was hoping that somebody had some fix that would > work for all of them instead of going through _all_ the kdelibs source > and looking for .path() calls that should be .toLocalFile() > I'm sorry but that's not possible because you've to take a look if you can really replace path() with toLocalFile(). I'll fix KIO::NetAccess::download()
Christian _______________________________________________ Kde-windows mailing list [email protected] https://mail.kde.org/mailman/listinfo/kde-windows
