this post was submitted on 15 Jun 2023
8 points (90.0% liked)

Linux

47231 readers
756 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

I have installed a few chat applications through flatpak (teams with Edge and "Whatsapp for Linux"). In both cases I can't paste images or drag files. I can paste text and I can upload files through the GUI. I imagine this is likely due to a permission that can be set through Flatseal. Anybody can help?

top 3 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 1 year ago* (last edited 1 year ago)

I'm definitely not an expert and there may be a better solution to this! Just sharing what my experience has been.

You can share any image through the GUI because that will open an xdg-desktop-portal that lets you select the file - Teams/Whatsapp doesn't know what's on your file system, only the portal does. The portal brings in your selected image and only your selected image into Edge/Whatsapp, therefore maintaining the sandbox.

Dragging and dropping doesn't go through a portal, so if the sandboxed application doesn't have access to wherever that image is, it can't accept it because it doesn't know about it! It has to have access to this file. As you mentioned this is something that can be solved in Flatseal: for instance, I added the Screenshots folder to my Firefox permissions so I can drag and drop photos from the Screenshots folder. Adding this allows me to drag and drop images from Screenshots (and any other folders in this "Other files" section), but dragging and dropping from anywhere else doesn't work since Firefox doesn't know about it.

You could enable all user files if you want to be able to drag images from anywhere, but that breaks the sandbox since the app would then have access to all files in your home.

[–] [email protected] 1 points 1 year ago

I can past images via ctl+v in webcord's default settings, but I can't right-click paste.

[–] [email protected] 1 points 1 year ago

My guess: It's likely that the applications' flatpak permissions don't allow to access the folder where those files live. The applications' file picker GUIs work anyway because they use flatpak portals, which automatically grant access to whatever file you pick.

If you want drag and paste to work, consider using flatseal or flatpak override to grant access to the folder where you keep your attachable files.