[devhelp] DhLink: small improvements



commit dfe678b83fd2e64a0a885a87596e69cf88220a19
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Fri Apr 28 19:50:30 2017 +0200

    DhLink: small improvements
    
    - Remove dh_link_free() (dead code).
    - Better function order with compare after ref/unref.
    - Add G_BEGIN_DECLS/G_END_DECLS for C++ support (it's the only header in
    Devhelp where it was missing).

 docs/reference/devhelp-sections.txt |    3 +--
 src/dh-link.h                       |    9 ++++++---
 2 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/docs/reference/devhelp-sections.txt b/docs/reference/devhelp-sections.txt
index dfed557..6cddb9c 100644
--- a/docs/reference/devhelp-sections.txt
+++ b/docs/reference/devhelp-sections.txt
@@ -196,10 +196,9 @@ dh_language_get_type
 <TITLE>DhLink</TITLE>
 DhLink
 dh_link_new
-dh_link_free
-dh_link_compare
 dh_link_ref
 dh_link_unref
+dh_link_compare
 dh_link_get_name
 dh_link_get_book_name
 dh_link_get_page_name
diff --git a/src/dh-link.h b/src/dh-link.h
index 74fdcbe..5c1e7f4 100644
--- a/src/dh-link.h
+++ b/src/dh-link.h
@@ -22,6 +22,8 @@
 
 #include <glib-object.h>
 
+G_BEGIN_DECLS
+
 /**
  * DhLinkType:
  * @DH_LINK_TYPE_BOOK: a book
@@ -72,11 +74,10 @@ DhLink *     dh_link_new                (DhLinkType     type,
                                          DhLink        *book,
                                          DhLink        *page,
                                          const gchar   *filename);
-void         dh_link_free               (DhLink        *link);
-gint         dh_link_compare            (gconstpointer  a,
-                                         gconstpointer  b);
 DhLink *     dh_link_ref                (DhLink        *link);
 void         dh_link_unref              (DhLink        *link);
+gint         dh_link_compare            (gconstpointer  a,
+                                         gconstpointer  b);
 const gchar *dh_link_get_name           (DhLink        *link);
 const gchar *dh_link_get_book_name      (DhLink        *link);
 const gchar *dh_link_get_page_name      (DhLink        *link);
@@ -89,4 +90,6 @@ void         dh_link_set_flags          (DhLink        *link,
 DhLinkType   dh_link_get_link_type      (DhLink        *link);
 const gchar *dh_link_get_type_as_string (DhLink        *link);
 
+G_END_DECLS
+
 #endif /* DH_LINK_H */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]