[epiphany/wip/history-rewrite: 1/9] Add a EphyHistoryService property to EphyHistoryWindow



commit 2bede0b8485e28cd89bf07bdca8ed0f3d4b13b1d
Author: Claudio Saavedra <csaavedra igalia com>
Date:   Wed Feb 29 09:45:15 2012 +0200

    Add a EphyHistoryService property to EphyHistoryWindow

 src/ephy-history-window.c |   17 ++++++++++++++++-
 src/ephy-history-window.h |    1 +
 2 files changed, 17 insertions(+), 1 deletions(-)
---
diff --git a/src/ephy-history-window.c b/src/ephy-history-window.c
index e5d6e6d..8cb73bd 100644
--- a/src/ephy-history-window.c
+++ b/src/ephy-history-window.c
@@ -97,6 +97,7 @@ static void search_entry_search_cb 	  (GtkWidget *entry,
 struct _EphyHistoryWindowPrivate
 {
 	EphyHistory *history;
+	EphyHistoryService *history_service;
 	GtkWidget *sites_view;
 	GtkWidget *pages_view;
 	EphyNodeFilter *pages_filter;
@@ -117,7 +118,8 @@ struct _EphyHistoryWindowPrivate
 enum
 {
 	PROP_0,
-	PROP_HISTORY
+	PROP_HISTORY,
+	PROP_HISTORY_SERVICE,
 };
 
 static const GtkActionEntry ephy_history_ui_entries [] = {
@@ -503,6 +505,13 @@ ephy_history_window_class_init (EphyHistoryWindowClass *klass)
 							      "Global History",
 							      EPHY_TYPE_HISTORY,
 							      G_PARAM_READWRITE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_CONSTRUCT_ONLY));
+	g_object_class_install_property (object_class,
+					 PROP_HISTORY_SERVICE,
+					 g_param_spec_object ("history-service",
+							      "History service",
+							      "History Service",
+							      EPHY_TYPE_HISTORY_SERVICE,
+							      G_PARAM_READWRITE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_CONSTRUCT_ONLY));
 
 	g_type_class_add_private (object_class, sizeof(EphyHistoryWindowPrivate));
 }
@@ -1361,6 +1370,9 @@ ephy_history_window_set_property (GObject *object,
 	case PROP_HISTORY:
 		editor->priv->history = g_value_get_object (value);
 		break;
+        case PROP_HISTORY_SERVICE:
+          editor->priv->history_service = g_value_get_object (value);
+          break;
 	default:
 		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
 		break;
@@ -1380,6 +1392,9 @@ ephy_history_window_get_property (GObject *object,
 	case PROP_HISTORY:
 		g_value_set_object (value, editor->priv->history);
 		break;
+        case PROP_HISTORY_SERVICE:
+          g_value_set_object (value, editor->priv->history_service);
+          break;
 	default:
 		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
 		break;
diff --git a/src/ephy-history-window.h b/src/ephy-history-window.h
index 88ada34..8bc9eec 100644
--- a/src/ephy-history-window.h
+++ b/src/ephy-history-window.h
@@ -28,6 +28,7 @@
 
 #include "ephy-node-view.h"
 #include "ephy-history.h"
+#include "ephy-history-service.h"
 
 G_BEGIN_DECLS
 



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