Hi,
On 04/23/2013 01:17 PM, David Faure wrote:
On Monday 22 April 2013 22:35:38 Hans de Goede wrote:
<snip>
The recently discussed (but not yet formalized) "Intents" spec will allow
to do exactly that:
1) pick the preferred file manager from .desktop files
(including the possibility for the user to change preference using a local
file, similar to mimeapps.list)
2) start it if not already running (knowing for sure which DBus name it
will register under)
This is inherently racy, and when we loose the race, depending on the
filemanager in question we may end up with 2 different windows.
DBus activation is not racy. You cannot end up with two processes.
And if the activated service starts without a window, you cannot end up with 2
windows either.
<sigh>, the steps 1 and 2 *you* mentioned above, are not about dbus activation,
if we do dbus-activation, we don't need to check if the file-manager is running
at all, but we can NOT do dbus activation, since that does not allow selecting
which file manager is the users preferred one.
So dbus-activation is not an option. Unless we give each file manager a
unique service name, which does not seem like a good idea to me...
Also most
filemanagers will throw up a default window, and then one more for the dbus
call, so if the filemanager is not running you end up with 2 windows.
nautilus has --no-default-window to fix this, others may have something too,
but this is not exactly simplifying the problem.
And konqueror has --silent. But you don't have to deal with any of that
yourself; when implementing the intents spec, the
nautilus/konqueror/dolphin/etc. developers will provide appropriate .service
files (including the right Exec line for not showing a window on startup).
And how do we deal with multiple apps (ie nautilus and konqueror) offering the
same dbus service name? AFAIK dbus currently does not deal with this.
Regards,
Hans
_______________________________________________
xdg mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/xdg