aboutsummaryrefslogblamecommitdiffstats
path: root/shell/Evolution-ShellComponent.idl
blob: 592245481e9e1b333298963a9a13c9f314d9a603 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12











                                                                             
              
                  








                                                    

                                         
                                                    

                                                                  
                                                           
                                          
 
                                                                           

                                              
                                      
 
                                  

                                          
                                                                 
                                      


                                             

                                                                   



                                                                          


                                                                        
                                      


                                                                           
                                      
 


                                                                           













                                              
                                                     

          
  
/* -*- Mode: IDL; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
 * Interface for the Evolution components.
 *
 * Authors:
 *   Ettore Perazzoli <ettore@helixcode.com>
 *
 * Copyright (C) 2000 Helix Code, Inc.
 */

#include <Bonobo.h>

module GNOME {
module Evolution {
    interface Shell;

    struct FolderType {
        string name;
        string icon_name;
    };

    typedef sequence<FolderType> FolderTypeList;

    interface ShellComponentListener;

    interface ShellComponent : Bonobo::Unknown {
        readonly attribute FolderTypeList supported_types;

        /* FIXME: Can we use an attribute here?  */
        exception AlreadyOwned {};

        void setOwner (in Shell shell, in string evolution_homedir)
            raises (AlreadyOwned);

        exception NotOwned {};

        void unsetOwner ()
            raises (NotOwned);

        /* FIXME: We might want more exceptions here.  */
        exception NotFound {};
        exception UnsupportedType {};
        exception InternalError {};

        Bonobo::Control createView (in string physical_uri,
                        in string type)
            raises (NotFound, UnsupportedType, InternalError);

        exception Busy {};

        void addFolderAsync (in ShellComponentListener listener,
                     in string physical_uri,
                     in string type)
            raises (Busy);

        void removeFolderAsync (in ShellComponentListener listener,
                    in string physical_uri)
            raises (Busy);

        void populateFolderContextMenu (in Bonobo::UIContainer uih,
                        in string physical_uri,
                        in string type);
    };

    interface ShellComponentListener {
        enum Result {
            OK,
            UNSUPPORTED_OPERATION,
            UNSUPPORTED_TYPE,
            EXISTS,
            INVALID_URI,
            PERMISSION_DENIED,
            HAS_SUBFOLDERS,
            NO_SPACE
        };

        void notifyResult (in Result result);
    };
};
};