Files
evolution/shell/evolution-activity-client.h
Ettore Perazzoli 7657ec4a52 Don't assert that there is a handler, so we don't crash if user clicks on
* e-storage-set-view.c (popup_folder_menu): Don't assert that
there is a handler, so we don't crash if user clicks on a folder
whose type we cannot handle for some reason [such as an
uninstalled component].

* evolution-test-component.c (activity_client_cancel_callback):
New callback for the "cancel" signal on the
EvolutionActivityClient object.
(activity_client_show_details_callback): New callback for the
"show_details" signal.
(timeout_callback_1): Connect these two signal handlers.

* e-activity-handler.c (task_widget_button_press_event_callback):
Ahem, right-click is button 3, not button 2.
(show_cancellation_popup): Actually pop up the menu.
(get_corba_null_value): New helper function to create a CORBA_any
null value.
(report_task_event): New helper function to report events to the
listener.
(task_widget_cancel_callback): Use it.  Report "Cancel" instead of
"Cancelled".
(task_widget_show_details_callback): New, callback for the "Show
Details" right-click menu item.

* evolution-activity-client.c: Updated to dispatch the "Cancel"
and "ShowDetails" events as "cancel" and "show_details" signals.
(class_init): Install the signals.
(listener_callback): Updated to update the signals corresponding
to the "ShowDetails" and "Cancel" events.

* Evolution-Activity.idl: Changed the docs about the events sent
to the Bonobo::Listener.  We now only have "ShowDetails" and
"Cancelled".

* evolution-test-component.c (timeout_callback_1): Make the
activity cancellable so we can test the right-click cancel menu
too.

* main.c (idle_cb): Actually exit if we cannot reach to the shell.

svn path=/trunk/; revision=10684
2001-07-02 17:06:08 +00:00

93 lines
3.6 KiB
C
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
/* evolution-activity-client.h
*
* Copyright (C) 2001 Ximian, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*
* Author: Ettore Perazzoli <ettore@ximian.com>
*/
#ifndef _EVOLUTION_ACTIVITY_CLIENT_H_
#define _EVOLUTION_ACTIVITY_CLIENT_H_
#include "evolution-shell-client.h"
#include "Evolution.h"
#include <gtk/gtkobject.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#ifdef __cplusplus
extern "C" {
#pragma }
#endif /* __cplusplus */
#define EVOLUTION_TYPE_ACTIVITY_CLIENT (evolution_activity_client_get_type ())
#define EVOLUTION_ACTIVITY_CLIENT(obj) (GTK_CHECK_CAST ((obj), EVOLUTION_TYPE_ACTIVITY_CLIENT, EvolutionActivityClient))
#define EVOLUTION_ACTIVITY_CLIENT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), EVOLUTION_TYPE_ACTIVITY_CLIENT, EvolutionActivityClientClass))
#define EVOLUTION_IS_ACTIVITY_CLIENT(obj) (GTK_CHECK_TYPE ((obj), EVOLUTION_TYPE_ACTIVITY_CLIENT))
#define EVOLUTION_IS_ACTIVITY_CLIENT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((obj), EVOLUTION_TYPE_ACTIVITY_CLIENT))
typedef struct _EvolutionActivityClient EvolutionActivityClient;
typedef struct _EvolutionActivityClientPrivate EvolutionActivityClientPrivate;
typedef struct _EvolutionActivityClientClass EvolutionActivityClientClass;
struct _EvolutionActivityClient {
GtkObject parent;
EvolutionActivityClientPrivate *priv;
};
struct _EvolutionActivityClientClass {
GtkObjectClass parent_class;
/* Signals. */
void (* show_details) (EvolutionActivityClient *activity_client);
void (* cancel) (EvolutionActivityClient *activity_client);
};
GtkType evolution_activity_client_get_type (void);
gboolean evolution_activity_client_construct (EvolutionActivityClient *activity_client,
EvolutionShellClient *shell_client,
const char *component_id,
GdkPixbuf **animated_icon,
const char *information,
gboolean cancellable,
gboolean *suggest_display_return);
EvolutionActivityClient *evolution_activity_client_new (EvolutionShellClient *shell_client,
const char *component_id,
GdkPixbuf **animated_icon,
const char *information,
gboolean cancellable,
gboolean *suggest_display_return);
gboolean evolution_activity_client_update (EvolutionActivityClient *activity_client,
const char *information,
double progress);
GNOME_Evolution_Activity_DialogAction
evolution_activity_client_request_dialog (EvolutionActivityClient *activity_client,
GNOME_Evolution_Activity_DialogType dialog_type);
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif /* _EVOLUTION_ACTIVITY_CLIENT_H_ */