Re: How to start a filemanager in Gtk2 "the proper way"
- From: christian bluepanel org
- To: "Emmanuele Bassi" <ebassi gmail com>
- Cc: "gtk-app-devel-list gnome org" <gtk-app-devel-list gnome org>
- Subject: Re: How to start a filemanager in Gtk2 "the proper way"
- Date: Sat, 8 Feb 2014 12:08:34 +0100
Hey,
on Linux you can use the `xdg-open` command[1] (it should be available
on any reasonably modern distribution as part of the cross-desktop
utilities[0]). you can use xdg-open to open any file or URI you pass
to it with the correct application for the file's MIME type; if that
path is a directory, then the default action is to open a file manager
window.
the program I'm working on is using XDG system variables so I guess
calling xdg-open shouldn't be a problem.
if you have access to a recent enough version of GLib, you should use
GSubprocess; alternatively, use the g_spawn_* family of functions.
It depends on the distribution. I'm currently working on a Fedora 20
machine to have the latest packages, although my default system is a
Debian Wheezy system. So, I probably go with g_spawn.
Thanks a lot.
Regards,
Christian
@Emmanuele: sorry for answering you directly... I haven't configured my
mail program yet, so I use the webmailer.. grml
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]