glib gio usage of the library outside of GNOME



Hello,

I'm curently working with the gio library. Especially with the GVolumeMonitor. My problem ist, that the GVolumeMonitor doesn't seem to work outside of GNOME (e.g. on a terminal only).

I created a test code:
g_type_init();
GVolumeMonitor *vmon = g_volume_monitor_get();
GList *drives = g_volume_monitor_get_connected_drives(vmon);
printf("DRIVES: %p\n", drives);

Inside of GNOME I receive a valid entry for drives, outside nil.

Is there any special thing, e.g. initialize gio, to get this working?

Thanks and Greetings
Michael Weimann


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]