[gnome-control-center] sharing: Don't show Media sharing without rygel
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] sharing: Don't show Media sharing without rygel
- Date: Tue, 15 Jan 2013 16:54:58 +0000 (UTC)
commit 354310cfb40e5d71a63789d672ddc0ef01a34e56
Author: Bastien Nocera <hadess hadess net>
Date: Tue Jan 15 17:54:00 2013 +0100
sharing: Don't show Media sharing without rygel
If rygel isn't available, don't show the media sharing section.
panels/sharing/cc-sharing-panel.c | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/panels/sharing/cc-sharing-panel.c b/panels/sharing/cc-sharing-panel.c
index 5c7bfe5..0b53683 100644
--- a/panels/sharing/cc-sharing-panel.c
+++ b/panels/sharing/cc-sharing-panel.c
@@ -403,6 +403,15 @@ cc_sharing_panel_setup_media_sharing_dialog (CcSharingPanel *self)
gchar **folders, **list;
gboolean enabled;
GtkListStore *store;
+ char *path;
+
+ path = g_find_program_in_path ("rygel");
+ if (path == NULL)
+ {
+ gtk_widget_hide (WID ("media-sharing-button"));
+ return;
+ }
+ g_free (path);
cc_sharing_panel_bind_switch_to_label (WID ("share-media-switch"),
WID ("media-sharing-status-label"));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]