For completeness and also because it's useful for libvirt-gconfig API's
consumers who are interested on reading the guest configuration, like
virt-viewer.
Signed-off-by: Fabiano FidĂȘncio <fidencio(a)redhat.com>
---
libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.c | 8 ++++++++
libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h | 1 +
libvirt-gconfig/libvirt-gconfig.sym | 1 +
3 files changed, 10 insertions(+)
diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.c
b/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.c
index 7a2cb4d..4f6096e 100644
--- a/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.c
+++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.c
@@ -73,6 +73,14 @@ gvir_config_domain_graphics_rdp_new_from_xml(const gchar *xml,
return GVIR_CONFIG_DOMAIN_GRAPHICS_RDP(object);
}
+gboolean gvir_config_domain_graphics_rdp_get_autoport(GVirConfigDomainGraphicsRdp
*graphics)
+{
+ g_return_val_if_fail(GVIR_CONFIG_IS_DOMAIN_GRAPHICS_RDP(graphics), FALSE);
+
+ return gvir_config_object_get_attribute_boolean(GVIR_CONFIG_OBJECT(graphics),
+ NULL, "autoport", FALSE);
+}
+
void gvir_config_domain_graphics_rdp_set_autoport(GVirConfigDomainGraphicsRdp *graphics,
gboolean autoport)
{
diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h
b/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h
index a048ff8..5cf93f0 100644
--- a/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h
+++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-rdp.h
@@ -62,6 +62,7 @@ GVirConfigDomainGraphicsRdp *gvir_config_domain_graphics_rdp_new(void);
GVirConfigDomainGraphicsRdp *gvir_config_domain_graphics_rdp_new_from_xml(const gchar
*xml,
GError
**error);
+gboolean gvir_config_domain_graphics_rdp_get_autoport(GVirConfigDomainGraphicsRdp*
graphics);
void gvir_config_domain_graphics_rdp_set_autoport(GVirConfigDomainGraphicsRdp *graphics,
gboolean autoport);
diff --git a/libvirt-gconfig/libvirt-gconfig.sym b/libvirt-gconfig/libvirt-gconfig.sym
index a9c45e6..100c174 100644
--- a/libvirt-gconfig/libvirt-gconfig.sym
+++ b/libvirt-gconfig/libvirt-gconfig.sym
@@ -734,6 +734,7 @@ global:
} LIBVIRT_GCONFIG_0.2.1;
LIBVIRT_GCONFIG_0.2.4 {
+ gvir_config_domain_graphics_rdp_get_autoport;
gvir_config_domain_graphics_spice_get_autoport;
gvir_config_domain_graphics_spice_set_gl;
gvir_config_domain_graphics_vnc_get_autoport;
--
2.5.0