From 7a4bd61930f826ceabf144bf1d4ca06592565e90 Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Tue, 3 Apr 2001 05:35:48 +0000 Subject: Plug leak. 2001-04-02 Federico Mena Quintero * gui/e-tasks.c (e_tasks_setup_menus): Plug leak. * gui/event-editor.c (obj_updated_cb): Do nothing for now until we think of something sensible to do. (obj_removed_cb): Likewise. * gui/dialogs/task-editor.c (obj_updated_cb): Likewise. (obj_removed_cb): Likewise. * gui/event-editor.c (dialog_to_comp_object): Plug leak. svn path=/trunk/; revision=9124 --- calendar/cal-client/cal-client.c | 36 +++++++++++++++++++++++++++++++----- 1 file changed, 31 insertions(+), 5 deletions(-) (limited to 'calendar/cal-client/cal-client.c') diff --git a/calendar/cal-client/cal-client.c b/calendar/cal-client/cal-client.c index e81ff9afa3..cd8c8713d6 100644 --- a/calendar/cal-client/cal-client.c +++ b/calendar/cal-client/cal-client.c @@ -1,8 +1,6 @@ -/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ /* Evolution calendar client * - * Copyright (C) 2000 Helix Code, Inc. - * Copyright (C) 2000 Ximian, Inc. + * Copyright (C) 2001 Ximian, Inc. * * Author: Federico Mena-Quintero * @@ -21,7 +19,10 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. */ +#ifdef HAVE_CONFIG_H #include +#endif + #include #include @@ -44,7 +45,7 @@ struct _CalClientPrivate { /* The calendar factory we are contacting */ GNOME_Evolution_Calendar_CalFactory factory; - /* Our calendar listener */ + /* Our calendar listener implementation */ CalListener *listener; /* The calendar client interface object we are contacting */ @@ -73,7 +74,6 @@ static GtkObjectClass *parent_class; /** * cal_client_get_type: - * @void: * * Registers the #CalClient class if necessary, and returns the type ID assigned * to it. @@ -1505,3 +1505,29 @@ cal_client_remove_object (CalClient *client, const char *uid) CORBA_exception_free (&ev); return retval; } + +/** + * cal_client_get_query: + * @client: A calendar client. + * @sexp: S-expression representing the query. + * + * Creates a live query object from a loaded calendar. + * + * Return value: A query object that will emit notification signals as calendar + * components are added and removed from the query in the server. + **/ +CalQuery * +cal_client_get_query (CalClient *client, const char *sexp) +{ + CalClientPrivate *priv; + + g_return_val_if_fail (client != NULL, NULL); + g_return_val_if_fail (IS_CAL_CLIENT (client), NULL); + + priv = client->priv; + g_return_val_if_fail (priv->load_state == CAL_CLIENT_LOAD_LOADED, FALSE); + + g_return_val_if_fail (sexp != NULL, NULL); + + return cal_query_new (priv->cal, sexp); +} -- cgit v1.2.3