aboutsummaryrefslogtreecommitdiffstats
path: root/art
diff options
context:
space:
mode:
authorJakub Steiner <jimmac@src.gnome.org>2001-10-22 18:58:13 +0800
committerJakub Steiner <jimmac@src.gnome.org>2001-10-22 18:58:13 +0800
commit54aa210e0013cd3a265acf4167cf20a614cb05af (patch)
tree2256eab177dffefdb7bbe50d4624777457ea2416 /art
parent5e0bf557171d1b107513af36832a79976b458734 (diff)
downloadgsoc2013-evolution-54aa210e0013cd3a265acf4167cf20a614cb05af.tar.gz
gsoc2013-evolution-54aa210e0013cd3a265acf4167cf20a614cb05af.tar.zst
gsoc2013-evolution-54aa210e0013cd3a265acf4167cf20a614cb05af.zip
update the look a bit
svn path=/trunk/; revision=13866
Diffstat (limited to 'art')
-rw-r--r--art/ChangeLog4
-rw-r--r--art/about-box.pngbin17232 -> 16070 bytes
2 files changed, 4 insertions, 0 deletions
diff --git a/art/ChangeLog b/art/ChangeLog
index 7a98c6a2e8..f9048b7529 100644
--- a/art/ChangeLog
+++ b/art/ChangeLog
@@ -1,3 +1,7 @@
+2001-10-22 Jakub Steiner <jimmac@ximian.com>
+
+ * about-box.png: update the layout a bit
+
2001-10-16 Ettore Perazzoli <ettore@ximian.com>
* Makefile.am (images_DATA): Add `about-box.png'.
diff --git a/art/about-box.png b/art/about-box.png
index 0551cca87f..a1de3c7928 100644
--- a/art/about-box.png
+++ b/art/about-box.png
Binary files differ
a> 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260
/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
/* mail-importer.c
 *
 * Authors: Iain Holmes <iain@ximian.com>
 *
 * 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.
 */

#ifdef HAVE_CONFIG_H
#include <config.h>
#endif

#include <dirent.h>
#include <gmodule.h>
#include <libgnome/gnome-defs.h>
#include <libgnome/gnome-util.h>
#include <evolution-storage.h>
#include <camel/camel-folder.h>
#include <camel/camel-mime-message.h>
#include <camel/camel-stream-mem.h>
#include <camel/camel-exception.h>

#include "mail-importer.h"
#include "mail-local.h"
#include "mail.h"


static GList *importer_modules = NULL;

extern char *evolution_dir;

static GNOME_Evolution_LocalStorage local_storage = NULL;

/* Prototype */

void mail_importer_uninit (void);

/**
 * mail_importer_create_folder:
 * parent_path: The path of the parent folder.
 * name: The name of the folder to be created.
 * description: A description of the folder.
 * listener: A BonoboListener for notification.
 *
 * Attempts to create the folder @parent_path/@name. When the folder has been
 * created, or there is an error, the "evolution-shell:folder-created" event is
 * emitted on @listener. The BonoboArg that is sent to @listener is a 
 * GNOME_Evolution_Storage_FolderResult which has two elements: result and path.
 * Result contains the error code, or success, and path contains the complete
 * physical path to the newly created folder.
 */
void
mail_importer_create_folder (const char *parent_path,
                 const char *name,
                 const char *description,
                 const BonoboListener *listener)
{
    Bonobo_Listener corba_listener;
    CORBA_Environment ev;
    char *path, *physical;
    char *real_description;

    g_return_if_fail (local_storage != NULL);
    g_return_if_fail (listener != NULL);
    g_return_if_fail (BONOBO_IS_LISTENER (listener));

    path = g_concat_dir_and_file (parent_path, name);
    physical = g_strdup_printf ("file://%s/local/%s", evolution_dir,
                    parent_path);

    corba_listener = bonobo_object_corba_objref (BONOBO_OBJECT (listener));
    /* Darn CORBA wanting non-NULL values for strings */
    real_description = CORBA_string_dup (description ? description : "");
    
    CORBA_exception_init (&ev);
    GNOME_Evolution_Storage_asyncCreateFolder (local_storage, 
                           path, "mail", 
                           real_description, physical,
                           corba_listener, &ev);
    CORBA_exception_free (&ev);
    g_free (path);
    g_free (physical);
}

/**
 * mail_importer_add_line:
 * importer: A MailImporter structure.
 * str: Next line of the mbox.
 * finished: TRUE if @str is the last line of the message.
 *
 * Adds lines to the message until it is finished, and then adds
 * the complete message to the folder.
 */
void
mail_importer_add_line (MailImporter *importer,
            const char *str,
            gboolean finished)
{
    CamelMimeMessage *msg;
    CamelMessageInfo *info;
    CamelException *ex;
    
    if (importer->mstream == NULL) {
        importer->mstream = CAMEL_STREAM_MEM (camel_stream_mem_new ());
    }

    camel_stream_write (CAMEL_STREAM (importer->mstream), str, 
                strlen (str));
    
    if (finished == FALSE)
        return;

    camel_stream_reset (CAMEL_STREAM (importer->mstream));
    info = g_new0 (CamelMessageInfo, 1);
    info->flags = CAMEL_MESSAGE_SEEN;

    msg = camel_mime_message_new ();
    camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (msg),
                          CAMEL_STREAM (importer->mstream));
    
    camel_object_unref (CAMEL_OBJECT (importer->mstream));
    importer->mstream = NULL;

    ex = camel_exception_new ();
    camel_folder_append_message (importer->folder, msg, info, ex);
    camel_object_unref (CAMEL_OBJECT (msg));

    camel_exception_free (ex);
    g_free (info);
}

/* module management */
static GList *
get_importer_list (void)
{
    DIR *dir;
    struct dirent *d;