Skip to content
Commit 421e7ea4 authored by Frank Reininghaus's avatar Frank Reininghaus
Browse files

Make it possible to open archives via the command line

This used to work before afcf8961 (only
if "Open archives as folder" was enabled in the settings though). The
reason why this commit broke it is that the mime type of a file is not
determined automatically any more before asking
KProtocolManager::protocolForArchiveMimetype for the correct protocol,
so the determination of the protocol may fail.

Keeping the isMimeTypeKnown() check in DolphinView::openItemAsFolderUrl
still makes sense, because it prevents GUI blocking if the user tries
to open many files at the same time.

Therefore, we now call determineMimeType() in
DolphinViewContainer::slotUrlIsFileError(const KUrl&) and then try to
determine the correct protocol and use it to open the archive in the
view, rather than hoping that slotItemActivated(item) will do the right
thing.

BUG: 333078
REVIEW: 119877
FIXED-IN: 4.14.1
parent 13efd595
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment