Reputation: 137
I'm trying to write a a GTK/C application that puts some files on the Gtk clipboard, so a user with Nautilus will be able to paste them. There is a good example of Gtk Clipboard local file copy and paste on stackoverflow. Unofrtunately the files I need to paste are not on the local disk, and cannot be accessed via a standard GVFS URI scheme like file:// Only my application can access these source file after setting up a TCP connection, authenticating and opening an extra channel.
How can I have these application managed remote files on the Gtk clipboard for pasting with Nautilus ? And in the future, for Dolphin/KDE too ?
After googling around I came to the following idea: I need to develop a new gvfs URI scheme handler (ie: my-app://). But it's hard to find examples or documentation. Is it the only way ? And, can my application register itself as a temporary GVFS URI scheme handler without changing any external system configuration file ? How ?
Upvotes: 3
Views: 312
Reputation: 21
This is an old question, but I had to solve a similar issue. By creating a custom fuse filesystem it was possible to utilize the normal clipboard behavior (kde and gnome way of announcing files to copy in the clipboard) and have network resources only utilized if the data is actually accessed.
Upvotes: 1