diff options
Diffstat (limited to 'src/librygel-core/rygel-meta-config.vala')
-rw-r--r-- | src/librygel-core/rygel-meta-config.vala | 41 |
1 files changed, 39 insertions, 2 deletions
diff --git a/src/librygel-core/rygel-meta-config.vala b/src/librygel-core/rygel-meta-config.vala index 02f3aa05..13bb0e69 100644 --- a/src/librygel-core/rygel-meta-config.vala +++ b/src/librygel-core/rygel-meta-config.vala @@ -2,12 +2,11 @@ * Copyright (C) 2008,2009 Nokia Corporation. * Copyright (C) 2008,2009 Zeeshan Ali (Khattak) <zeeshanak@gnome.org>. * Copyright (C) 2012 Intel Corporation. - * Copyright (C) 2012 Intel Corporation * * Author: Zeeshan Ali (Khattak) <zeeshanak@gnome.org> * <zeeshan.ali@nokia.com> - * Jens Georg <jensg@openismus.com> * Krzesimir Nowak <krnowak@openismus.com> + * Jens Georg <jensg@openismus.com> * * This file is part of Rygel. * @@ -226,6 +225,44 @@ public class Rygel.MetaConfig : GLib.Object, Configuration { return val; } + public string get_media_engine () throws GLib.Error { + string val = null; + bool unavailable = true; + + foreach (var config in MetaConfig.configs) { + try { + val = config.get_media_engine (); + unavailable = false; + break; + } catch (GLib.Error err) {} + } + + if (unavailable) { + throw new ConfigurationError.NO_VALUE_SET ("No value available"); + } + + return val; + } + + public string get_engine_path () throws GLib.Error { + string val = null; + bool unavailable = true; + + foreach (var config in MetaConfig.configs) { + try { + val = config.get_engine_path (); + unavailable = false; + break; + } catch (GLib.Error err) {} + } + + if (unavailable) { + throw new ConfigurationError.NO_VALUE_SET ("No value available"); + } + + return val; + } + public string get_video_upload_folder () throws GLib.Error { unowned string default = Environment.get_user_special_dir (UserDirectory.VIDEOS); |