aboutsummaryrefslogtreecommitdiffstats
path: root/shell/Evolution-Component.idl
blob: 7a915c6bfbe075a24972151a6084d23ad685dd12 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
/* -*- Mode: IDL; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
 * Interface for the Evolution components.
 *
 * Authors:
 *   Ettore Perazzoli <ettore@ximian.com>
 *
 * Copyright (C) 2003 Ximian, Inc.
 */

#include <Bonobo.idl>

module GNOME {
module Evolution {

    /* A type of item that the component can create when asked by the user,
       e.g. a mail message or an appointment.  */
    struct CreatableItemType {
        string id;
        string description;
        string menuDescription;
        string tooltip;
        char menuShortcut;
        string iconName;
    };
    typedef sequence <CreatableItemType> CreatableItemTypeList;

    interface Component : Bonobo::Unknown {
        exception Failed {};
        exception UnknownType {};

        /* Create the controls for embedding in the shell.  */
        void createControls (out Bonobo::Control sidebar_control,
                     out Bonobo::Control view_control)
            raises (Failed);

        /* Request the component to quit.  The component will reply
           with an event named "quit", with a boolean value of TRUE if
           the component agrees to quit and FALSE if it doesn't want
           to.  */
        void requestQuit (in Bonobo::Listener listener);

        /* Notify the component of whether the shell is currently
           running in interactive mode or not.  (I.e. basically,
           whether there are any Evolution windows on the screen.)
           @new_view_xid is an X Window ID ("None" if @now_interactive
           is FALSE) */
        void interactive (in boolean now_interactive,
                  in unsigned long new_view_xid);


        /*** The following stuff is needed to build the "New" toolbar
                     item as well as the "File -> New" submenu.  ***/

        /* List of creatable items. */
        readonly attribute CreatableItemTypeList userCreatableItems;

        /* Pop up a new editing dialog for the item with the specified
           @item_type_name.  */
        void requestCreateItem (in string item_type_name)
            raises (UnknownType);
    };

};
};