diff --git a/src/libsysprof-analyze/sysprof-document-frame.c b/src/libsysprof-analyze/sysprof-document-frame.c index 00a9b8f1..b47b258e 100644 --- a/src/libsysprof-analyze/sysprof-document-frame.c +++ b/src/libsysprof-analyze/sysprof-document-frame.c @@ -275,3 +275,10 @@ sysprof_document_frame_get_time_offset (SysprofDocumentFrame *self) return self->time_offset; } + +gboolean +sysprof_document_frame_equal (const SysprofDocumentFrame *a, + const SysprofDocumentFrame *b) +{ + return a->frame == b->frame; +} diff --git a/src/libsysprof-analyze/sysprof-document-frame.h b/src/libsysprof-analyze/sysprof-document-frame.h index c8556fa1..279219a1 100644 --- a/src/libsysprof-analyze/sysprof-document-frame.h +++ b/src/libsysprof-analyze/sysprof-document-frame.h @@ -35,15 +35,18 @@ typedef struct _SysprofDocumentFrame SysprofDocumentFrame; typedef struct _SysprofDocumentFrameClass SysprofDocumentFrameClass; SYSPROF_AVAILABLE_IN_ALL -GType sysprof_document_frame_get_type (void) G_GNUC_CONST; +GType sysprof_document_frame_get_type (void) G_GNUC_CONST; SYSPROF_AVAILABLE_IN_ALL -int sysprof_document_frame_get_cpu (SysprofDocumentFrame *self); +int sysprof_document_frame_get_cpu (SysprofDocumentFrame *self); SYSPROF_AVAILABLE_IN_ALL -int sysprof_document_frame_get_pid (SysprofDocumentFrame *self); +int sysprof_document_frame_get_pid (SysprofDocumentFrame *self); SYSPROF_AVAILABLE_IN_ALL -gint64 sysprof_document_frame_get_time (SysprofDocumentFrame *self); +gint64 sysprof_document_frame_get_time (SysprofDocumentFrame *self); SYSPROF_AVAILABLE_IN_ALL -gint64 sysprof_document_frame_get_time_offset (SysprofDocumentFrame *self); +gint64 sysprof_document_frame_get_time_offset (SysprofDocumentFrame *self); +SYSPROF_AVAILABLE_IN_ALL +gboolean sysprof_document_frame_equal (const SysprofDocumentFrame *a, + const SysprofDocumentFrame *b); G_DEFINE_AUTOPTR_CLEANUP_FUNC (SysprofDocumentFrame, g_object_unref)