[devhelp] AssistantView: more logical function order



commit 0bc31cb858e86543bbd52ed9cd366bd0b0787d8d
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Mon May 1 11:53:06 2017 +0200

    AssistantView: more logical function order

 docs/reference/devhelp-sections.txt |    2 +-
 src/dh-assistant-view.c             |   42 +++++++++++++++++-----------------
 src/dh-assistant-view.h             |   21 ++++++++++------
 3 files changed, 35 insertions(+), 30 deletions(-)
---
diff --git a/docs/reference/devhelp-sections.txt b/docs/reference/devhelp-sections.txt
index 76e9ae0..5bdd307 100644
--- a/docs/reference/devhelp-sections.txt
+++ b/docs/reference/devhelp-sections.txt
@@ -50,9 +50,9 @@ dh_assistant_get_type
 <TITLE>DhAssistantView</TITLE>
 DhAssistantView
 dh_assistant_view_new
-dh_assistant_view_search
 dh_assistant_view_set_book_manager
 dh_assistant_view_set_link
+dh_assistant_view_search
 <SUBSECTION Standard>
 DhAssistantViewClass
 DH_ASSISTANT_VIEW
diff --git a/src/dh-assistant-view.c b/src/dh-assistant-view.c
index a33b59f..b6ee1e7 100644
--- a/src/dh-assistant-view.c
+++ b/src/dh-assistant-view.c
@@ -163,6 +163,27 @@ dh_assistant_view_new (void)
         return g_object_new (DH_TYPE_ASSISTANT_VIEW, NULL);
 }
 
+/**
+ * dh_assistant_view_set_book_manager:
+ * @view: a #DhAssistantView.
+ * @book_manager: the #DhBookManager.
+ *
+ * Set the #DhBookManager to search in.
+ */
+void
+dh_assistant_view_set_book_manager (DhAssistantView *view,
+                                    DhBookManager   *book_manager)
+{
+        DhAssistantViewPrivate *priv;
+
+        g_return_if_fail (DH_IS_ASSISTANT_VIEW (view));
+        g_return_if_fail (DH_IS_BOOK_MANAGER (book_manager));
+
+        priv = dh_assistant_view_get_instance_private (view);
+
+        priv->book_manager = g_object_ref (book_manager);
+}
+
 static const gchar *
 find_in_buffer (const gchar *buffer,
                 const gchar *key,
@@ -504,24 +525,3 @@ dh_assistant_view_search (DhAssistantView *view,
 
         return TRUE;
 }
-
-/**
- * dh_assistant_view_set_book_manager:
- * @view: a #DhAssistantView.
- * @book_manager: the #DhBookManager.
- *
- * Set the #DhBookManager to search in.
- */
-void
-dh_assistant_view_set_book_manager (DhAssistantView *view,
-                                    DhBookManager   *book_manager)
-{
-        DhAssistantViewPrivate *priv;
-
-        g_return_if_fail (DH_IS_ASSISTANT_VIEW (view));
-        g_return_if_fail (DH_IS_BOOK_MANAGER (book_manager));
-
-        priv = dh_assistant_view_get_instance_private (view);
-
-        priv->book_manager = g_object_ref (book_manager);
-}
diff --git a/src/dh-assistant-view.h b/src/dh-assistant-view.h
index 46ef22a..565c981 100644
--- a/src/dh-assistant-view.h
+++ b/src/dh-assistant-view.h
@@ -45,14 +45,19 @@ struct _DhAssistantViewClass {
         WebKitWebViewClass parent_class;
 };
 
-GType      dh_assistant_view_get_type (void) G_GNUC_CONST;
-GtkWidget* dh_assistant_view_new      (void);
-gboolean   dh_assistant_view_search   (DhAssistantView *view,
-                                       const gchar     *str);
-void       dh_assistant_view_set_book_manager  (DhAssistantView *view,
-                                                DhBookManager   *book_manager);
-gboolean   dh_assistant_view_set_link (DhAssistantView *view,
-                                       DhLink          *link);
+GType           dh_assistant_view_get_type              (void) G_GNUC_CONST;
+
+GtkWidget *     dh_assistant_view_new                   (void);
+
+void            dh_assistant_view_set_book_manager      (DhAssistantView *view,
+                                                         DhBookManager   *book_manager);
+
+gboolean        dh_assistant_view_set_link              (DhAssistantView *view,
+                                                         DhLink          *link);
+
+gboolean        dh_assistant_view_search                (DhAssistantView *view,
+                                                         const gchar     *str);
+
 G_END_DECLS
 
 #endif /* DH_ASSISTANT_VIEW_H */


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