aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--importers/ChangeLog6
-rw-r--r--importers/elm-importer.c56
2 files changed, 62 insertions, 0 deletions
diff --git a/importers/ChangeLog b/importers/ChangeLog
index 4b660e2152..f138273071 100644
--- a/importers/ChangeLog
+++ b/importers/ChangeLog
@@ -1,3 +1,9 @@
+2001-08-31 Iain Holmes <iain@ximian.com>
+
+ * elm-importer.c (create_importer_gui): Add a messagebox.
+ (importer_cb): Update GUI
+ (elm_import_file): Update GUI.
+
2001-08-30 Iain Holmes <iain@ximian.com>
* pine-importer.c (create_importer_gui): Add a messagebox.
diff --git a/importers/elm-importer.c b/importers/elm-importer.c
index ff36aa087d..27d3508ec0 100644
--- a/importers/elm-importer.c
+++ b/importers/elm-importer.c
@@ -72,6 +72,10 @@ typedef struct {
gboolean do_mail;
Bonobo_ConfigDatabase db;
+
+ GtkWidget *dialog;
+ GtkWidget *label;
+ GtkWidget *progressbar;
} ElmImporter;
typedef struct {
@@ -84,6 +88,23 @@ static GHashTable *elm_prefs = NULL;
static void import_next (ElmImporter *importer);
+static GtkWidget *
+create_importer_gui (ElmImporter *importer)
+{
+ GtkWidget *dialog;
+
+ dialog = gnome_message_box_new (_("Evolution is importing your old Elm mail"), GNOME_MESSAGE_BOX_INFO, NULL);
+ gtk_window_set_title (GTK_WINDOW (dialog), _("Importing..."));
+
+ importer->label = gtk_label_new (_("Please wait"));
+ importer->progressbar = gtk_progress_bar_new ();
+ gtk_progress_set_activity_mode (GTK_PROGRESS (importer->progressbar), TRUE);
+ gtk_box_pack_start (GTK_BOX (GNOME_DIALOG (dialog)->vbox), importer->label, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (GNOME_DIALOG (dialog)->vbox), importer->progressbar, FALSE, FALSE, 0);
+
+ return dialog;
+}
+
static void
elm_store_settings (ElmImporter *importer)
{
@@ -109,6 +130,16 @@ importer_cb (EvolutionImporterListener *listener,
CORBA_Environment ev;
if (more_items) {
+ GtkAdjustment *adj;
+ float newval;
+
+ adj = GTK_PROGRESS (importer->progressbar)->adjustment;
+ newval = adj->value + 1;
+ if (newval > adj->upper) {
+ newval = adj->lower;
+ }
+
+ gtk_progress_set_value (GTK_PROGRESS (importer->progressbar), newval);
CORBA_exception_init (&ev);
objref = bonobo_object_corba_objref (BONOBO_OBJECT (importer->listener));
GNOME_Evolution_Importer_processItem (importer->importer,
@@ -133,8 +164,17 @@ elm_import_file (ElmImporter *importer,
CORBA_boolean result;
CORBA_Environment ev;
CORBA_Object objref;
+ char *str;
CORBA_exception_init (&ev);
+
+ str = g_strdup_printf (_("Importing %s as %s"), path, folderpath);
+ gtk_label_set_text (GTK_LABEL (importer->label), str);
+ g_free (str);
+ while (gtk_events_pending ()) {
+ gtk_main_iteration ();
+ }
+
result = GNOME_Evolution_Importer_loadFile (importer->importer, path,
folderpath, &ev);
if (ev._major != CORBA_NO_EXCEPTION || result == FALSE) {
@@ -325,6 +365,7 @@ scan_dir (ElmImporter *importer,
DIR *maildir;
struct stat buf;
struct dirent *current;
+ char *str;
maildir = opendir (dirname);
if (maildir == NULL) {
@@ -333,6 +374,14 @@ scan_dir (ElmImporter *importer,
return;
}
+ str = g_strdup_printf (_("Scanning %s"), dirname);
+ gtk_label_set_text (GTK_LABEL (importer->label), str);
+ g_free (str);
+
+ while (gtk_events_pending ()) {
+ gtk_main_iteration ();
+ }
+
current = readdir (maildir);
while (current) {
ElmFolder *pf;
@@ -395,6 +444,13 @@ elm_create_structure (EvolutionIntelligentImporter *ii,
elm_store_settings (importer);
+ /* Create a dialog */
+ importer->dialog = create_importer_gui (importer);
+ gtk_widget_show_all (importer->dialog);
+ while (gtk_events_pending ()) {
+ gtk_main_iteration ();
+ }
+
if (importer->do_mail == TRUE) {
char *elmdir;
h=gstreamer0.10-removal&id=30aaeb68b21ce3a618480b76b77aa8cf2fefc7db'>- Update to 1.10;sobomax2003-05-204-9/+8 * Update to KDE 3.1.2lioux2003-05-204-10/+8 * Bring back from Attic: localized messages and documentation for kofficelioux2003-05-2013-0/+415 * Remove bogus hypen dict.mbr2003-05-141-1/+0 * Add russian ooodict port.mbr2003-05-142-0/+21 * Re-add russian language patch.mbr2003-05-142-2/+2 * Remove Y2K conformance statement URLs.fenner2003-05-091-1/+0 * Update to 3.2arved2003-05-052-3/+3 * Add ksocrat, a KDE russian-english dictionary.arved2003-05-015-0/+55 * Fix breakage caused by old translating patches.mbr2003-04-252-2/+2 * [PATCH] russian/wmcyrx: fix MASTER_SITESedwin2003-04-071-3/+2 * Update to 1.3.27PL30.17+2.8.14.nork2003-04-062-2/+2 * Rejoice, for the long awaited upgrade to kde 3.1.1 is here!alane2003-04-064-26/+68 * Remove manpage directories on deinstallkris2003-04-051-0/+2 * Update Russian Apache + mod_ssl to patchlevel 30.17edwin2003-03-312-3/+3 * Update Russian Apache to patchlevel 30.17edwin2003-03-312-4/+3 * Clear moonlight beckons.ade2003-03-0722-11/+11 * Update MASTER_SITE for port russian/apache13 to lateset mirror listedwin2003-02-241-15/+1 * Update MASTER_SITE for port russian/apache13-modssl to lateset mirror listedwin2003-02-241-29/+10 * Update russian/rus-ispell to more recent version: 0.99f4edwin2003-02-242-11/+11 * Remove RESTRICTED tag for crypto stuff.nork2003-02-231-2/+0 * De-pkg-comment.knu2003-02-2120-10/+10 * De-pkg-comment.knu2003-02-212-1/+1 * De-pkg-comment.knu2003-02-218-4/+4 * update to fortuneru-0.4leeym2003-02-192-12/+7 * Update to 1.15.3.naddy2003-02-173-4/+4 * Upgrade to 0.3.naddy2003-02-155-16/+27 * Remove redundant category 'editors' in slave ports.mbr2003-02-132-2/+2 * Add correct encodings for the russian port.mbr2003-02-132-0/+8 * Upgrade kde-i18n to 3.1. Note that the following modules did not get awill2003-01-294-84/+692 * Add russian language distribution patch.mbr2003-01-222-0/+6 * Mark sites/distfiles with tags to minimize false hitsache2003-01-171-5/+5 * Master site changedache2003-01-172-2/+2 * Upgrade to 1.5ache2003-01-033-4/+6 * Upgrade to 0.99f3ache2003-01-023-6/+4 * Update to version 1.8.3.edwin2002-12-132-2/+9 * Fix maintainers email addressedwin2002-12-131-1/+1 * Typo in pkg-descredwin2002-12-111-1/+1 * spelling-typoedwin2002-12-111-1/+1 * Remove all netscape ports with a vulnerability of JRE.sada2002-11-176-45/+0 * - upgrade mod-ssl to 2.8.12 so that distfile could be fetchable again.sada2002-11-114-10/+107 * Add login classes support for suexecsada2002-11-113-9/+105 * o Rollback PORTCOMMENT modifications while this feature's implementationlioux2002-11-1112-12/+6 * Use PORTCOMMENT in the Makefile, and whack the pkg-comment.adamw2002-11-0712-6/+12 * PERL -> REINPLACEedwin2002-11-041-0/+1 * Fix categories to match dir containing port. bsd.port.mk (and portlint)alane2002-10-302-2/+4 * Vendor made minor code changes with no version bump. Label this askris2002-10-133-81/+82 * 1. Removed comments from pkg-plist files per will's request.alane2002-10-112-2/+2 * Update to apache 1.3.27 and 2.0.43. This fixes a security vulnerability.kris2002-10-056-14/+20 * add ru-mtc 1.3ijliao2002-09-186-0/+58 * texas chainsaw kde2 massacrealane2002-09-111-2/+0 * build aspell with dictionarydinoex2002-09-104-0/+22 * KDE2 is dead. The source is no longer available.alane2002-09-0920-660/+0 * Fix build in -current (build/link C++ code with ${CXX})kris2002-09-092-1/+27 * Fix build on -current (build/link C++ code with ${CXX})kris2002-09-092-6/+37 * Update to 3.0.3. Not much changed here: [1] i18n PKGNAMEs converted towill2002-08-256-8/+26 * Use MASTERDIRmbr2002-08-032-4/+4 * 1. Changed the lib depends on gettext to a build depends. This will meanalane2002-08-033-6/+6 * Bump PORTREVISION. KDE is fragile enough in its dependencies; we don'talane2002-08-023-1/+3 * Chase shlib rev of devel/gettextade2002-08-026-6/+6 * Bump shared library version because of devel/mm updatepat2002-07-281-1/+1 * Fix MASTER_SITE_SUBDIR.will2002-07-102-2/+2 * upgrade toijliao2002-07-083-37/+145 * upgrade to 1.3.26PL30.15ijliao2002-07-085-13/+181 * Update to 3.0.2 -- full log available in ports/x11/kde3/Makefile,v 1.51.will2002-07-056-32/+10 * Update:demon2002-07-0210-597/+609 * Update to Russian patch version 30.14.demon2002-06-302-2/+2 * Remove a master-site, that no longer exists.mi2002-06-251-1/+0 * Pass maintainership to Lev Serebryakov <lev@serebryakov.spb.ru>demon2002-06-241-1/+1 * - Make fetchable;sobomax2002-06-232-19/+20 * - Update to 1.3.26.30.13pat2002-06-234-38/+70 * Distfiles have been moved on kde site to Attic.alane2002-06-211-1/+1 * Mark FORBIDDEN until an update is available.nectar2002-06-182-0/+6 * Upgrade to KDE 3.0.1. The delay in this upgrade is mainly due to thewill2002-06-166-42/+80 * Add Russian OpenOffice slave portmbr2002-06-153-0/+31 * Minor clean.skv2002-06-072-4/+5 * Add p5-cyrillic 2.09, library for fast and easy cyrillic texttobez2002-06-066-0/+35 * - update to 0.2petef2002-06-026-27/+71 * Allow to add custom args to configure.demon2002-05-301-0/+4 * Unbreak on bento.sobomax2002-05-231-0/+29 * - Update MASTER_SITES (1)pat2002-05-231-3/+5 * Update to 1.3.24dwcjr2002-05-08