Skip to content

KUrlMimeData::urlsFromMimeData: only use the portal in sandbox

Jin Liu requested to merge genericity/kcoreaddons:skip-xdg-portal-on-host into master

Use KSandbox::isInside to detect if we are inside a Flatpak/Snap sandbox, and only use the FileTransfer portal then. The FileTransfer portal just returns the original paths from the sender when receiving in host, so we don't lose any functionality. But we avoid all symlink -related problems introduced by the portal resolving symlinks.

Sandbox types other than Flatpak/Snap are not supported. But the portal only support the two and treats others as host too. So no functionality lost.

Merge request reports