[patch] kfilewidget, kurlcompletion, kurl: improve experience of using the file widget

Jarosław Staniek js at iidea.pl
Thu Apr 3 01:19:27 BST 2008


A set of fixes for improving experience file dialog, mostly on Windows
+ some fixes for handling urls


KFileWidget:
- check whether a string contains protocol part more carefully because c:/ is
an absolute path, not a protocol
    (static containsProtocolSection()), so we assume the protocol has at least
two characters before ":/"
- enclose locationEdit->currentText() with QDir::fromNativeSeparators() and
add .trimmed() to cover more cases in conditions
- slotOk(): add code for handling accepting using OK button when directory
path is entered and directories are not acceptable result of the file widget:
cd to that directory then; in particuar it is now possible to enter C:\ or /
and press OK to change to the root dir on windows (or linux, respectively)

KUrlCompletion:
- construct the path more carefully because cwd can already end with '/', e.g.
it can be "c:/"

KUrl:
- KUrl::equals() and ::urlcmp(): make comparison of local urls
case-insensitive on Windows
- KUrl::hasSubUrl() some more optimizations

(for review)

-- 
regards / pozdrawiam, Jaroslaw Staniek
   Sponsored by OpenOffice Polska (http://www.openoffice.com.pl/en) to work on
   Kexi & KOffice (http://www.kexi.pl/en, http://www.koffice.org/kexi)
   KDE Libraries for MS Windows (http://windows.kde.org)

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: urls.patch
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080403/f715da19/attachment.ksh>


More information about the kde-core-devel mailing list