diff --git a/src/libsysprof/sysprof-document-dbus-message.c b/src/libsysprof/sysprof-document-dbus-message.c
index 133ebd07..abb644fd 100644
--- a/src/libsysprof/sysprof-document-dbus-message.c
+++ b/src/libsysprof/sysprof-document-dbus-message.c
@@ -51,6 +51,7 @@ enum {
PROP_SIGNATURE,
PROP_SENDER,
PROP_SERIAL,
+ PROP_STRING,
N_PROPS
};
@@ -130,6 +131,10 @@ sysprof_document_dbus_message_get_property (GObject *object,
g_value_set_string (value, sysprof_document_dbus_message_get_signature (self));
break;
+ case PROP_STRING:
+ g_value_take_string (value, sysprof_document_dbus_message_dup_string (self));
+ break;
+
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
}
@@ -214,6 +219,11 @@ sysprof_document_dbus_message_class_init (SysprofDocumentDBusMessageClass *klass
0,
(G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
+ properties[PROP_STRING] =
+ g_param_spec_string ("string", NULL, NULL,
+ NULL,
+ (G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
+
g_object_class_install_properties (object_class, N_PROPS, properties);
}
@@ -444,3 +454,16 @@ sysprof_document_dbus_message_get_bus_type (SysprofDocumentDBusMessage *self)
return 0;
}
+
+char *
+sysprof_document_dbus_message_dup_string (SysprofDocumentDBusMessage *self)
+{
+ g_autoptr(GDBusMessage) message = NULL;
+
+ g_return_val_if_fail (SYSPROF_IS_DOCUMENT_DBUS_MESSAGE (self), NULL);
+
+ if (!(message = sysprof_document_dbus_message_dup_message (self)))
+ return NULL;
+
+ return g_dbus_message_print (message, 0);
+}
diff --git a/src/libsysprof/sysprof-document-dbus-message.h b/src/libsysprof/sysprof-document-dbus-message.h
index 57a0e7e0..85b6ba47 100644
--- a/src/libsysprof/sysprof-document-dbus-message.h
+++ b/src/libsysprof/sysprof-document-dbus-message.h
@@ -65,6 +65,8 @@ SYSPROF_AVAILABLE_IN_ALL
GDBusMessageFlags sysprof_document_dbus_message_get_flags (SysprofDocumentDBusMessage *self);
SYSPROF_AVAILABLE_IN_ALL
GBusType sysprof_document_dbus_message_get_bus_type (SysprofDocumentDBusMessage *self);
+SYSPROF_AVAILABLE_IN_ALL
+char *sysprof_document_dbus_message_dup_string (SysprofDocumentDBusMessage *self);
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SysprofDocumentDBusMessage, g_object_unref)
diff --git a/src/sysprof/meson.build b/src/sysprof/meson.build
index 0c64bb76..c09a3b2e 100644
--- a/src/sysprof/meson.build
+++ b/src/sysprof/meson.build
@@ -15,6 +15,7 @@ sysprof_sources = [
'sysprof-cpu-section.c',
'sysprof-css.c',
'sysprof-dbus-section.c',
+ 'sysprof-dbus-utility.c',
'sysprof-duplex-layer.c',
'sysprof-energy-section.c',
'sysprof-files-section.c',
diff --git a/src/sysprof/sysprof-dbus-section.c b/src/sysprof/sysprof-dbus-section.c
index 2228306f..3863a7d8 100644
--- a/src/sysprof/sysprof-dbus-section.c
+++ b/src/sysprof/sysprof-dbus-section.c
@@ -22,6 +22,7 @@
#include "sysprof-chart.h"
#include "sysprof-dbus-section.h"
+#include "sysprof-dbus-utility.h"
#include "sysprof-line-layer.h"
#include "sysprof-time-filter-model.h"
#include "sysprof-time-scrubber.h"
@@ -184,6 +185,7 @@ sysprof_dbus_section_class_init (SysprofDBusSectionClass *klass)
gtk_widget_class_bind_template_callback (widget_class, format_message_type);
g_type_ensure (SYSPROF_TYPE_CHART);
+ g_type_ensure (SYSPROF_TYPE_DBUS_UTILITY);
g_type_ensure (SYSPROF_TYPE_DOCUMENT_MARK);
g_type_ensure (SYSPROF_TYPE_DOCUMENT_DBUS_MESSAGE);
}
diff --git a/src/sysprof/sysprof-dbus-section.ui b/src/sysprof/sysprof-dbus-section.ui
index e77f8a09..11f2a0fa 100644
--- a/src/sysprof/sysprof-dbus-section.ui
+++ b/src/sysprof/sysprof-dbus-section.ui
@@ -74,7 +74,7 @@
true
true
-