commit 515dd02ab9b52043e250629a98425bb50e608acd
parent c8b47d43cfcbcc581e184aa6b5696d949f816e6d
Author: Jean-Yves Lefort <jylefort@brutele.be>
Date: Thu, 9 Sep 2004 09:44:55 +1000
mail-notification-0.6.2
* Added STARTTLS support to the IMAP backend
* Added STLS support to the POP3 backend
* Now prompts the user before connecting to untrusted SSL/TLS
servers
* Added a "Start Mail Notification on GNOME login" option
* Added a "Blink on errors" option
* Commands are now executed in the user's shell
* The Gmail log is now dumped when --enable-info is in use
* Added a --unset-obsolete-configuration command line argument
* An obsolete mailbox list is now handled without being
rewritten (a step towards full forward compatibility of
GConf keys)
* "SSL" is now called "SSL/TLS", as we provide SSLv2, SSLv3
and TLSv1 support
* Fixed a typo in the MD5 code which prevented builds on some
platforms (reported by Andy Shaw)
* Automatic mailboxes were also polled: fixed
* Added German translations (Hendrik Brandt)
* Added Portuguese translations (Duarte Henriques)
* A few minor issues have been fixed
* Some cleanups have been performed
* Now requires GNOME version 2.6 or superior
Diffstat:
125 files changed, 9670 insertions(+), 5009 deletions(-)
diff --git a/AUTHORS b/AUTHORS
@@ -5,6 +5,9 @@
Developed by Jean-Yves Lefort <jylefort@brutele.be>.
Contributors:
+ * Hendrik Brandt <eru@gmx.li> (german translations)
+ * Duarte Henriques <duarte_henriques@myrealbox.com>
+ (portuguese translations)
* Dan Korostelev <dan@ats.energo.ru> (russian translations)
External art sources:
diff --git a/INSTALL b/INSTALL
@@ -10,7 +10,7 @@ Index
0. About this document
- $Id: INSTALL,v 1.8 2004/08/18 22:45:35 jylefort Exp $
+ $Id: INSTALL,v 1.10 2004/09/08 23:35:47 jylefort Exp $
Copyright (c) 2003, 2004 Jean-Yves Lefort.
@@ -24,7 +24,7 @@ Index
* GTK+ (version 2.4.0 or superior)
http://www.gtk.org/
- * GNOME (version 2.0 or superior)
+ * GNOME (version 2.6.0 or superior)
http://www.gnome.org/
Optional libraries:
@@ -34,7 +34,7 @@ Index
libsoup (version 1.99.28)
ftp://ftp.gnome.org/pub/GNOME/sources/libsoup/1.99/
- * for SSL support:
+ * for SSL/TLS support:
OpenSSL (version 0.9.5b or superior)
http://www.openssl.org/
@@ -54,9 +54,19 @@ Index
<get root privileges, if needed>
$ make install
- IMPORTANT: you must install Mail Notification in the same
- prefix as GNOME (commonly /usr or /opt/gnome).
+ IMPORTANT:
+ * You must install Mail Notification in the same
+ prefix as GNOME (commonly /usr or /opt/gnome). To
+ know where GNOME is installed on your system, type:
+
+ $ pkg-config --variable prefix libgnome-2.0
+
+ * Due to a bug in bonobo-activation
+ (http://bugzilla.gnome.org/show_bug.cgi?id=151082),
+ your session must be restarted after installing Mail
+ Notification.
+
The ./configure script behaviour can be changed using
command-line options: type "./configure --help" for an
exhaustive list.
diff --git a/Makefile.in b/Makefile.in
@@ -41,8 +41,8 @@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
mkinstalldirs
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
diff --git a/NEWS b/NEWS
@@ -1,3 +1,28 @@
+0.6.2 09 September 2004
+
+ * Added STARTTLS support to the IMAP backend
+ * Added STLS support to the POP3 backend
+ * Now prompts the user before connecting to untrusted SSL/TLS
+ servers
+ * Added a "Start Mail Notification on GNOME login" option
+ * Added a "Blink on errors" option
+ * Commands are now executed in the user's shell
+ * The Gmail log is now dumped when --enable-info is in use
+ * Added a --unset-obsolete-configuration command line argument
+ * An obsolete mailbox list is now handled without being
+ rewritten (a step towards full forward compatibility of
+ GConf keys)
+ * "SSL" is now called "SSL/TLS", as we provide SSLv2, SSLv3
+ and TLSv1 support
+ * Fixed a typo in the MD5 code which prevented builds on some
+ platforms (reported by Andy Shaw)
+ * Automatic mailboxes were also polled: fixed
+ * Added german translations (Henrik Brandt)
+ * Added portuguese translations (Duarte Henriques)
+ * A few minor issues have been fixed
+ * Some cleanups have been performed
+ * Now requires GNOME version 2.6 or superior
+
0.6.1 19 August 2004
* File descriptor leaks in the Sylpheed and Maildir backends
diff --git a/README b/README
@@ -6,12 +6,11 @@ Index
0. About this document
1. About Mail Notification
- 2. Release notes
- 3. Installation instructions
+ 2. Installation instructions
0. About this document
- $Id: README,v 1.18 2004/08/18 01:00:25 jylefort Exp $
+ $Id: README,v 1.21 2004/09/08 23:35:47 jylefort Exp $
Copyright (c) 2003, 2004 Jean-Yves Lefort.
@@ -35,23 +34,12 @@ Index
support
* SASL authentication support
* APOP authentication support
- * SSL support
+ * SSL/TLS support
* automatic detection of mailbox format
- * automatic notification
+ * immediate notification (the status icon is updated
+ within seconds after a mailbox changes)
* HIG 2.0 compliance
-2. Release notes
-
- In this release or in previous ones, some configuration keys
- have been obsoleted. For the sake of cleanliness, you should
- remove them, by typing:
-
- $ gconftool-2 --recursive-unset \
- /apps/mail-notification/local \
- /apps/mail-notification/remote \
- /apps/mail-notification/commands/clicked \
- /apps/mail-notification/ui/preferences-dialog
-
-3. Installation instructions
+2. Installation instructions
See the INSTALL file.
diff --git a/TODO b/TODO
@@ -1,3 +1,2 @@
-* add STARTTLS support to the IMAP backend
-* implement RFC 2965 cookie support
-* implement a MNURI object
+* Check the SSL certificate's hostname against the hostname we used
+ (RFC 3501, section 11.1)
diff --git a/aclocal.m4 b/aclocal.m4
@@ -772,6 +772,64 @@ chmod u+w intltool-update
])
+
+dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not)
+dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page
+dnl also defines GSTUFF_PKG_ERRORS on error
+AC_DEFUN(PKG_CHECK_MODULES, [
+ succeeded=no
+
+ if test -z "$PKG_CONFIG"; then
+ AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
+ fi
+
+ if test "$PKG_CONFIG" = "no" ; then
+ echo "*** The pkg-config script could not be found. Make sure it is"
+ echo "*** in your path, or set the PKG_CONFIG environment variable"
+ echo "*** to the full path to pkg-config."
+ echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
+ else
+ PKG_CONFIG_MIN_VERSION=0.9.0
+ if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
+ AC_MSG_CHECKING(for $2)
+
+ if $PKG_CONFIG --exists "$2" ; then
+ AC_MSG_RESULT(yes)
+ succeeded=yes
+
+ AC_MSG_CHECKING($1_CFLAGS)
+ $1_CFLAGS=`$PKG_CONFIG --cflags "$2"`
+ AC_MSG_RESULT($$1_CFLAGS)
+
+ AC_MSG_CHECKING($1_LIBS)
+ $1_LIBS=`$PKG_CONFIG --libs "$2"`
+ AC_MSG_RESULT($$1_LIBS)
+ else
+ $1_CFLAGS=""
+ $1_LIBS=""
+ ## If we have a custom action on failure, don't print errors, but
+ ## do set a variable so people can do so.
+ $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
+ ifelse([$4], ,echo $$1_PKG_ERRORS,)
+ fi
+
+ AC_SUBST($1_CFLAGS)
+ AC_SUBST($1_LIBS)
+ else
+ echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
+ echo "*** See http://www.freedesktop.org/software/pkgconfig"
+ fi
+ fi
+
+ if test $succeeded = yes; then
+ ifelse([$3], , :, [$3])
+ else
+ ifelse([$4], , AC_MSG_ERROR([Library requirements ($2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.]), [$4])
+ fi
+])
+
+
+
# -*- Autoconf -*-
# Copyright (C) 2002, 2003 Free Software Foundation, Inc.
# Generated from amversion.in; do not edit by hand.
@@ -1732,6 +1790,5 @@ INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
AC_SUBST([INSTALL_STRIP_PROGRAM])])
m4_include([m4/openssl.m4])
-m4_include([m4/pkg.m4])
m4_include([m4/sasl2.m4])
m4_include([acinclude.m4])
diff --git a/art/Makefile.in b/art/Makefile.in
@@ -39,8 +39,8 @@ DIST_COMMON = $(dist_app_pixmaps_DATA) $(dist_gnome_pixmaps_DATA) \
$(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/config.h.in b/config.h.in
@@ -177,7 +177,7 @@
/* Define to 1 if SASL support is enabled */
#undef WITH_SASL
-/* Define to 1 if SSL support is enabled */
+/* Define to 1 if SSL/TLS support is enabled */
#undef WITH_SSL
/* Define to 1 if Sylpheed support is enabled */
diff --git a/configure b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59 for mail-notification 0.6.1.
+# Generated by GNU Autoconf 2.59 for mail-notification 0.6.2.
#
# Report bugs to <jylefort@brutele.be>.
#
@@ -269,8 +269,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
# Identity of this package.
PACKAGE_NAME='mail-notification'
PACKAGE_TARNAME='mail-notification'
-PACKAGE_VERSION='0.6.1'
-PACKAGE_STRING='mail-notification 0.6.1'
+PACKAGE_VERSION='0.6.2'
+PACKAGE_STRING='mail-notification 0.6.2'
PACKAGE_BUGREPORT='jylefort@brutele.be'
ac_unique_file="src/mn-main.c"
@@ -780,7 +780,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures mail-notification 0.6.1 to adapt to many kinds of systems.
+\`configure' configures mail-notification 0.6.2 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -842,7 +842,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of mail-notification 0.6.1:";;
+ short | recursive ) echo "Configuration of mail-notification 0.6.2:";;
esac
cat <<\_ACEOF
@@ -854,7 +854,7 @@ Optional Features:
--disable-maildir disable Maildir support
--disable-pop3 disable POP3 support
--disable-imap disable IMAP support
- --disable-ssl disable SSL support
+ --disable-ssl disable SSL/TLS support
--disable-sasl disable SASL authentication support
--disable-sylpheed disable Sylpheed support
--disable-gmail disable Gmail support
@@ -986,7 +986,7 @@ fi
test -n "$ac_init_help" && exit 0
if $ac_init_version; then
cat <<\_ACEOF
-mail-notification configure 0.6.1
+mail-notification configure 0.6.2
generated by GNU Autoconf 2.59
Copyright (C) 2003 Free Software Foundation, Inc.
@@ -1000,7 +1000,7 @@ cat >&5 <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by mail-notification $as_me 0.6.1, which was
+It was created by mail-notification $as_me 0.6.2, which was
generated by GNU Autoconf 2.59. Invocation command line was
$ $0 $@
@@ -1828,7 +1828,7 @@ fi
# Define the identity of the package.
PACKAGE='mail-notification'
- VERSION='0.6.1'
+ VERSION='0.6.2'
cat >>confdefs.h <<_ACEOF
@@ -1991,7 +1991,7 @@ _ACEOF
-ALL_LINGUAS="fr ru"
+ALL_LINGUAS="de fr pt ru"
DEPDIR="${am__leading_dot}deps"
ac_config_commands="$ac_config_commands depfiles"
@@ -7201,12 +7201,11 @@ echo "$as_me: error: unable to find the GTK+ library" >&2;}
rm -f conf.gtktest
-found=no
-GNOME_CFLAGS=""
-GNOME_LIBS=""
-if test -z "$PKG_CONFIG"; then
- # Extract the first word of "pkg-config", so it can be a program name with args.
+ succeeded=no
+
+ if test -z "$PKG_CONFIG"; then
+ # Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
@@ -7246,45 +7245,59 @@ else
echo "${ECHO_T}no" >&6
fi
-fi
+ fi
-if test "x$PKG_CONFIG" = "xno" ; then
- { echo "$as_me:$LINENO: WARNING: the pkg-config script could not be found: make sure it is in your path, or set the PKG_CONFIG environment variable to the full path to pkg-config" >&5
-echo "$as_me: WARNING: the pkg-config script could not be found: make sure it is in your path, or set the PKG_CONFIG environment variable to the full path to pkg-config" >&2;}
-else
- PKG_CONFIG_MIN_VERSION=0.9.0
+ if test "$PKG_CONFIG" = "no" ; then
+ echo "*** The pkg-config script could not be found. Make sure it is"
+ echo "*** in your path, or set the PKG_CONFIG environment variable"
+ echo "*** to the full path to pkg-config."
+ echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
+ else
+ PKG_CONFIG_MIN_VERSION=0.9.0
+ if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
+ echo "$as_me:$LINENO: checking for gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0" >&5
+echo $ECHO_N "checking for gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0... $ECHO_C" >&6
- if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
- echo "$as_me:$LINENO: checking for gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0" >&5
-echo $ECHO_N "checking for gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0... $ECHO_C" >&6
+ if $PKG_CONFIG --exists "gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0" ; then
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ succeeded=yes
+
+ echo "$as_me:$LINENO: checking GNOME_CFLAGS" >&5
+echo $ECHO_N "checking GNOME_CFLAGS... $ECHO_C" >&6
+ GNOME_CFLAGS=`$PKG_CONFIG --cflags "gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0"`
+ echo "$as_me:$LINENO: result: $GNOME_CFLAGS" >&5
+echo "${ECHO_T}$GNOME_CFLAGS" >&6
+
+ echo "$as_me:$LINENO: checking GNOME_LIBS" >&5
+echo $ECHO_N "checking GNOME_LIBS... $ECHO_C" >&6
+ GNOME_LIBS=`$PKG_CONFIG --libs "gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0"`
+ echo "$as_me:$LINENO: result: $GNOME_LIBS" >&5
+echo "${ECHO_T}$GNOME_LIBS" >&6
+ else
+ GNOME_CFLAGS=""
+ GNOME_LIBS=""
+ ## If we have a custom action on failure, don't print errors, but
+ ## do set a variable so people can do so.
+ GNOME_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0"`
- if $PKG_CONFIG --exists "gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0"; then
- found=yes
+ fi
- GNOME_CFLAGS=`$PKG_CONFIG --cflags "gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0"`
- GNOME_LIBS=`$PKG_CONFIG --libs "gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0"`
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- fi
- else
- { echo "$as_me:$LINENO: WARNING: your version of pkg-config is too old, you need version $PKG_CONFIG_MIN_VERSION or newer" >&5
-echo "$as_me: WARNING: your version of pkg-config is too old, you need version $PKG_CONFIG_MIN_VERSION or newer" >&2;}
- fi
-fi
-if test $found = no; then
- { { echo "$as_me:$LINENO: error: unable to find the GNOME libraries" >&5
+ else
+ echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
+ echo "*** See http://www.freedesktop.org/software/pkgconfig"
+ fi
+ fi
+
+ if test $succeeded = yes; then
+ :
+ else
+ { { echo "$as_me:$LINENO: error: unable to find the GNOME libraries" >&5
echo "$as_me: error: unable to find the GNOME libraries" >&2;}
{ (exit 1); exit 1; }; }
-else
- :
-fi
-
-
+ fi
@@ -7568,12 +7581,11 @@ fi
have_soup=no
if test $enable_gmail = yes; then
- found=no
-SOUP_CFLAGS=""
-SOUP_LIBS=""
-if test -z "$PKG_CONFIG"; then
- # Extract the first word of "pkg-config", so it can be a program name with args.
+ succeeded=no
+
+ if test -z "$PKG_CONFIG"; then
+ # Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
@@ -7613,44 +7625,58 @@ else
echo "${ECHO_T}no" >&6
fi
-fi
-
-if test "x$PKG_CONFIG" = "xno" ; then
- { echo "$as_me:$LINENO: WARNING: the pkg-config script could not be found: make sure it is in your path, or set the PKG_CONFIG environment variable to the full path to pkg-config" >&5
-echo "$as_me: WARNING: the pkg-config script could not be found: make sure it is in your path, or set the PKG_CONFIG environment variable to the full path to pkg-config" >&2;}
-else
- PKG_CONFIG_MIN_VERSION=0.9.0
+ fi
- if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
- echo "$as_me:$LINENO: checking for soup-2.0" >&5
+ if test "$PKG_CONFIG" = "no" ; then
+ echo "*** The pkg-config script could not be found. Make sure it is"
+ echo "*** in your path, or set the PKG_CONFIG environment variable"
+ echo "*** to the full path to pkg-config."
+ echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
+ else
+ PKG_CONFIG_MIN_VERSION=0.9.0
+ if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
+ echo "$as_me:$LINENO: checking for soup-2.0" >&5
echo $ECHO_N "checking for soup-2.0... $ECHO_C" >&6
- if $PKG_CONFIG --exists "soup-2.0"; then
- found=yes
+ if $PKG_CONFIG --exists "soup-2.0" ; then
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ succeeded=yes
+
+ echo "$as_me:$LINENO: checking SOUP_CFLAGS" >&5
+echo $ECHO_N "checking SOUP_CFLAGS... $ECHO_C" >&6
+ SOUP_CFLAGS=`$PKG_CONFIG --cflags "soup-2.0"`
+ echo "$as_me:$LINENO: result: $SOUP_CFLAGS" >&5
+echo "${ECHO_T}$SOUP_CFLAGS" >&6
+
+ echo "$as_me:$LINENO: checking SOUP_LIBS" >&5
+echo $ECHO_N "checking SOUP_LIBS... $ECHO_C" >&6
+ SOUP_LIBS=`$PKG_CONFIG --libs "soup-2.0"`
+ echo "$as_me:$LINENO: result: $SOUP_LIBS" >&5
+echo "${ECHO_T}$SOUP_LIBS" >&6
+ else
+ SOUP_CFLAGS=""
+ SOUP_LIBS=""
+ ## If we have a custom action on failure, don't print errors, but
+ ## do set a variable so people can do so.
+ SOUP_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "soup-2.0"`
- SOUP_CFLAGS=`$PKG_CONFIG --cflags "soup-2.0"`
- SOUP_LIBS=`$PKG_CONFIG --libs "soup-2.0"`
+ fi
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- fi
- else
- { echo "$as_me:$LINENO: WARNING: your version of pkg-config is too old, you need version $PKG_CONFIG_MIN_VERSION or newer" >&5
-echo "$as_me: WARNING: your version of pkg-config is too old, you need version $PKG_CONFIG_MIN_VERSION or newer" >&2;}
- fi
-fi
-if test $found = no; then
- { echo "$as_me:$LINENO: WARNING: unable to find the soup library: forcing --disable-gmail" >&5
-echo "$as_me: WARNING: unable to find the soup library: forcing --disable-gmail" >&2;}; enable_gmail=no; disable_gmail_reason="(libsoup not found)"
-else
- have_soup=yes
-fi
+ else
+ echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
+ echo "*** See http://www.freedesktop.org/software/pkgconfig"
+ fi
+ fi
+ if test $succeeded = yes; then
+ have_soup=yes
+ else
+ { echo "$as_me:$LINENO: WARNING: unable to find the soup library: forcing --disable-gmail" >&5
+echo "$as_me: WARNING: unable to find the soup library: forcing --disable-gmail" >&2;}; enable_gmail=no; disable_gmail_reason="(libsoup not found)"
+ fi
fi
@@ -8391,7 +8417,7 @@ _ASBOX
} >&5
cat >&5 <<_CSEOF
-This file was extended by mail-notification $as_me 0.6.1, which was
+This file was extended by mail-notification $as_me 0.6.2, which was
generated by GNU Autoconf 2.59. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -8454,7 +8480,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-mail-notification config.status 0.6.1
+mail-notification config.status 0.6.2
configured by $0, generated by GNU Autoconf 2.59,
with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/configure.ac b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT(mail-notification, 0.6.1, jylefort@brutele.be)
+AC_INIT(mail-notification, 0.6.2, jylefort@brutele.be)
AC_CONFIG_SRCDIR(src/mn-main.c)
AC_PREREQ(2.59)
@@ -41,7 +41,7 @@ AC_HELP_STRING([--disable-imap], [disable IMAP support]),
esac], [enable_imap=yes])
AC_ARG_ENABLE(ssl,
-AC_HELP_STRING([--disable-ssl], [disable SSL support]),
+AC_HELP_STRING([--disable-ssl], [disable SSL/TLS support]),
[case "$enableval" in
yes|no) enable_ssl=$enableval ;;
*) AC_MSG_ERROR([bad value $enableval for --enable-ssl]) ;;
@@ -97,7 +97,7 @@ GETTEXT_PACKAGE=AC_PACKAGE_NAME
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Define to the gettext package name])
AC_SUBST(GETTEXT_PACKAGE)
-ALL_LINGUAS="fr ru"
+ALL_LINGUAS="de fr pt ru"
AM_GLIB_GNU_GETTEXT
AC_PROG_INTLTOOL
@@ -138,7 +138,7 @@ AC_CHECK_FUNCS(atoi close connect exit freeaddrinfo gai_strerror getaddrinfo get
AM_PATH_GTK_2_0(2.4.0,, [AC_MSG_ERROR([unable to find the GTK+ library])])
-AM_PATH_PKG(GNOME, [gthread-2.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 bonobo-activation-2.0],, [AC_MSG_ERROR([unable to find the GNOME libraries])])
+PKG_CHECK_MODULES(GNOME, [gthread-2.0 gconf-2.0 >= 2.4.0 libgnomeui-2.0 gnome-vfs-2.0 libglade-2.0 eel-2.0 >= 2.6.0 bonobo-activation-2.0],, [AC_MSG_ERROR([unable to find the GNOME libraries])])
AC_SUBST(GNOME_CFLAGS)
AC_SUBST(GNOME_LIBS)
@@ -172,7 +172,7 @@ fi
have_soup=no
if test $enable_gmail = yes; then
- AM_PATH_PKG(SOUP, soup-2.0, have_soup=yes, [AC_MSG_WARN([unable to find the soup library: forcing --disable-gmail]); enable_gmail=no; disable_gmail_reason="(libsoup not found)"])
+ PKG_CHECK_MODULES(SOUP, soup-2.0, have_soup=yes, [AC_MSG_WARN([unable to find the soup library: forcing --disable-gmail]); enable_gmail=no; disable_gmail_reason="(libsoup not found)"])
fi
ORBIT_IDL="`$PKG_CONFIG --variable=orbit_idl ORBit-2.0`"
@@ -219,7 +219,7 @@ if test $enable_imap = yes; then
AC_DEFINE(WITH_IMAP, 1, [Define to 1 if IMAP support is enabled])
fi
if test $enable_ssl = yes; then
- AC_DEFINE(WITH_SSL, 1, [Define to 1 if SSL support is enabled])
+ AC_DEFINE(WITH_SSL, 1, [Define to 1 if SSL/TLS support is enabled])
fi
if test $enable_sasl = yes; then
AC_DEFINE(WITH_SASL, 1, [Define to 1 if SASL support is enabled])
diff --git a/data/Makefile.in b/data/Makefile.in
@@ -38,8 +38,8 @@ subdir = data
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/data/mail-notification.schemas.in b/data/mail-notification.schemas.in
@@ -108,5 +108,38 @@
<long>Whether Mail Notification has already been run or not.</long>
</locale>
</schema>
+ <schema>
+ <key>/schemas/apps/mail-notification/blink-on-errors</key>
+ <applyto>/apps/mail-notification/blink-on-errors</applyto>
+ <owner>mail-notification</owner>
+ <type>bool</type>
+ <default>1</default>
+ <locale name="C">
+ <short>Blink on errors</short>
+ <long>Whether the status icon should blink on errors or not.</long>
+ </locale>
+ </schema>
+ <schema>
+ <key>/schemas/apps/mail-notification/trusted-x509-certificates</key>
+ <applyto>/apps/mail-notification/trusted-x509-certificates</applyto>
+ <owner>mail-notification</owner>
+ <type>list</type>
+ <list_type>string</list_type>
+ <locale name="C">
+ <short>Fingerprints of trusted X509 certificates</short>
+ <long>The list of trusted X509 certificates, represented by their MD5 fingerprint.</long>
+ </locale>
+ </schema>
+ <schema>
+ <key>/schemas/apps/mail-notification/trusted-servers</key>
+ <applyto>/apps/mail-notification/trusted-servers</applyto>
+ <owner>mail-notification</owner>
+ <type>list</type>
+ <list_type>string</list_type>
+ <locale name="C">
+ <short>Trusted servers list</short>
+ <long>The list of trusted SSL/TLS servers (hostname:port) lacking a X509 certificate.</long>
+ </locale>
+ </schema>
</schemalist>
</gconfschemafile>
diff --git a/help/C/Makefile.in b/help/C/Makefile.in
@@ -100,8 +100,8 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
subdir = help/C
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/help/C/mail-notification-C.omf b/help/C/mail-notification-C.omf
@@ -12,9 +12,9 @@
Mail Notification Manual
</title>
<date>
- 2004-08-19
+ 2004-09-09
</date>
- <version identifier="2.3" date="2004-08-19" description="Fourth release"/>
+ <version identifier="2.4" date="2004-09-09" description="Fifth release"/>
<subject category="GNOME|Internet"/>
<description>
Mail Notification Manual
diff --git a/help/C/mail-notification.xml b/help/C/mail-notification.xml
@@ -2,9 +2,9 @@
<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
<!ENTITY app "<application>Mail Notification</application>">
- <!ENTITY appversion "0.6.1">
- <!ENTITY manrevision "2.3">
- <!ENTITY date "Thursday, August 19, 2004">
+ <!ENTITY appversion "0.6.2">
+ <!ENTITY manrevision "2.4">
+ <!ENTITY date "Thursday, September 9, 2004">
<!ENTITY project "The Mail Notification Project">
@@ -20,12 +20,13 @@
<!ENTITY imap "<link linkend="imap">IMAP</link>">
<!ENTITY sasl "<link linkend="sasl">SASL</link>">
<!ENTITY ssl "<link linkend="pop3">SSL</link>">
+ <!ENTITY tls "<link linkend="pop3">TLS</link>">
<!ENTITY sylpheed "<link linkend="sylpheed">Sylpheed</link>">
<!ENTITY gmail "<link linkend="gmail">Gmail</link>">
<!ENTITY gnomevfs "<link linkend="gnomevfs">GnomeVFS</link>">
]>
-<!-- $Id: mail-notification.xml,v 1.37 2004/08/18 22:37:58 jylefort Exp $ -->
+<!-- $Id: mail-notification.xml,v 1.49 2004/09/08 23:26:57 jylefort Exp $ -->
<!-- Mail Notification Manual -->
<!-- Copyright (c) 2004 Jean-Yves Lefort -->
@@ -133,6 +134,17 @@
</revdescription>
</revision>
<revision>
+ <revnumber>Mail Notification Manual V2.3</revnumber>
+ <date>Thursday, August 19, 2004</date>
+ <revdescription>
+ <para role="author">
+ Jean-Yves Lefort
+ <email>jylefort@brutele.be</email>
+ </para>
+ <para role="publisher">&project;</para>
+ </revdescription>
+ </revision>
+ <revision>
<revnumber>Mail Notification Manual V2.2</revnumber>
<date>Monday, August 16, 2004</date>
<revdescription>
@@ -203,9 +215,9 @@
<listitem><para>&mbox;, &mh;, &maildir;, &sylpheed;, &pop3;, &imap; and &gmail; support</para></listitem>
<listitem><para>&sasl; authentication support</para></listitem>
<listitem><para>APOP authentication support</para></listitem>
- <listitem><para>&ssl; support</para></listitem>
+ <listitem><para>&ssl;/&tls; support</para></listitem>
<listitem><para>automatic detection of mailbox format</para></listitem>
- <listitem><para><link linkend="automatic-notification">automatic notification</link></para></listitem>
+ <listitem><para><link linkend="immediate-notification">immediate notification</link> (the status icon is updated within seconds after a mailbox changes)</para></listitem>
<listitem><para><ulink url="http://developer.gnome.org/projects/gup/hig" type="http">HIG</ulink> 2.0 compliance</para></listitem>
</itemizedlist>
</sect1>
@@ -291,6 +303,11 @@
</varlistentry>
<varlistentry>
+ <term>--unset-obsolete-configuration</term>
+ <listitem><para>Unset obsolete GConf configuration and exit</para></listitem>
+ </varlistentry>
+
+ <varlistentry>
<term>--help</term>
<listitem><para>Show help and exit</para></listitem>
</varlistentry>
@@ -324,7 +341,8 @@
</screenshot>
</figure>
<para>
- If an error is detected, the icon blinks.
+ If an error is detected, the icon blinks (unless the
+ <link linkend="blink-on-errors">Blink on errors</link> setting is disabled).
</para>
<para>
Leaving your mouse over the icon will reveal more details
@@ -339,27 +357,64 @@
<menuchoice>
<guimenu>Applications</guimenu>
<guisubmenu>Desktop Preferences</guisubmenu>
- <guimenuitem>Mail Notification</guimenuitem>
- </menuchoice>. The
- <guilabel>Properties</guilabel> dialog contains the following
- settings:
+ <guimenuitem>Mail Notification</guimenuitem>
+ </menuchoice> (or on some systems
+ <menuchoice>
+ <guimenu>Applications</guimenu>
+ <guisubmenu>Preferences</guisubmenu>
+ <guisubmenu>More Preferences</guisubmenu>
+ <guimenuitem>Mail Notification</guimenuitem>
+ </menuchoice>).
+ </para>
+ <para>
+ The <guilabel>Properties</guilabel> dialog contains the
+ following settings:
</para>
<variablelist>
- <varlistentry id="delay-between-mail-checks">
- <term><guilabel>Delay between mail checks</guilabel></term>
+ <varlistentry>
+ <term><guilabel>General</guilabel></term>
<listitem>
- <para>
- This is the amount of time to wait between mail checks.
- <note>
- <para>
- This delay only applies to mailboxes which do not
- support <link linkend="automatic-notification">automatic notification</link> of changes.
- </para>
- </note>
- </para>
+ <variablelist>
+ <varlistentry id="delay-between-mail-checks">
+ <term><guilabel>Delay between mail checks</guilabel></term>
+ <listitem>
+ <para>
+ This is the amount of time to wait between mail
+ checks.
+ <note>
+ <para>
+ This delay only applies to mailboxes which do
+ not support <link linkend="immediate-notification">immediate notification</link> of changes.
+ </para>
+ </note>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><guilabel>Start Mail Notification on GNOME login</guilabel></term>
+ <listitem>
+ <para>
+ If this option is enabled, &app; will be started
+ along with your GNOME session.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry id="blink-on-errors">
+ <term><guilabel>Blink on errors</guilabel></term>
+ <listitem>
+ <para>
+ If this option is enabled, &app; will show the
+ status icon and make it blink on errors. Disabling
+ this option is useful if some of your mailboxes are
+ not permanently accessible.
+ </para>
+ </listitem>
+ </varlistentry>
+ </variablelist>
</listitem>
</varlistentry>
+
<varlistentry>
<term><guilabel>Mailboxes</guilabel></term>
<listitem>
@@ -373,26 +428,36 @@
</para>
</listitem>
</varlistentry>
+
<varlistentry>
- <term><guilabel>When new mail arrives:</guilabel></term>
- <listitem>
- <para>
- This is the command to execute when new mail arrives.
- <note>
- <para>
- This command will not be executed if you already have
- new mail.
- </para>
- </note>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><guilabel>When double-clicked:</guilabel></term>
+ <term><guilabel>Commands</guilabel></term>
<listitem>
- <para>
- This is the command to execute when the icon is double-clicked.
- </para>
+ <variablelist>
+ <varlistentry>
+ <term><guilabel>When new mail arrives:</guilabel></term>
+ <listitem>
+ <para>
+ This is the command to execute when new mail
+ arrives.
+ <note>
+ <para>
+ This command will not be executed if you already
+ have new mail.
+ </para>
+ </note>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><guilabel>When double-clicked:</guilabel></term>
+ <listitem>
+ <para>
+ This is the command to execute when the icon is
+ double-clicked.
+ </para>
+ </listitem>
+ </varlistentry>
+ </variablelist>
</listitem>
</varlistentry>
</variablelist>
@@ -483,10 +548,13 @@
<title>Security</title>
<para>
To avoid sending your password over the network in
- clear text, you must eitheir use a SSL connection
- or select a secure authentication mechanism. See
- below for more details.
+ clear text, you must eitheir use a SSL/TLS
+ connection or select a secure authentication
+ mechanism. See below for more details.
</para>
+ <!-- simplified on purpose: actually, a weak SSL/TLS -->
+ <!-- algorithm could be used, but this is beyond the -->
+ <!-- scope of this document -->
</warning>
</listitem>
</varlistentry>
@@ -497,11 +565,28 @@
This is the type of connection to use and the port
number to connect to.
</para>
+ <para>
+ <guilabel>In-band SSL/TLS</guilabel> refers to a
+ &ssl;/&tls; connection negotiated inside of the
+ protocol (using the <literal>STLS</literal> &pop3;
+ command or the <literal>STARTTLS</literal> &imap;
+ command).
+ </para>
+ <para>
+ <guilabel>SSL/TLS on separate port</guilabel> refers to
+ the most widespread method for establishing a
+ &ssl;/&tls; connection: using a separate port.
+ </para>
<note>
<para>
The security considerations listed below do not
- apply if you select <guilabel>SSL</guilabel>.
+ apply if you select <guilabel>SSL/TLS</guilabel>
+ (eitheir <guilabel>in-band</guilabel> or
+ <guilabel>on separate port</guilabel>).
</para>
+ <!-- simplified on purpose: actually, a weak SSL/TLS -->
+ <!-- algorithm could be used, but this is beyond the -->
+ <!-- scope of this document -->
</note>
</listitem>
</varlistentry>
@@ -523,7 +608,7 @@
If <guilabel>autodetect</guilabel> is selected and
secure authentication fails, your credentials may
be sent over the network in clear text (unless you
- use a &ssl; connection).
+ use a &ssl;/&tls; connection).
</para>
<para>
If this is a concern, select the appropriate
@@ -602,16 +687,16 @@
<sect1 id="technical-information">
<title>Technical Information</title>
- <sect2 id="automatic-notification">
- <title>Automatic Notification</title>
+ <sect2 id="immediate-notification">
+ <title>Immediate Notification</title>
<para>
- Automatic notification is the ability to detect changes to a
+ Immediate notification is the ability to detect changes to a
mailbox without needing to poll it periodically. It allows the
status icon to be updated within seconds after a mailbox
- receives new mail.
+ changes.
</para>
<para>
- For automatic notification to be supported, &gnomevfs; must be compiled
+ For immediate notification to be supported, &gnomevfs; must be compiled
with <ulink url="http://oss.sgi.com/projects/fam" type="http">FAM</ulink> support,
and FAM must be configured properly.
</para>
@@ -622,7 +707,7 @@
</para>
<note>
<para>
- Automatic notification is only supported for local mailboxes.
+ Immediate notification is only supported for local mailboxes.
Mailboxes which do not support it will be checked periodically
according to the <link linkend="delay-between-mail-checks">Delay between mail checks</link>
setting.
@@ -635,8 +720,9 @@
<para>
The &app; &pop3; implementation strictly conforms to
<ulink url="http://www.ietf.org/rfc/rfc1939.txt" type="http">RFC 1939</ulink>,
- <ulink url="http://www.ietf.org/rfc/rfc2449.txt" type="http">RFC 2449</ulink> and
- <ulink url="http://www.ietf.org/rfc/rfc1734.txt" type="http">RFC 1734</ulink>.
+ <ulink url="http://www.ietf.org/rfc/rfc2449.txt" type="http">RFC 2449</ulink>,
+ <ulink url="http://www.ietf.org/rfc/rfc1734.txt" type="http">RFC 1734</ulink> and
+ <ulink url="http://www.ietf.org/rfc/rfc2595.txt" type="http">RFC 2595</ulink>.
</para>
<para>
The AUTH, APOP and USER/PASS authentication mechanisms are
@@ -723,6 +809,8 @@ endif</programlisting>
<itemizedlist>
<!-- We don't use <firstname> and <surname> because we can't -->
<!-- unambiguously split some names. -->
+ <listitem><para>Hendrik Brandt</para></listitem>
+ <listitem><para>Duarte Henriques</para></listitem>
<listitem><para>Dan Korostelev</para></listitem>
<listitem><para>Phil Nelson</para></listitem>
</itemizedlist>
@@ -879,6 +967,26 @@ endif</programlisting>
</glossentry>
</glossdiv>
+ <glossdiv><title>T</title>
+ <glossentry>
+ <glossterm>TLS</glossterm>
+ <glosssee otherterm="tls"/>
+ </glossentry>
+
+ <glossentry id="tls">
+ <glossterm>Transport Layer Security</glossterm>
+ <acronym>TLS</acronym>
+ <glossdef>
+ <para>
+ A protocol securing a connection through the use of
+ cryptographic techniques, as defined by
+ <ulink url="http://www.ietf.org/rfc/rfc2246.txt" type="http">RFC 2246</ulink>.
+ TLS is the successor of &ssl;.
+ </para>
+ </glossdef>
+ </glossentry>
+ </glossdiv>
+
<glossdiv><title>U</title>
<glossentry id="uri">
<glossterm>Uniform Resource Identifier</glossterm>
diff --git a/help/Makefile.in b/help/Makefile.in
@@ -37,8 +37,8 @@ subdir = help
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/m4/Makefile.am b/m4/Makefile.am
@@ -1 +1 @@
-EXTRA_DIST = pkg.m4
+EXTRA_DIST = openssl.m4 sasl2.m4
diff --git a/m4/Makefile.in b/m4/Makefile.in
@@ -37,8 +37,8 @@ subdir = m4
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
@@ -201,7 +201,7 @@ sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
-EXTRA_DIST = pkg.m4
+EXTRA_DIST = openssl.m4 sasl2.m4
all: all-am
.SUFFIXES:
diff --git a/m4/pkg.m4 b/m4/pkg.m4
@@ -1,52 +0,0 @@
-# $Id: pkg.m4,v 1.5 2004/05/26 18:02:11 jylefort Exp $
-#
-# This file is part of Mail Notification.
-#
-# Copyright (c) 2002, 2003, 2004 Jean-Yves Lefort.
-#
-# As a special exception to the Mail Notification licensing terms,
-# Jean-Yves Lefort gives unlimited permission to copy, distribute and
-# modify this file.
-
-dnl AM_PATH_PKG(VARIABLE_PREFIX, MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-dnl
-AC_DEFUN([AM_PATH_PKG],
-[found=no
-$1_CFLAGS=""
-$1_LIBS=""
-
-if test -z "$PKG_CONFIG"; then
- AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
-fi
-
-if test "x$PKG_CONFIG" = "xno" ; then
- AC_MSG_WARN([the pkg-config script could not be found: make sure it is in your path, or set the PKG_CONFIG environment variable to the full path to pkg-config])
-else
- PKG_CONFIG_MIN_VERSION=0.9.0
-
- if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
- AC_MSG_CHECKING([for $2])
-
- if $PKG_CONFIG --exists "$2"; then
- found=yes
-
- $1_CFLAGS=`$PKG_CONFIG --cflags "$2"`
- $1_LIBS=`$PKG_CONFIG --libs "$2"`
-
- AC_MSG_RESULT(yes)
- else
- AC_MSG_RESULT(no)
- fi
- else
- AC_MSG_WARN([your version of pkg-config is too old, you need version $PKG_CONFIG_MIN_VERSION or newer])
- fi
-fi
-
-if test $found = no; then
- ifelse([$4],, :, [$4])
-else
- ifelse([$3],, :, [$3])
-fi
-
-AC_SUBST($1_CFLAGS)
-AC_SUBST($1_LIBS)])
diff --git a/po/POTFILES.in b/po/POTFILES.in
@@ -16,8 +16,6 @@ src/mn-client-session.c
src/mn-client-session.h
src/mn-conf.c
src/mn-conf.h
-src/mn-dialog.c
-src/mn-dialog.h
src/mn-gmail-mailbox-properties.gob
src/mn-gmail-mailbox.gob
src/mn-imap-mailbox-properties.gob
@@ -56,13 +54,11 @@ src/mn-stock.h
src/mn-sylpheed-mailbox.gob
src/mn-system-mailbox-properties.gob
src/mn-unsupported-mailbox.gob
-src/mn-uri.c
-src/mn-uri.h
+src/mn-uri.gob
src/mn-util.c
src/mn-util.h
src/mn-vfs.c
src/mn-vfs.h
-ui/dialog.glade
ui/mailbox-properties.glade
ui/properties.glade
ui/welcome.glade
diff --git a/po/de.gmo b/po/de.gmo
Binary files differ.
diff --git a/po/de.po b/po/de.po
@@ -0,0 +1,1263 @@
+# German translations for mail-notification.
+# Copyright (c) 2003, 2004 Jean-Yves Lefort.
+#
+# This file is distributed under the same license as the
+# mail-notification package.
+#
+# Hendrik Brandt <eru@gmx.li>, 2004.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: mail-notification 0.6.1\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2004-09-09 01:43+0200\n"
+"PO-Revision-Date: 2004-09-08 23:26+0200\n"
+"Last-Translator: Hendrik Brandt <eru@gmx.li>\n"
+"Language-Team: German <gnome-de@gnome.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
+
+#: data/GNOME_MailNotification_Automation.server.in.in.h:1
+msgid "Mail Notification automation"
+msgstr "Automatische E-Mail-Eingangsüberwachnung"
+
+#: data/GNOME_MailNotification_Automation.server.in.in.h:2
+#, fuzzy
+msgid "Mail Notification automation factory"
+msgstr "Automatische E-Mail-Eingangsüberwachnung"
+
+#: data/mail-notification-properties.desktop.in.h:1
+msgid "Configure Mail Notification"
+msgstr "Die E-Mail-Eingangsüberwachung einstellen"
+
+#: data/mail-notification-properties.desktop.in.h:2
+#: data/mail-notification.desktop.in.h:2
+#: data/mail-notification.soundlist.in.h:1 src/mn-about-dialog.gob:38
+#: src/mn-mail-icon.gob:160 src/mn-main.c:221
+msgid "Mail Notification"
+msgstr "E-Mail-Eingangsüberwachung"
+
+#: data/mail-notification.desktop.in.h:1
+msgid "Get notified when new mail arrives"
+msgstr "Informiert Sie wenn eine neue Nachricht eintrifft"
+
+#: data/mail-notification.schemas.in.h:1
+msgid "Blink on errors"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:2
+msgid "Delay between mail checks (minutes part)."
+msgstr "Abstand zwischen Eingangsüberprüfung (Minutenteil)."
+
+#: data/mail-notification.schemas.in.h:3
+msgid "Delay between mail checks (seconds part)."
+msgstr "Abstand zwischen Eingangsüberprüfung (Sekundenteil)."
+
+#: data/mail-notification.schemas.in.h:4
+msgid "Double-clicked command"
+msgstr "Auszuführender Befehl bei Doppelklick"
+
+#: data/mail-notification.schemas.in.h:5
+msgid "Fingerprints of trusted X509 certificates"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:6
+msgid "Has already been run"
+msgstr "Wurde schon einmal gestartet"
+
+#: data/mail-notification.schemas.in.h:7
+msgid "Height of properties dialog"
+msgstr "Höhe des Einstellungen-Dialogs"
+
+#: data/mail-notification.schemas.in.h:8
+msgid "Mailboxes list"
+msgstr "Liste der Postfächer"
+
+#: data/mail-notification.schemas.in.h:9
+msgid "Minutes between mail checks"
+msgstr "Minuten zwischen den Aktualisierungen"
+
+#: data/mail-notification.schemas.in.h:10
+msgid "New mail command"
+msgstr "Befehl bei neuer Nachricht"
+
+#: data/mail-notification.schemas.in.h:11
+msgid "Run a command when new mail arrives"
+msgstr "Einen Befehl ausführen, wenn eine neue Nachricht eintrifft"
+
+#: data/mail-notification.schemas.in.h:12
+msgid "Run a command when the icon is double-clicked"
+msgstr ""
+"Einen Befehl ausführen, wenn das Nachrichtensymbol doppelt angeklickt wird"
+
+#: data/mail-notification.schemas.in.h:13
+msgid "Seconds between mail checks"
+msgstr "Sekunden zwischen den Aktualisierungen"
+
+#: data/mail-notification.schemas.in.h:14
+msgid "The command to run when new mail arrives."
+msgstr "Der Befehl der ausgeführt wird, wenn eine neue Nachricht eintrifft."
+
+#: data/mail-notification.schemas.in.h:15
+msgid "The command to run when the icon is double-clicked."
+msgstr ""
+"Der Befehl der ausgeführt wird, wenn das Nachrichtensymbol doppelt "
+"angeklickt wird."
+
+#: data/mail-notification.schemas.in.h:16
+msgid "The height of the properties dialog in pixels."
+msgstr "Die Höhe des Einstellungsdialogs in Pixel."
+
+#: data/mail-notification.schemas.in.h:17
+msgid "The list of mailboxes to monitor."
+msgstr "Die Liste der zu überwachenden Postfächer."
+
+#: data/mail-notification.schemas.in.h:18
+msgid ""
+"The list of trusted SSL/TLS servers (hostname:port) lacking a X509 "
+"certificate."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:19
+msgid ""
+"The list of trusted X509 certificates, represented by their MD5 fingerprint."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:20
+msgid "The width of the properties dialog in pixels."
+msgstr "Die Breite des Einstellungen-Dialogs in Pixel."
+
+#: data/mail-notification.schemas.in.h:21
+msgid "Trusted servers list"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:22
+msgid "Whether Mail Notification has already been run or not."
+msgstr ""
+"Legt fest, ob die E-Mail-Eingangsüberwachnung schon einmal gestartet wurde."
+
+#: data/mail-notification.schemas.in.h:23
+#, fuzzy
+msgid "Whether the status icon should blink on errors or not."
+msgstr "Legt fest, ob das Bild blinkt oder nicht"
+
+#: data/mail-notification.schemas.in.h:24
+msgid "Whether to run a command when new mail arrives or not."
+msgstr ""
+"Legt fest, ob ein Befehl ausgeführt wird, wenn eine neue Nachricht eintrifft."
+
+#: data/mail-notification.schemas.in.h:25
+msgid "Whether to run a command when the icon is double-clicked or not."
+msgstr ""
+"Legt fest, ob ein Befehl ausgeführt wird, wenn das Nachrichtensymbol doppelt "
+"angeklickt wird."
+
+#: data/mail-notification.schemas.in.h:26
+msgid "Width of properties dialog"
+msgstr "Breite des Einstellungen-Dialogs"
+
+#: data/mail-notification.soundlist.in.h:2
+msgid "New Mail"
+msgstr "Neue Nachricht"
+
+#: src/eggtrayicon.c:109
+msgid "Orientation"
+msgstr "Ausrichtung"
+
+#: src/eggtrayicon.c:110
+msgid "The orientation of the tray."
+msgstr "Die Ausrichtung des Benachrichtigungsfeldes"
+
+#: src/mn-about-dialog.gob:41
+msgid "A Mail Notification Icon"
+msgstr ""
+"Ein Benachrichtigungssymbol das erscheint, wenn neue Nachrichten in Ihren "
+"Postfächern liegen."
+
+#: src/mn-about-dialog.gob:44
+msgid "Jean-Yves Lefort <jylefort@brutele.be>"
+msgstr "Hendrik Brandt <eru@gmx.li>"
+
+#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:35
+msgid "<span style=\"italic\">autodetect</span>"
+msgstr "<span style=\"italic\">automatisch erkennen</span>"
+
+#: src/mn-autodetect-mailbox-properties.gob:66
+msgid "_Location:"
+msgstr "_Ort:"
+
+#: src/mn-autodetect-mailbox-properties.gob:72
+msgid "_Browse..."
+msgstr "_Durchsuchen..."
+
+#: src/mn-autodetect-mailbox-properties.gob:79
+msgid "The URI of the mailbox"
+msgstr "Die Adresse des Postfachs"
+
+#: src/mn-autodetect-mailbox-properties.gob:116
+msgid "Select a File or Folder"
+msgstr "Wählen Sie eine Datei oder ein Verzeichnis"
+
+#: src/mn-blinking-image.gob:30
+msgid "Whether the image is blinking or not"
+msgstr "Legt fest, ob das Bild blinkt oder nicht"
+
+#: src/mn-client-session.c:196 src/mn-client-session.c:203
+#, c-format
+msgid "unable to read from server: %s"
+msgstr "Es konnte nicht vom Server gelesen werden: %s"
+
+#: src/mn-client-session.c:201
+msgid "unable to read from server: EOF"
+msgstr "Es konnte nicht vom Server gelesen werden: EOF"
+
+#: src/mn-client-session.c:213
+#, c-format
+msgid "unable to decode data using SASL: %s"
+msgstr "Die Daten konnten nicht per SASL dekodiert werden: %s"
+
+#: src/mn-client-session.c:284
+#, c-format
+msgid "resolving %s"
+msgstr "%s wird kontaktiert"
+
+#: src/mn-client-session.c:294
+#, c-format
+msgid "unable to resolve %s: %s"
+msgstr "%s konnte nicht kontaktiert werden: %s"
+
+#: src/mn-client-session.c:331
+#, c-format
+msgid "%s: unsupported address family"
+msgstr "%s: Adressfamilie wird nicht unterstützt"
+
+#: src/mn-client-session.c:338
+#, c-format
+msgid "%s: unable to create socket: %s"
+msgstr "%s: Socket konnte nciht erstellt werden: %s"
+
+#: src/mn-client-session.c:342
+#, c-format
+msgid "connecting to %s (%s) port %i"
+msgstr "Verbindung mit %s (%s) über Port %i wird hergestellt"
+
+#: src/mn-client-session.c:345
+#, c-format
+msgid "unable to connect: %s"
+msgstr "Es konnte nicht verbunden werden: %s"
+
+#: src/mn-client-session.c:350
+msgid "connected successfully"
+msgstr "Verbindung hergestellt"
+
+#. if reached, we couldn't find a working address
+#: src/mn-client-session.c:356
+#, c-format
+msgid "unable to connect to %s"
+msgstr "Es konnte keine Verbindung mit %s hergestellt werden"
+
+#: src/mn-client-session.c:372
+#, c-format
+msgid "unable to initialize the OpenSSL library: %s"
+msgstr "Die OpenSSL-Bibliothek konnte nicht initializiert werden: %s"
+
+#: src/mn-client-session.c:380
+#, fuzzy, c-format
+msgid "unable to create a SSL/TLS object: %s"
+msgstr "Es konnte kein SSL-Objekt erzeugt werden: %s"
+
+#: src/mn-client-session.c:386
+#, fuzzy, c-format
+msgid "unable to set the SSL/TLS file descriptor: %s"
+msgstr "Es konnte kein SSL-Dateideskriptor gesetzt werden: %s"
+
+#: src/mn-client-session.c:392
+#, fuzzy, c-format
+msgid "unable to perform the SSL/TLS handshake: %s"
+msgstr "Es konnte kein SSL-Dateideskriptor gesetzt werden: %s"
+
+#: src/mn-client-session.c:398
+msgid "untrusted server"
+msgstr ""
+
+#: src/mn-client-session.c:402
+#, c-format
+msgid "a SSL/TLS layer is now active (%s, %s %i-bit)"
+msgstr ""
+
+#: src/mn-client-session.c:449
+#, c-format
+msgid "%s, fingerprint: %s"
+msgstr ""
+
+#: src/mn-client-session.c:478
+msgid "missing certificate"
+msgstr ""
+
+#: src/mn-client-session.c:504
+#, c-format
+msgid ""
+"Mail Notification was unable to trust \"%s\" (%s). It is possible that "
+"someone is intercepting your communication to obtain your confidential "
+"information.\n"
+"\n"
+"You should only connect to the server if you are certain you are connected "
+"to \"%s\". If you choose to connect to the server, this message will not be "
+"shown again."
+msgstr ""
+
+#: src/mn-client-session.c:521
+msgid "Connect to untrusted server?"
+msgstr ""
+
+#: src/mn-client-session.c:526
+msgid "Co_nnect"
+msgstr ""
+
+#: src/mn-client-session.c:584
+#, c-format
+msgid "response \"%s\" is not valid in current context"
+msgstr "Die Antwort »%s« ist in diesem Kontext nicht zugelassen"
+
+#: src/mn-client-session.c:610
+#, c-format
+msgid "unable to parse response \"%s\""
+msgstr "Die Antwort »%s« konnte nicht analysiert werden"
+
+#: src/mn-client-session.c:657
+#, c-format
+msgid "unable to encode data using SASL: %s"
+msgstr "Die Daten konnten nicht per SASL kodiert werden: %s"
+
+#: src/mn-client-session.c:688 src/mn-client-session.c:695
+#, c-format
+msgid "unable to write to server: %s"
+msgstr "Es konnte nicht auf den Server geschrieben werden: %s"
+
+#: src/mn-client-session.c:693
+msgid "unable to write to server: EOF"
+msgstr "Es konnte nicht auf den Server geschrieben werden: EOF"
+
+#: src/mn-client-session.c:725
+#, c-format
+msgid "unable to encode Base64: %s"
+msgstr "Es konnte nicht mit Base64 kodiert werden: %s"
+
+#: src/mn-client-session.c:828
+#, c-format
+msgid "unable to initialize the SASL library: %s"
+msgstr "Die SASL-Bibliothek konnte nicht initializiert werden: %s"
+
+#: src/mn-client-session.c:837
+#, c-format
+msgid "unable to retrieve local address of socket: %s"
+msgstr "Die lokale Adresse des Socket konnte nicht herausgefunden werden: %s"
+
+#: src/mn-client-session.c:843
+#, c-format
+msgid "unable to retrieve remote address of socket: %s"
+msgstr ""
+"Die entfernte Adresse des Socket konnte nicht herausgefunden werden: %s"
+
+#: src/mn-client-session.c:877
+#, c-format
+msgid "warning: unable to set SASL security properties: %s"
+msgstr ""
+"Warnung: Die SASL-Sicherheitseigenschaften konnten nicht gesetzt werden: %s"
+
+#: src/mn-client-session.c:916
+msgid ""
+"unable to start SASL authentication: SASL asked for something we did not know"
+msgstr ""
+"Die SASL-Authentifizierung konnte nicht gestartet werden: es wurde eine "
+"unbekannte Anfrage von SASL gestellt"
+
+#: src/mn-client-session.c:920
+#, c-format
+msgid "unable to start SASL authentication: %s"
+msgstr "Die SASL-Authentifizierung konnte nicht gestartet werden: %s"
+
+#: src/mn-client-session.c:924
+#, c-format
+msgid "unable to create a SASL connection: %s"
+msgstr "Es konnte keine Verbindung mit SASL erzeugt werden: %s"
+
+#: src/mn-client-session.c:974
+msgid "SASL asked for something we did not know, aborting SASL authentication"
+msgstr ""
+"Es wurde eine unbekannte Anfrage von SASL gestellt, SASL-Authentifizierung "
+"wird abgebrochen"
+
+#: src/mn-client-session.c:978
+#, c-format
+msgid "%s, aborting SASL authentication"
+msgstr "%s, SASL-Authentifizierung wird abgebrochen"
+
+#. compliance error
+#: src/mn-client-session.c:983
+#, c-format
+msgid "unable to decode Base64 input from server: %s"
+msgstr "Die Server-seitige Base64-Eingabe konnte nicht dekodiert werden: %s"
+
+#: src/mn-client-session.c:986
+msgid ""
+"the server sent a SASL challenge, but there was a pending initial SASL "
+"client response"
+msgstr ""
+
+#: src/mn-client-session.c:1000
+msgid ""
+"the server did not send a SASL challenge, but there was no pending initial "
+"SASL client response"
+msgstr ""
+
+#: src/mn-client-session.c:1023
+#, c-format
+msgid "a SASL security layer of strength factor %i is now active"
+msgstr "Die SASL-Sicherheitsebene der Stärke %i ist jetzt aktiv"
+
+#. a security layer is active but we can't retrieve maxoutbuf -> fatal
+#: src/mn-client-session.c:1028
+#, c-format
+msgid "unable to get SASL_MAXOUTBUF property: %s"
+msgstr "Der Wert SASL_MAXOUTBUF wurde nicht gefunden: %s"
+
+#: src/mn-client-session.c:1034
+#, c-format
+msgid "warning: unable to get SASL_SSF property: %s"
+msgstr "Warnung: Der Wert SASL_SSF wurde nicht gefunden: %s"
+
+#: src/mn-conf.c:109
+#, c-format
+msgid "recursively unsetting %s"
+msgstr ""
+
+#: src/mn-conf.c:113
+msgid "syncing the GConf database"
+msgstr ""
+
+#: src/mn-conf.c:116
+#, fuzzy
+msgid "completed"
+msgstr "Vollständig"
+
+#: src/mn-gmail-mailbox-properties.gob:77
+msgid "Your Gmail username"
+msgstr "Ihr Gmail-Benutzername"
+
+#: src/mn-gmail-mailbox-properties.gob:78
+msgid "Your Gmail password"
+msgstr "Ihr Gmail-Passwort"
+
+#: src/mn-gmail-mailbox.gob:220
+#, fuzzy
+msgid "logging in"
+msgstr "Anmelden bei"
+
+#: src/mn-gmail-mailbox.gob:239 src/mn-gmail-mailbox.gob:279
+#: src/mn-gmail-mailbox.gob:313 src/mn-gmail-mailbox.gob:418
+#, c-format
+msgid "unable to transfer data: %s"
+msgstr "Daten konnten nicht übertragen werden: %s"
+
+#: src/mn-gmail-mailbox.gob:265 src/mn-gmail-mailbox.gob:299
+#: src/mn-gmail-mailbox.gob:334
+msgid "login failed"
+msgstr "Anmeldung fehlgeschlagen"
+
+#: src/mn-gmail-mailbox.gob:328
+msgid "successfully logged in"
+msgstr "Anmeldung war erfolgreich"
+
+#: src/mn-gmail-mailbox.gob:406
+msgid "searching for unread mail"
+msgstr "Es wird nach ungelesenen Nachrichten gesucht"
+
+#: src/mn-gmail-mailbox.gob:427
+msgid "unable to parse Gmail data"
+msgstr "Die Gmail-Daten konnte nicht analysiert werden"
+
+#: src/mn-imap-mailbox-properties.gob:92
+msgid "Mailbox:"
+msgstr "Postfach:"
+
+#: src/mn-imap-mailbox-properties.gob:96
+msgid "in_box"
+msgstr "In_box"
+
+#: src/mn-imap-mailbox-properties.gob:107
+msgid "oth_er:"
+msgstr "_Anderer:"
+
+#: src/mn-imap-mailbox-properties.gob:122
+msgid "The hostname or IP address of the IMAP server"
+msgstr "Der Name oder die IP-Adresse des IMAP-Servers"
+
+#: src/mn-imap-mailbox-properties.gob:123
+msgid "Your username on the IMAP server"
+msgstr "Ihr Benutzername auf dem IMAP-Server"
+
+#: src/mn-imap-mailbox-properties.gob:124
+msgid "Your password on the IMAP server"
+msgstr "Ihr Passwort auf dem IMAP-Server"
+
+#: src/mn-imap-mailbox-properties.gob:125
+#: src/mn-imap-mailbox-properties.gob:126
+msgid "The port number of the IMAP server"
+msgstr "Die Port-Nummer auf dem IMAP-Server"
+
+#: src/mn-imap-mailbox-properties.gob:127
+msgid "The mailbox name"
+msgstr "Der Postfachname"
+
+#: src/mn-imap-mailbox.gob:112 src/mn-pop3-mailbox.gob:125
+#, fuzzy
+msgid "SSL/TLS support has not been compiled in"
+msgstr ""
+"Die Unterstützung für SSL wurde beim Erstellen des Programms nicht eingebaut"
+
+#: src/mn-imap-mailbox.gob:179
+msgid "server did not send capabilities"
+msgstr "Der Server hat seine Fähigkeiten nicht bekannt gegeben"
+
+#: src/mn-imap-mailbox.gob:292
+msgid "server advertised LOGINDISABLED, not using LOGIN authentication"
+msgstr ""
+"Der Server gibt LOGINDISABLED zurück, LOGIN-Authentifizierung wird nicht "
+"verwendet"
+
+#: src/mn-imap-mailbox.gob:293
+msgid "unable to login"
+msgstr "Anmeldung fehlgeschlagen"
+
+#. compliance error
+#: src/mn-imap-mailbox.gob:361
+msgid "server did not send status"
+msgstr "Der Server hat seinen Status nicht bekannt gegeben"
+
+#: src/mn-imap-mailbox.gob:583 src/mn-pop3-mailbox.gob:744
+msgid "unknown server error"
+msgstr "Unbekannter Server-Fehler"
+
+#: src/mn-imap-mailbox.gob:656 src/mn-pop3-mailbox.gob:210
+#, fuzzy
+msgid "server does not support in-band SSL/TLS"
+msgstr "Der Server unterstütz eine Authentifizierung per APOP nicht."
+
+#: src/mn-imap-mailbox.gob:675 src/mn-pop3-mailbox.gob:674
+msgid ""
+"a SASL authentication mechanism was selected but SASL support has not been "
+"compiled in"
+msgstr ""
+"Sie haben eine Authentifizierung mit SASL ausgewählt, jedoch wurde die "
+"Unterstützung für SASL beim Erstellen des Programms nicht eingebaut"
+
+#: src/mn-imap-mailbox.gob:683 src/mn-pop3-mailbox.gob:686
+#, c-format
+msgid "unknown authentication mechanism \"%s\""
+msgstr "Unbekannte Authentifizierungsmethode »%s«"
+
+#: src/mn-imap-mailbox.gob:701
+msgid "falling back to IMAP LOGIN authentication"
+msgstr "Es wird auf die Authentifizierung per IMAP LOGIN zurückgegriffen"
+
+#: src/mn-imap-mailbox.gob:705 src/mn-pop3-mailbox.gob:720
+msgid "authentication failed"
+msgstr "Authentifizierung fehlgeschlagen"
+
+#: src/mn-mail-icon.gob:81
+msgid "_Update"
+msgstr "_Aktualisieren"
+
+#: src/mn-mail-icon.gob:87
+msgid "R_emove From Notification Area"
+msgstr "Aus dem Benachrichtigungsfeld entfernen"
+
+#: src/mn-mail-icon.gob:172
+#, c-format
+msgid "_Run %s"
+msgstr "%s a_usführen"
+
+#: src/mn-mail-icon.gob:173
+msgid "_Run Default Action"
+msgstr "_Standard Aktion ausführen"
+
+#: src/mn-mailbox-properties-dialog.c:109
+msgid "Add a Mailbox"
+msgstr "Ein Postfach hinzufügen"
+
+#: src/mn-mailbox-properties-dialog.c:331
+#, c-format
+msgid "%s Properties"
+msgstr "%s Eigenschaften"
+
+#: src/mn-mailbox-properties-util.c:77
+msgid "_Username:"
+msgstr "Ben_utzername:"
+
+#: src/mn-mailbox-properties-util.c:87
+msgid "_Password:"
+msgstr "_Passwort:"
+
+#: src/mn-mailbox-properties-util.c:154
+msgid "Connection type:"
+msgstr "Verbindungsart:"
+
+#: src/mn-mailbox-properties-util.c:161
+msgid "Port:"
+msgstr "Port:"
+
+#: src/mn-mailbox-properties-util.c:189
+msgid "_Authentication mechanism:"
+msgstr "_Authentifizierungsmethode:"
+
+#: src/mn-mailbox-properties.c:63
+msgid "Label"
+msgstr "Bezeichnung"
+
+#: src/mn-mailbox-properties.c:64
+msgid "The marked up text to show in the type combo box"
+msgstr ""
+
+#: src/mn-mailbox-properties.c:69
+msgid "Size group"
+msgstr ""
+
+#: src/mn-mailbox-properties.c:70
+msgid "A GtkSizeGroup for aligning control labels"
+msgstr ""
+
+#: src/mn-mailbox-properties.c:75
+msgid "Complete"
+msgstr "Vollständig"
+
+#: src/mn-mailbox-properties.c:76
+msgid "Whether the properties are completely filled or not"
+msgstr "Legt fest, ob die Einstellungen vollständig ausgefüllt sind"
+
+#: src/mn-mailbox-view.gob:254
+msgid "Mailbox"
+msgstr "Postfach"
+
+#: src/mn-mailbox-view.gob:268
+msgid "Format"
+msgstr "Protokoll"
+
+#: src/mn-mailbox-view.gob:543
+msgid "Unable to add mailbox"
+msgstr "Postfach konnte nicht hinzugefügt werden"
+
+#: src/mn-mailbox-view.gob:543
+msgid "The mailbox is already in the list."
+msgstr "Dieses Postfach exisitiert bereits in Ihrer Liste."
+
+#: src/mn-mailbox.gob:122
+msgid "The mailbox URI"
+msgstr "Die Postfachadresse"
+
+#: src/mn-mailbox.gob:133
+msgid "The mailbox human-readable name"
+msgstr "Der lesbare Postfachname"
+
+#: src/mn-mailbox.gob:137
+msgid "Whether the mailbox has to be manually checked or not"
+msgstr "Legt fest, ob das Postfach manuell überprüft werden soll"
+
+#: src/mn-mailbox.gob:142
+msgid "Whether the mailbox has new mail or not"
+msgstr "Legt fest, ob das Postfach neue Nachrichten enthält"
+
+#: src/mn-mailbox.gob:147
+msgid "The mailbox error, if any"
+msgstr "Der Postfachfehler, falls vorhanden"
+
+#: src/mn-mailbox.gob:251
+msgid "does not exist"
+msgstr "existiert nicht"
+
+#: src/mn-mailbox.gob:287
+msgid "unknown format"
+msgstr "unbekanntes Format"
+
+#: src/mn-mailbox.gob:355
+#, c-format
+msgid "unable to monitor %s: %s"
+msgstr "%s konnte nicht überwacht werden: %s"
+
+#: src/mn-mailbox.gob:369
+#, fuzzy, c-format
+msgid ""
+"As a fallback, they will be checked every %i second (this delay is "
+"configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked every %i seconds (this delay is "
+"configurable from the Properties Dialog)."
+msgstr[0] ""
+"Als Rücksicherung werden die Postfächer alle %i Sekunden überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Sekunden überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+msgstr[1] ""
+"Als Rücksicherung werden die Postfächer alle %i Sekunden überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Sekunden überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+
+#: src/mn-mailbox.gob:380
+#, fuzzy, c-format
+msgid ""
+"As a fallback, they will be checked every %i minute (this delay is "
+"configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked every %i minutes (this delay is "
+"configurable from the Properties Dialog)."
+msgstr[0] ""
+"Als Rücksicherung werden die Postfächer alle %i Minuten überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Minuten überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+msgstr[1] ""
+"Als Rücksicherung werden die Postfächer alle %i Minuten überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Minuten überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+
+#: src/mn-mailbox.gob:391
+#, fuzzy, c-format
+msgid ""
+"As a fallback, they will be checked approximately every %i minute (this "
+"delay is configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked approximately every %i minutes (this "
+"delay is configurable from the Properties Dialog)."
+msgstr[0] ""
+"Als Rücksicherung werden die Postfächer alle %i Minuten überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Minuten überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+msgstr[1] ""
+"Als Rücksicherung werden die Postfächer alle %i Minuten überprüft (Dieser "
+"Wert kann über den Einstellungen-Dialog angepasst werden).Als Rücksicherung "
+"werden die Postfächer alle %i Minuten überprüft (Dieser Wert kann über den "
+"Einstellungen-Dialog angepasst werden)."
+
+#: src/mn-mailbox.gob:405
+msgid "A monitoring error has occurred"
+msgstr "Bei der Überwachung ist ein Fehler aufgetreten"
+
+#: src/mn-mailbox.gob:406
+#, fuzzy, c-format
+msgid ""
+"Mail Notification was unable to enable immediate notification for one or "
+"more mailboxes. %s"
+msgstr ""
+"Die E-Mail-Eingangsüberwachung konnte die automatische Benachrichtigung für "
+"ein oder mehrere Postfächer nicht aktivieren: %s"
+
+#: src/mn-mailboxes.gob:143
+#, c-format
+msgid "%s is unsupported: %s"
+msgstr "%s wird nicht unterstützt: %s"
+
+#: src/mn-mailboxes.gob:170
+#, c-format
+msgid "%s has new mail"
+msgstr "%s hat neue Nachrichten"
+
+#: src/mn-mailboxes.gob:170
+#, c-format
+msgid "%s has no new mail"
+msgstr "%s hat keine neuen Nachrichten"
+
+#: src/mn-mailboxes.gob:186
+#, c-format
+msgid "%s reported an error: %s"
+msgstr "%s hat einen Fehler erzeugt: %s"
+
+#: src/mn-maildir-mailbox.gob:109
+#, c-format
+msgid "unable to open folder \"new\": %s"
+msgstr "Der Ordner »new« konnte nicht geöffnet werden: %s"
+
+#: src/mn-maildir-mailbox.gob:137
+#, c-format
+msgid "unable to close folder \"new\": %s"
+msgstr "Der Ordner »new« konnte nicht geschlossen werden: %s"
+
+#: src/mn-maildir-mailbox.gob:140
+#, c-format
+msgid "error while reading folder \"new\": %s"
+msgstr "Fehler beim Lesen des Ordners »new«: %s"
+
+#: src/mn-main.c:85
+#, c-format
+msgid "Compiled-in mailbox backends: %s\n"
+msgstr "Eingebaute Postfacharten: %s\n"
+
+#: src/mn-main.c:103
+#, c-format
+msgid "Compiled-in features: %s\n"
+msgstr "Eingebaute Programmfähigkeiten: %s\n"
+
+#: src/mn-main.c:133
+msgid "Enable informational output"
+msgstr "Ausgabe von Informationen aktivieren"
+
+#: src/mn-main.c:142
+msgid "List compiled-in features and exit"
+msgstr "Eingebaute Programmfähigkeiten anzeigen und beenden"
+
+#: src/mn-main.c:151
+msgid "Display the properties dialog"
+msgstr "Den Dialog zum Einstellen der E-Mail-Eingangsüberwachung anzeigen"
+
+#: src/mn-main.c:160
+msgid "Display the about dialog"
+msgstr "Den Info-Dialog anzeigen"
+
+#: src/mn-main.c:169
+msgid "Update the mail status"
+msgstr "Nach neuen Nachrichten sehen"
+
+#: src/mn-main.c:178
+msgid "Report the mail status"
+msgstr "Den aktuellen Nachrichten anzeigen"
+
+#: src/mn-main.c:187
+msgid "Unset obsolete GConf configuration and exit"
+msgstr ""
+
+#.
+#. * We can't use mn_error_dialog() because gtk_init() has not been
+#. * called yet.
+#.
+#: src/mn-main.c:213
+msgid "multi-threading is not available"
+msgstr "Multi-Threading steht nicht zur Verfügung"
+
+#: src/mn-main.c:258
+msgid ""
+"Bonobo could not locate the automation object. Please check your Mail "
+"Notification installation."
+msgstr ""
+"Bonobo konnte das Automatisierungsobjekt nicht finden. Bitte überprüfen Sie "
+"Ihre Installation der E-Mail-Eingangsüberwachung."
+
+#: src/mn-main.c:263
+msgid "Unable to initialize the GnomeVFS library."
+msgstr "Die GnomeVFS-Bibliothek konnte nicht initializiert werden."
+
+#: src/mn-main.c:285
+msgid "updating the mail status"
+msgstr "Nachrichtenstatus wird aktualisiert"
+
+#: src/mn-main.c:301
+msgid "Mail Notification is already running"
+msgstr "Die E-Mail-Eingangsüberwachung ist bereits aktiv"
+
+#: src/mn-main.c:308
+msgid ""
+"Bonobo could not locate the GNOME_MailNotification_Automation.server file. "
+"Please check your Mail Notification installation."
+msgstr ""
+"Bonobo konnte die Datei GNOME_MailNotification_Automation.server nicht "
+"finden. Bitte überprüfen Sie Ihre Installation der E-Mail-"
+"Eingangsüberwachung."
+
+#: src/mn-main.c:312
+msgid ""
+"Bonobo was unable to register the automation server. Please check your Mail "
+"Notification installation."
+msgstr ""
+"Bonobo konnte den Automatisierungs-Server nicht registrieren.Bitte "
+"überprüfen Sie Ihre Installation der E-Mail-Eingangsüberwachung."
+
+#: src/mn-mbox-mailbox.gob:171
+#, c-format
+msgid "error while reading mailbox: %s"
+msgstr "Postfach konnte nicht neu geladen werden: %s"
+
+#: src/mn-mbox-mailbox.gob:179
+#, c-format
+msgid "unable to open mailbox: %s"
+msgstr "Postfach konnte nicht geöffnet werden: %s"
+
+#: src/mn-mh-mailbox.gob:122
+#, c-format
+msgid "error while reading .mh_sequences: %s"
+msgstr "Fehler beim lesen der .mh_sequences: %s"
+
+#: src/mn-mh-mailbox.gob:130
+#, c-format
+msgid "unable to open .mh_sequences: %s"
+msgstr ".mh_sequences konnten nicht geöffnet werden: %s"
+
+#: src/mn-pending-mailbox.gob:33
+msgid "detecting"
+msgstr "ermitteln"
+
+#: src/mn-pi-mailbox-properties.gob:74
+msgid "_Hostname:"
+msgstr "_Server:"
+
+#: src/mn-pi-mailbox-properties.gob:92
+msgid "_Details"
+msgstr "_Details"
+
+#: src/mn-pi-mailbox-properties.gob:104
+msgid "sta_ndard"
+msgstr "Sta_ndard"
+
+#: src/mn-pi-mailbox-properties.gob:114
+msgid "_in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-pi-mailbox-properties.gob:124
+msgid "SSL/TLS on sepa_rate port"
+msgstr ""
+
+#: src/mn-pop3-mailbox-properties.gob:84
+msgid "The hostname or IP address of the POP3 server"
+msgstr "Der Name oder die IP-Adresse des POP3-Servers"
+
+#: src/mn-pop3-mailbox-properties.gob:85
+msgid "Your username on the POP3 server"
+msgstr "Ihr Benutzername für diesen POP3-Server"
+
+#: src/mn-pop3-mailbox-properties.gob:86
+msgid "Your password on the POP3 server"
+msgstr "Ihr Passwort für diesen POP3-Server"
+
+#: src/mn-pop3-mailbox-properties.gob:87 src/mn-pop3-mailbox-properties.gob:88
+msgid "The port number of the POP3 server"
+msgstr "Die Port-Nummer des POP3-Servers"
+
+#: src/mn-pop3-mailbox.gob:256
+msgid "invalid arguments for the LOGIN-DELAY capability"
+msgstr "Ungültige Argumente für die Anmeldeverzögerung"
+
+#: src/mn-pop3-mailbox.gob:523
+#, c-format
+msgid "honouring LOGIN-DELAY, sleeping for %i second"
+msgid_plural "honouring LOGIN-DELAY, sleeping for %i seconds"
+msgstr[0] ""
+"Anmeldeverzögerung wird berücksichtigt, es wird für eine Sekunde gewartet"
+msgstr[1] ""
+"Anmeldeverzögerung wird berücksichtigt, es wird für %i Sekunden gewartet"
+
+#: src/mn-pop3-mailbox.gob:682
+msgid "server does not support APOP authentication"
+msgstr "Der Server unterstütz eine Authentifizierung per APOP nicht."
+
+#: src/mn-pop3-mailbox.gob:710
+msgid "falling back to APOP authentication"
+msgstr "Es wird auf Authentifizierung mit APOP zurück gegriffen."
+
+#: src/mn-pop3-mailbox.gob:715
+msgid "falling back to USER/PASS authentication"
+msgstr ""
+"Es wird auf Authentifizierung per Nutzername und Passwort zurück gegriffen."
+
+#: src/mn-properties.c:151
+msgid "No mailbox selected."
+msgstr "Kein Postfach ausgewählt."
+
+#: src/mn-properties.c:156
+#, c-format
+msgid "%i mailbox selected."
+msgid_plural "%i mailboxes selected."
+msgstr[0] "Ein Posfach ausgewählt."
+msgstr[1] "%i Postfächer ausgewählt."
+
+#: src/mn-shell.gob:204
+msgid "A command error has occurred"
+msgstr "Es ist ein Fehler beim Ausführen des Befehls aufgetreten"
+
+#: src/mn-shell.gob:205
+#, c-format
+msgid "Unable to execute double-clicked command: %s."
+msgstr ""
+"Der Befehl für einen Symboldoppelklick konnte nicht ausgeführt werden: %s."
+
+#: src/mn-shell.gob:292
+msgid "The following mailbox has new mail:\n"
+msgid_plural "The following mailboxes have new mail:\n"
+msgstr[0] "Dieses Postfach hat neue Nachrichten:\n"
+msgstr[1] "Diese Postfächer haben neue Nachrichten:\n"
+
+#: src/mn-shell.gob:296
+msgid "You have no new mail."
+msgstr "Sie haben keine neuen Nachrichten."
+
+#: src/mn-shell.gob:299
+msgid "The following mailbox reported an error:\n"
+msgid_plural "The following mailboxes reported an error:\n"
+msgstr[0] "Das folgende Postfach hat einen Fehler ausgegeben:\n"
+msgstr[1] "Die folgenden Postfächer haben einen Fehler ausgegeben:\n"
+
+#: src/mn-shell.gob:304
+msgid "The following mailbox is unsupported:\n"
+msgid_plural "The following mailboxes are unsupported:\n"
+msgstr[0] "Das folgende Postfach wird nicht unterstützt:\n"
+msgstr[1] "Die folgenden Postfächer werden nicht unterstützt:\n"
+
+#: src/mn-shell.gob:320
+msgid "You have new mail."
+msgstr "Sie haben neue Nachrichten."
+
+#: src/mn-shell.gob:330
+msgid "A command error has occurred in Mail Notification"
+msgstr ""
+"Es ist ein Fehler beim Ausführen eines Befehls in der E-Mail-"
+"Eingangsüberwachung aufgetreten."
+
+#: src/mn-shell.gob:331
+#, c-format
+msgid "Unable to execute new mail command: %s."
+msgstr "Der Befehl für neue E-Mails konnte nicht ausgeführt werden: %s."
+
+#: src/mn-ssl.c:79
+#, fuzzy
+msgid "unknown SSL/TLS error"
+msgstr "Unbekannter Server-Fehler"
+
+#: src/mn-stock.c:28
+msgid "Select _All"
+msgstr "_Alles auswählen"
+
+#: src/mn-sylpheed-mailbox.gob:93
+#, c-format
+msgid "unable to open folder: %s"
+msgstr "Ordner konnte nicht geöffnet werden: %s"
+
+#: src/mn-sylpheed-mailbox.gob:127
+#, c-format
+msgid "unable to close folder: %s"
+msgstr "Ordner konnte nicht geschlossen werden: %s"
+
+#: src/mn-sylpheed-mailbox.gob:130
+#, c-format
+msgid "error while reading folder: %s"
+msgstr "Fehler beim Lesen von Ordner: %s"
+
+#: src/mn-system-mailbox-properties.gob:32 src/mn-uri.gob:391
+msgid "System Mailbox"
+msgstr "Systempostfach"
+
+#: src/mn-system-mailbox-properties.gob:55
+#, c-format
+msgid "Your system mailbox (<span weight=\"bold\">%s</span>) will be used."
+msgstr ""
+"Es wird Ihr Systempostfach (<span weight=\"bold\">%s</span>) verwendet."
+
+#: src/mn-system-mailbox-properties.gob:62
+msgid ""
+"The location of your system mailbox could not be detected. Please set the "
+"MAIL environment variable."
+msgstr ""
+"Der Ort Ihres Systempostfachs wurde nicht erkannt. Bitte setzen Sie die "
+"Umgebungsvariable »MAIL«."
+
+#: src/mn-unsupported-mailbox.gob:31
+msgid "The reason why the mailbox is unsupported"
+msgstr "Der Grund weshalb dieses Postfach nicht unerstützt wird"
+
+#: src/mn-unsupported-mailbox.gob:38
+msgid "unsupported"
+msgstr "nicht unterstützt"
+
+#: src/mn-util.c:199
+#, c-format
+msgid "error loading image: %s"
+msgstr "Bild konnte nicht geladen werden: %s"
+
+#: src/mn-util.c:237
+#, c-format
+msgid "widget %s not found in interface %s"
+msgstr "Widget %s konnte nicht in Interface %s gefunden werden"
+
+#: src/mn-util.c:355
+msgid "received an invalid URI list"
+msgstr "Es wurde eine ungültige Adressliste erhalten"
+
+#: src/mn-util.c:391
+msgid "received an invalid Mozilla URL"
+msgstr "Es wurde eine ungültige Mozilla-Adresse erhalten"
+
+#: src/mn-util.c:484
+msgid "Unable to display help"
+msgstr "Die Hilfe kann nicht angezeigt werden"
+
+#: src/mn-util.c:498
+#, c-format
+msgid "Unable to create a thread: %s."
+msgstr "Es konnte kein Thread erzeugt werden: %s."
+
+#: src/mn-util.c:701
+msgid "A fatal error has occurred in Mail Notification"
+msgstr ""
+"Ein schwerwiegender Fehler ist beim Ausführen der E-Mail-Eingangsüberwachung "
+"aufgetreten"
+
+#: ui/mailbox-properties.glade.h:1
+msgid "_Mailbox type:"
+msgstr "_Art des Postfachs:"
+
+#: ui/properties.glade.h:1
+msgid " "
+msgstr " "
+
+#: ui/properties.glade.h:2
+msgid "*"
+msgstr "*"
+
+#: ui/properties.glade.h:3
+msgid "<span weight=\"bold\">Commands</span>"
+msgstr "<span weight=\"bold\">Befehle</span>"
+
+#: ui/properties.glade.h:4
+msgid "<span weight=\"bold\">General</span>"
+msgstr "<span weight=\"bold\">Allgemein</span>"
+
+#: ui/properties.glade.h:5
+msgid "<span weight=\"bold\">Mailboxes</span>"
+msgstr "<span weight=\"bold\">Postfächer</span>"
+
+#: ui/properties.glade.h:6
+msgid "Mail Notification Properties"
+msgstr "Einstellung der E-Mail-Eingangsüberwachung"
+
+#: ui/properties.glade.h:7
+msgid "The amount of time to wait between mail checks"
+msgstr "Die Zeit die zwischen zwei Überprüfungen auf neue Nachrichten vergeht"
+
+#: ui/properties.glade.h:8
+msgid "The command to run when new mail arrives"
+msgstr ""
+"Geben Sie hier den Befehl ein, der ausgeführt wird sobald eine neue "
+"Nachricht eintrifft."
+
+#: ui/properties.glade.h:9
+msgid "The command to run when the icon is double-clicked"
+msgstr ""
+"Geben Sie hier den Befehl ein, der ausgeführt wird sobald das "
+"Benachrichtigungssymbol doppelt angeklickt wird."
+
+#: ui/properties.glade.h:10
+msgid "When _new mail arrives:"
+msgstr "Wenn neue Nachricht _eintrifft:"
+
+#: ui/properties.glade.h:11
+msgid "When double-click_ed:"
+msgstr "Wenn _doppelt angeklickt:"
+
+#: ui/properties.glade.h:12
+#, fuzzy
+msgid "Whether the status icon should blink on errors or not"
+msgstr "Legt fest, ob das Bild blinkt oder nicht"
+
+#: ui/properties.glade.h:13
+msgid "Whether to run a command when new mail arrives or not"
+msgstr ""
+"Wenn diese Option ausgewählt ist, können Sie einen Befehl angeben der "
+"ausgeführt wird, sobald eine neue Nachricht eintrifft."
+
+#: ui/properties.glade.h:14
+msgid "Whether to run a command when the icon is double-clicked or not"
+msgstr ""
+"Wenn diese Option ausgewählt ist, können Sie einen Befehl angeben der "
+"ausgeführt wird, sobald das Benachrichtigungssymbol doppelt angeklickt wird."
+
+#: ui/properties.glade.h:15
+#, fuzzy
+msgid ""
+"Whether to start Mail Notification when you log into your GNOME session or "
+"not"
+msgstr ""
+"Legt fest, ob die E-Mail-Eingangsüberwachnung schon einmal gestartet wurde."
+
+#: ui/properties.glade.h:16
+msgid "_Blink on errors"
+msgstr ""
+
+#: ui/properties.glade.h:17
+msgid "_Delay between mail checks:"
+msgstr "_Nach neuen Nachrichten sehen alle:"
+
+#: ui/properties.glade.h:18
+#, fuzzy
+msgid "_Start Mail Notification on GNOME login"
+msgstr ""
+"Ein Benachrichtigungssymbol das erscheint, wenn neue Nachrichten in Ihren "
+"Postfächern liegen."
+
+#: ui/properties.glade.h:19
+msgid "minutes"
+msgstr "Minuten"
+
+#: ui/properties.glade.h:20
+msgid "seconds"
+msgstr "Sekunden"
+
+#: ui/welcome.glade.h:1
+#, fuzzy
+msgid ""
+"<span weight=\"bold\" size=\"larger\">First startup</span>\n"
+"\n"
+"Mail Notification has been loaded successfully.\n"
+"\n"
+"Since this is the first time you run Mail Notification, you might want to "
+"configure it.\n"
+"\n"
+"Note: this message will not be shown anymore. To configure Mail Notification "
+"again, choose <span weight=\"bold\">Applications</span> → <span weight=\"bold"
+"\">Desktop Preferences</span> → <span weight=\"bold\">Mail Notification</"
+"span> (or on some systems <span weight=\"bold\">Applications → Preferences → "
+"More Preferences → Mail Notification</span>)."
+msgstr ""
+"<span weight=\"bold\" size=\"larger\">Erster Start</span>\n"
+"\n"
+"Die E-Mail-Eingangsüberwachung wurde erfolgreich geladen.\n"
+"\n"
+"Da dies das erste Mal ist, dass Sie die E-Mail-Eingangsüberwachnung starten, "
+"möchten Sie vielleicht einige Einstellungen vornehmen.\n"
+"\n"
+"Hinweis: Diese Meldung wird nicht erneut angezeigt. Um die E-Mail-"
+"Eingangsüberwachnung zu einem später Zeitpunkt einzustellen, starten Sie "
+"bitte <span weight=\"bold\">Anwendungen</span> → <span weight=\"bold"
+"\">Desktop-Einstellungen</span> → <span weight=\"bold\">E-Mail-"
+"Eingangsüberwachnung</span>."
+
+#: ui/welcome.glade.h:8
+msgid "_Configure Mail Notification"
+msgstr "Die E-Mail-Eingangsüberwachung anpassen"
+
+#: ui/welcome.glade.h:9
+msgid "_Skip configuration"
+msgstr "Konfiguration über_springen"
+
+#~ msgid "unable to parse Gmail URI"
+#~ msgstr "Die Gmail-Adresse konnte nicht analysiert werden"
+
+#~ msgid "unable to parse IMAP URI"
+#~ msgstr "Die IMAP-Adresse konnte nicht analysiert werden"
+
+#~ msgid ""
+#~ "As a fallback, they will be checked approximately every %i minute (this "
+#~ "delay is configurable from the Properties Dialog).As a fallback, they "
+#~ "will be checked approximately every %i minutes (this delay is "
+#~ "configurable from the Properties Dialog)."
+#~ msgstr ""
+#~ "Als Rücksicherung werden die Postfächer durchschnittlich alle %i Minuten "
+#~ "überprüft (Dieser Wert kann über den Einstellungen-Dialog angepasst "
+#~ "werden).Als Rücksicherung werden die Postfächer durchschnittlich alle %i "
+#~ "Minuten überprüft (Dieser Wert kann über den Einstellungen-Dialog "
+#~ "angepasst werden)."
+
+#~ msgid "_SSL"
+#~ msgstr "_SSL"
+
+#~ msgid "unable to parse POP3 URI"
+#~ msgstr "POP3-Adresse konnte nicht analysiert werden"
diff --git a/po/fr.gmo b/po/fr.gmo
Binary files differ.
diff --git a/po/fr.po b/po/fr.po
@@ -8,10 +8,10 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: mail-notification 0.6.1\n"
+"Project-Id-Version: mail-notification 0.6.2\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2004-08-19 00:12+0200\n"
-"PO-Revision-Date: 2004-08-19 00:04+0200\n"
+"POT-Creation-Date: 2004-09-09 01:43+0200\n"
+"PO-Revision-Date: 2004-09-09 01:37+0200\n"
"Last-Translator: Jean-Yves Lefort <jylefort@brutele.be>\n"
"Language-Team: Jean-Yves Lefort <jylefort@brutele.be>\n"
"MIME-Version: 1.0\n"
@@ -34,7 +34,7 @@ msgstr "Configurer la Notification de Courrier"
#: data/mail-notification-properties.desktop.in.h:2
#: data/mail-notification.desktop.in.h:2
#: data/mail-notification.soundlist.in.h:1 src/mn-about-dialog.gob:38
-#: src/mn-mail-icon.gob:160 src/mn-main.c:212
+#: src/mn-mail-icon.gob:160 src/mn-main.c:221
msgid "Mail Notification"
msgstr "Notification de Courrier"
@@ -43,84 +43,115 @@ msgid "Get notified when new mail arrives"
msgstr "Etre notifié lorsque du nouveau courrier arrive"
#: data/mail-notification.schemas.in.h:1
+msgid "Blink on errors"
+msgstr "Clignoter lors d'erreurs"
+
+#: data/mail-notification.schemas.in.h:2
msgid "Delay between mail checks (minutes part)."
msgstr "Délai entre les vérifications de courrier (partie minutes)."
-#: data/mail-notification.schemas.in.h:2
+#: data/mail-notification.schemas.in.h:3
msgid "Delay between mail checks (seconds part)."
msgstr "Délai entre les vérifications de courrier (partie secondes)."
-#: data/mail-notification.schemas.in.h:3
+#: data/mail-notification.schemas.in.h:4
msgid "Double-clicked command"
msgstr "Commande associée au double-click"
-#: data/mail-notification.schemas.in.h:4
+#: data/mail-notification.schemas.in.h:5
+msgid "Fingerprints of trusted X509 certificates"
+msgstr "Empreintes digitales des certificats X509 de confiance"
+
+#: data/mail-notification.schemas.in.h:6
msgid "Has already been run"
msgstr "A déjà été exécuté"
-#: data/mail-notification.schemas.in.h:5
+#: data/mail-notification.schemas.in.h:7
msgid "Height of properties dialog"
msgstr "Hauteur de la boîte de dialogue contenant les propriétés"
-#: data/mail-notification.schemas.in.h:6
+#: data/mail-notification.schemas.in.h:8
msgid "Mailboxes list"
msgstr "Liste des boîtes aux lettres"
-#: data/mail-notification.schemas.in.h:7
+#: data/mail-notification.schemas.in.h:9
msgid "Minutes between mail checks"
msgstr "Minutes entre les vérifications de courrier"
-#: data/mail-notification.schemas.in.h:8
+#: data/mail-notification.schemas.in.h:10
msgid "New mail command"
msgstr "Commande de nouveau message"
-#: data/mail-notification.schemas.in.h:9
+#: data/mail-notification.schemas.in.h:11
msgid "Run a command when new mail arrives"
msgstr "Exécuter une commande lorsque du nouveau courrier arrive"
-#: data/mail-notification.schemas.in.h:10
+#: data/mail-notification.schemas.in.h:12
msgid "Run a command when the icon is double-clicked"
msgstr "Exécuter une commande lorsque l'îcone est double-cliquée"
-#: data/mail-notification.schemas.in.h:11
+#: data/mail-notification.schemas.in.h:13
msgid "Seconds between mail checks"
msgstr "Secondes entre les vérifications de courrier"
-#: data/mail-notification.schemas.in.h:12
+#: data/mail-notification.schemas.in.h:14
msgid "The command to run when new mail arrives."
msgstr "La commande à exécuter lorsque du nouveau courrier arrive."
-#: data/mail-notification.schemas.in.h:13
+#: data/mail-notification.schemas.in.h:15
msgid "The command to run when the icon is double-clicked."
msgstr "La commande à exécuter lorsque l'îcone est double-cliquée."
-#: data/mail-notification.schemas.in.h:14
+#: data/mail-notification.schemas.in.h:16
msgid "The height of the properties dialog in pixels."
msgstr "La hauteur de la boîte de dialogue contenant les propriétés en pixels."
-#: data/mail-notification.schemas.in.h:15
+#: data/mail-notification.schemas.in.h:17
msgid "The list of mailboxes to monitor."
msgstr "La liste des boîtes aux lettres à surveiller."
-#: data/mail-notification.schemas.in.h:16
+#: data/mail-notification.schemas.in.h:18
+msgid ""
+"The list of trusted SSL/TLS servers (hostname:port) lacking a X509 "
+"certificate."
+msgstr ""
+"La liste des serveurs SSL/TLS (hôte:port) de confiance auxquels il manque un "
+"certificat X509."
+
+#: data/mail-notification.schemas.in.h:19
+msgid ""
+"The list of trusted X509 certificates, represented by their MD5 fingerprint."
+msgstr ""
+"La liste des certificats X509 de confiance, représentés par leur empreinte "
+"digitale."
+
+#: data/mail-notification.schemas.in.h:20
msgid "The width of the properties dialog in pixels."
msgstr "La largeur de la boîte de dialogue contenant les propriétés en pixels."
-#: data/mail-notification.schemas.in.h:17
+#: data/mail-notification.schemas.in.h:21
+msgid "Trusted servers list"
+msgstr "Liste des serveurs de confiance"
+
+#: data/mail-notification.schemas.in.h:22
msgid "Whether Mail Notification has already been run or not."
msgstr "Si la Notification de Courrier a déjà été exécutée ou pas."
-#: data/mail-notification.schemas.in.h:18
+#: data/mail-notification.schemas.in.h:23
+msgid "Whether the status icon should blink on errors or not."
+msgstr "Si l'icône de status doit clignoter lors d'erreurs ou pas."
+
+#: data/mail-notification.schemas.in.h:24
msgid "Whether to run a command when new mail arrives or not."
msgstr ""
"Si une commande doit être exécutée lorsque du nouveau courrier arrive ou pas."
-#: data/mail-notification.schemas.in.h:19
+#: data/mail-notification.schemas.in.h:25
msgid "Whether to run a command when the icon is double-clicked or not."
msgstr ""
"Si une commande doit être exécutée lorsque l'îcone est double-cliquée ou pas."
-#: data/mail-notification.schemas.in.h:20
+#: data/mail-notification.schemas.in.h:26
msgid "Width of properties dialog"
msgstr "Largeur de la boîte de dialogue contenant les propriétés"
@@ -144,23 +175,23 @@ msgstr "Une Icône de Notification de Courrier"
msgid "Jean-Yves Lefort <jylefort@brutele.be>"
msgstr "Jean-Yves Lefort <jylefort@brutele.be>"
-#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:36
+#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:35
msgid "<span style=\"italic\">autodetect</span>"
msgstr "<span style=\"italic\">autodétecter</span>"
-#: src/mn-autodetect-mailbox-properties.gob:67
+#: src/mn-autodetect-mailbox-properties.gob:66
msgid "_Location:"
msgstr "_Emplacement:"
-#: src/mn-autodetect-mailbox-properties.gob:73
+#: src/mn-autodetect-mailbox-properties.gob:72
msgid "_Browse..."
msgstr "_Parcourir..."
-#: src/mn-autodetect-mailbox-properties.gob:80
+#: src/mn-autodetect-mailbox-properties.gob:79
msgid "The URI of the mailbox"
msgstr "L'URI de la boîte aux lettres"
-#: src/mn-autodetect-mailbox-properties.gob:117
+#: src/mn-autodetect-mailbox-properties.gob:116
msgid "Select a File or Folder"
msgstr "Sélectionnez un Fichier ou Dossier"
@@ -168,160 +199,210 @@ msgstr "Sélectionnez un Fichier ou Dossier"
msgid "Whether the image is blinking or not"
msgstr "Si l'image clignote ou pas"
-#: src/mn-client-session.c:195 src/mn-client-session.c:202
+#: src/mn-client-session.c:196 src/mn-client-session.c:203
#, c-format
msgid "unable to read from server: %s"
msgstr "impossible de lire depuis le serveur: %s"
-#: src/mn-client-session.c:200
+#: src/mn-client-session.c:201
msgid "unable to read from server: EOF"
msgstr "impossible de lire depuis le serveur: EOF"
-#: src/mn-client-session.c:212
+#: src/mn-client-session.c:213
#, c-format
msgid "unable to decode data using SASL: %s"
msgstr "impossible de décoder les données en utilisant SASL: %s"
-#: src/mn-client-session.c:286
+#: src/mn-client-session.c:284
#, c-format
msgid "resolving %s"
msgstr "résolution de %s en cours"
-#: src/mn-client-session.c:296
+#: src/mn-client-session.c:294
#, c-format
msgid "unable to resolve %s: %s"
msgstr "impossible de résoudre %s: %s"
-#: src/mn-client-session.c:333
+#: src/mn-client-session.c:331
#, c-format
msgid "%s: unsupported address family"
msgstr "%s: famille d'adresse non prise en charge"
-#: src/mn-client-session.c:340
+#: src/mn-client-session.c:338
#, c-format
msgid "%s: unable to create socket: %s"
msgstr "%s: impossible de créer un soquet: %s"
-#: src/mn-client-session.c:344
+#: src/mn-client-session.c:342
#, c-format
msgid "connecting to %s (%s) port %i"
msgstr "connection à %s (%s) port %i en cours"
-#: src/mn-client-session.c:347
+#: src/mn-client-session.c:345
#, c-format
msgid "unable to connect: %s"
msgstr "impossible de se connecter: %s"
-#: src/mn-client-session.c:352
+#: src/mn-client-session.c:350
msgid "connected successfully"
msgstr "connecté avec succès"
#. if reached, we couldn't find a working address
-#: src/mn-client-session.c:358
+#: src/mn-client-session.c:356
#, c-format
msgid "unable to connect to %s"
msgstr "impossible de se connecter à %s"
-#: src/mn-client-session.c:374
+#: src/mn-client-session.c:372
#, c-format
msgid "unable to initialize the OpenSSL library: %s"
msgstr "impossible d'initialiser la bibliothèque OpenSSL: %s"
-#: src/mn-client-session.c:382
+#: src/mn-client-session.c:380
+#, c-format
+msgid "unable to create a SSL/TLS object: %s"
+msgstr "impossible de créer un objet SSL/TLS: %s"
+
+#: src/mn-client-session.c:386
+#, c-format
+msgid "unable to set the SSL/TLS file descriptor: %s"
+msgstr "impossible de spécifier le descripteur de fichier SSL/TLS: %s"
+
+#: src/mn-client-session.c:392
#, c-format
-msgid "unable to create a SSL object: %s"
-msgstr "impossible de créer un objet SSL: %s"
+msgid "unable to perform the SSL/TLS handshake: %s"
+msgstr "impossible d'accomplir la négotiation SSL/TLS: %s"
+
+#: src/mn-client-session.c:398
+msgid "untrusted server"
+msgstr "serveur non fiable"
-#: src/mn-client-session.c:388
+#: src/mn-client-session.c:402
#, c-format
-msgid "unable to set the SSL file descriptor: %s"
-msgstr "impossible de spécifier le descripteur de fichier SSL: %s"
+msgid "a SSL/TLS layer is now active (%s, %s %i-bit)"
+msgstr "une couche SSL/TLS est maintenant active (%s, %s %i-bit)"
+
+#: src/mn-client-session.c:449
+#, c-format
+msgid "%s, fingerprint: %s"
+msgstr "%s, empreinte digitale: %s"
+
+#: src/mn-client-session.c:478
+msgid "missing certificate"
+msgstr "certificat manquant"
+
+#: src/mn-client-session.c:504
+#, c-format
+msgid ""
+"Mail Notification was unable to trust \"%s\" (%s). It is possible that "
+"someone is intercepting your communication to obtain your confidential "
+"information.\n"
+"\n"
+"You should only connect to the server if you are certain you are connected "
+"to \"%s\". If you choose to connect to the server, this message will not be "
+"shown again."
+msgstr ""
+"La Notification de Courrier n'a pas été en mesure de faire confiance à \"%s"
+"\" (%s). Il est possible que quelqu'un soit en train d'intercepter votre "
+"communication afin d'obtenir vos informations confidentielles.\n"
+"\n"
+"Vous devriez vous connecter au serveur uniquement si vous êtes certain que "
+"vous êtes connecté à \"%s\". Si vous choisissez de vous connecter au "
+"serveur, ce message ne sera plus affiché."
+
+#: src/mn-client-session.c:521
+msgid "Connect to untrusted server?"
+msgstr "Se connecter au serveur non fiable?"
+
+#: src/mn-client-session.c:526
+msgid "Co_nnect"
+msgstr "Se co_nnecter"
-#: src/mn-client-session.c:443
+#: src/mn-client-session.c:584
#, c-format
msgid "response \"%s\" is not valid in current context"
msgstr "la réponse \"%s\" n'est pas valable dans le contexte actuel"
-#: src/mn-client-session.c:469
+#: src/mn-client-session.c:610
#, c-format
msgid "unable to parse response \"%s\""
msgstr "impossible d'interpréter la réponse \"%s\""
-#: src/mn-client-session.c:516
+#: src/mn-client-session.c:657
#, c-format
msgid "unable to encode data using SASL: %s"
msgstr "impossible d'encoder les données en utilisant SASL: %s"
-#: src/mn-client-session.c:545 src/mn-client-session.c:552
+#: src/mn-client-session.c:688 src/mn-client-session.c:695
#, c-format
msgid "unable to write to server: %s"
msgstr "impossible d'écrire vers le serveur: %s"
-#: src/mn-client-session.c:550
+#: src/mn-client-session.c:693
msgid "unable to write to server: EOF"
msgstr "impossible d'écrire vers le serveur: EOF"
-#: src/mn-client-session.c:582
+#: src/mn-client-session.c:725
#, c-format
msgid "unable to encode Base64: %s"
msgstr "impossible d'encoder en Base64: %s"
-#: src/mn-client-session.c:685
+#: src/mn-client-session.c:828
#, c-format
msgid "unable to initialize the SASL library: %s"
msgstr "impossible d'initialiser la bibliothèque SASL: %s"
-#: src/mn-client-session.c:694
+#: src/mn-client-session.c:837
#, c-format
msgid "unable to retrieve local address of socket: %s"
msgstr "impossible d'obtenir l'adresse locale du soquet: %s"
-#: src/mn-client-session.c:700
+#: src/mn-client-session.c:843
#, c-format
msgid "unable to retrieve remote address of socket: %s"
msgstr "impossible d'obtenir l'adresse distante du soquet: %s"
-#: src/mn-client-session.c:734
+#: src/mn-client-session.c:877
#, c-format
msgid "warning: unable to set SASL security properties: %s"
msgstr ""
"avertissement: impossible de spécifier les propriétés de sécurité SASL: %s"
-#: src/mn-client-session.c:773
+#: src/mn-client-session.c:916
msgid ""
"unable to start SASL authentication: SASL asked for something we did not know"
msgstr ""
"impossible de démarrer l'authentification SASL: SASL a demandé quelque chose "
"que nous ne connaissions pas"
-#: src/mn-client-session.c:777
+#: src/mn-client-session.c:920
#, c-format
msgid "unable to start SASL authentication: %s"
msgstr "impossible de démarrer l'authentification SASL: %s"
-#: src/mn-client-session.c:781
+#: src/mn-client-session.c:924
#, c-format
msgid "unable to create a SASL connection: %s"
msgstr "impossible de créer une connection SASL: %s"
-#: src/mn-client-session.c:831
+#: src/mn-client-session.c:974
msgid "SASL asked for something we did not know, aborting SASL authentication"
msgstr ""
"SASL a demandé quelque chose que nous ne connaissions pas, annulation de "
"l'authentification SASL"
-#: src/mn-client-session.c:835
+#: src/mn-client-session.c:978
#, c-format
msgid "%s, aborting SASL authentication"
msgstr "%s, annulation de l'authentification SASL"
#. compliance error
-#: src/mn-client-session.c:840
+#: src/mn-client-session.c:983
#, c-format
msgid "unable to decode Base64 input from server: %s"
msgstr "impossible de décoder l'entrée Base64 du serveur: %s"
-#: src/mn-client-session.c:843
+#: src/mn-client-session.c:986
msgid ""
"the server sent a SASL challenge, but there was a pending initial SASL "
"client response"
@@ -329,7 +410,7 @@ msgstr ""
"le serveur a envoyé un défi SASL, mais il y avait une réponse client SASL "
"initiale en attente"
-#: src/mn-client-session.c:857
+#: src/mn-client-session.c:1000
msgid ""
"the server did not send a SASL challenge, but there was no pending initial "
"SASL client response"
@@ -337,63 +418,68 @@ msgstr ""
"le serveur n'a pas envoyé de défi SASL, mais il n'y avait pas de réponse "
"client SASL initiale en attente"
-#: src/mn-client-session.c:880
+#: src/mn-client-session.c:1023
#, c-format
msgid "a SASL security layer of strength factor %i is now active"
msgstr ""
"une couche de sécurité SASL de facteur de force %i est maintenant active"
#. a security layer is active but we can't retrieve maxoutbuf -> fatal
-#: src/mn-client-session.c:885
+#: src/mn-client-session.c:1028
#, c-format
msgid "unable to get SASL_MAXOUTBUF property: %s"
msgstr "impossible d'obtenir la propriété SASL_MAXOUTBUF: %s"
-#: src/mn-client-session.c:891
+#: src/mn-client-session.c:1034
#, c-format
msgid "warning: unable to get SASL_SSF property: %s"
msgstr "avertissement: impossible d'obtenir la propriété SASL_SSF: %s"
-#: src/mn-dialog.c:108
-msgid "A fatal error has occurred in Mail Notification"
-msgstr "Une erreur fatale s'est produite dans la Notification de Courrier"
+#: src/mn-conf.c:109
+#, c-format
+msgid "recursively unsetting %s"
+msgstr "en train de supprimer récursivement %s"
-#: src/mn-gmail-mailbox-properties.gob:78
+#: src/mn-conf.c:113
+msgid "syncing the GConf database"
+msgstr "en train de synchroniser la base de données GConf"
+
+#: src/mn-conf.c:116
+msgid "completed"
+msgstr "terminé"
+
+#: src/mn-gmail-mailbox-properties.gob:77
msgid "Your Gmail username"
msgstr "Votre nom d'utilisateur Gmail"
-#: src/mn-gmail-mailbox-properties.gob:79
+#: src/mn-gmail-mailbox-properties.gob:78
msgid "Your Gmail password"
msgstr "Votre mot de passe Gmail"
-#: src/mn-gmail-mailbox.gob:65
-msgid "unable to parse Gmail URI"
-msgstr "impossible d'interpréter l'URI Gmail"
-
-#: src/mn-gmail-mailbox.gob:182
+#: src/mn-gmail-mailbox.gob:220
msgid "logging in"
msgstr "ouverture de session en cours"
-#: src/mn-gmail-mailbox.gob:201 src/mn-gmail-mailbox.gob:240
-#: src/mn-gmail-mailbox.gob:273 src/mn-gmail-mailbox.gob:377
+#: src/mn-gmail-mailbox.gob:239 src/mn-gmail-mailbox.gob:279
+#: src/mn-gmail-mailbox.gob:313 src/mn-gmail-mailbox.gob:418
#, c-format
msgid "unable to transfer data: %s"
msgstr "impossible de transférer des données: %s"
-#: src/mn-gmail-mailbox.gob:226 src/mn-gmail-mailbox.gob:259
-#: src/mn-gmail-mailbox.gob:293
+#: src/mn-gmail-mailbox.gob:265 src/mn-gmail-mailbox.gob:299
+#: src/mn-gmail-mailbox.gob:334
msgid "login failed"
msgstr "l'ouverture de session a échoué"
-#: src/mn-gmail-mailbox.gob:287
+#: src/mn-gmail-mailbox.gob:328
msgid "successfully logged in"
msgstr "ouverture de session effectuée avec succès"
-#: src/mn-gmail-mailbox.gob:365
+#: src/mn-gmail-mailbox.gob:406
msgid "searching for unread mail"
msgstr "recherche du courrier non lu"
-#: src/mn-gmail-mailbox.gob:384
+#: src/mn-gmail-mailbox.gob:427
msgid "unable to parse Gmail data"
msgstr "impossible d'interpréter les données Gmail"
@@ -409,76 +495,76 @@ msgstr "_boîte de réception"
msgid "oth_er:"
msgstr "autr_e:"
-#: src/mn-imap-mailbox-properties.gob:121
+#: src/mn-imap-mailbox-properties.gob:122
msgid "The hostname or IP address of the IMAP server"
msgstr "Le nom d'hôte ou adresse IP du serveur IMAP"
-#: src/mn-imap-mailbox-properties.gob:122
+#: src/mn-imap-mailbox-properties.gob:123
msgid "Your username on the IMAP server"
msgstr "Votre nom d'utilisateur sur le serveur IMAP"
-#: src/mn-imap-mailbox-properties.gob:123
+#: src/mn-imap-mailbox-properties.gob:124
msgid "Your password on the IMAP server"
msgstr "Votre mot de passe sur le serveur IMAP"
-#: src/mn-imap-mailbox-properties.gob:124
#: src/mn-imap-mailbox-properties.gob:125
+#: src/mn-imap-mailbox-properties.gob:126
msgid "The port number of the IMAP server"
msgstr "Le numéro de port du serveur IMAP"
-#: src/mn-imap-mailbox-properties.gob:126
+#: src/mn-imap-mailbox-properties.gob:127
msgid "The mailbox name"
msgstr "Le nom de la boîte aux lettres"
-#: src/mn-imap-mailbox.gob:124 src/mn-pop3-mailbox.gob:133
-msgid "SSL support has not been compiled in"
-msgstr "le support SSL n'a pas été inclus lors de la compilation"
-
-#: src/mn-imap-mailbox.gob:128
-msgid "unable to parse IMAP URI"
-msgstr "impossible d'interpréter l'URI IMAP"
+#: src/mn-imap-mailbox.gob:112 src/mn-pop3-mailbox.gob:125
+msgid "SSL/TLS support has not been compiled in"
+msgstr "le support SSL/TLS n'a pas été inclus lors de la compilation"
-#: src/mn-imap-mailbox.gob:195
+#: src/mn-imap-mailbox.gob:179
msgid "server did not send capabilities"
msgstr "le serveur n'a pas envoyé ses possibilités"
-#: src/mn-imap-mailbox.gob:267
+#: src/mn-imap-mailbox.gob:292
msgid "server advertised LOGINDISABLED, not using LOGIN authentication"
msgstr ""
"le serveur a annoncé LOGINDISABLED, pas d'utilisation de l'authentification "
"LOGIN"
-#: src/mn-imap-mailbox.gob:268
+#: src/mn-imap-mailbox.gob:293
msgid "unable to login"
msgstr "impossible d'ouvrir la session"
#. compliance error
-#: src/mn-imap-mailbox.gob:336
+#: src/mn-imap-mailbox.gob:361
msgid "server did not send status"
msgstr "le serveur n'a pas envoyé de status"
-#: src/mn-imap-mailbox.gob:554 src/mn-pop3-mailbox.gob:715
+#: src/mn-imap-mailbox.gob:583 src/mn-pop3-mailbox.gob:744
msgid "unknown server error"
msgstr "erreur serveur inconnue"
-#: src/mn-imap-mailbox.gob:625 src/mn-pop3-mailbox.gob:645
+#: src/mn-imap-mailbox.gob:656 src/mn-pop3-mailbox.gob:210
+msgid "server does not support in-band SSL/TLS"
+msgstr "le serveur ne supporte pas le mode SSL/TLS interne"
+
+#: src/mn-imap-mailbox.gob:675 src/mn-pop3-mailbox.gob:674
msgid ""
"a SASL authentication mechanism was selected but SASL support has not been "
"compiled in"
msgstr ""
-"un méchanisme d'authentification SASL a été sélectionné mais le support SASL "
+"un mécanisme d'authentification SASL a été sélectionné mais le support SASL "
"n'a pas été inclus lors de la compilation"
-#: src/mn-imap-mailbox.gob:633 src/mn-pop3-mailbox.gob:657
+#: src/mn-imap-mailbox.gob:683 src/mn-pop3-mailbox.gob:686
#, c-format
msgid "unknown authentication mechanism \"%s\""
-msgstr "méchanisme d'authentification inconnu \"%s\""
+msgstr "mécanisme d'authentification inconnu \"%s\""
-#: src/mn-imap-mailbox.gob:651
+#: src/mn-imap-mailbox.gob:701
msgid "falling back to IMAP LOGIN authentication"
msgstr "rétrogradation vers l'authentification IMAP LOGIN"
-#: src/mn-imap-mailbox.gob:655 src/mn-pop3-mailbox.gob:691
+#: src/mn-imap-mailbox.gob:705 src/mn-pop3-mailbox.gob:720
msgid "authentication failed"
msgstr "l'authentification a échoué"
@@ -508,25 +594,25 @@ msgstr "Ajouter une Boîte aux Lettres"
msgid "%s Properties"
msgstr "Propriétés de %s"
-#: src/mn-mailbox-properties-util.c:75
+#: src/mn-mailbox-properties-util.c:77
msgid "_Username:"
msgstr "_Nom d'utilisateur:"
-#: src/mn-mailbox-properties-util.c:79
+#: src/mn-mailbox-properties-util.c:87
msgid "_Password:"
msgstr "_Mot de passe:"
-#: src/mn-mailbox-properties-util.c:146
+#: src/mn-mailbox-properties-util.c:154
msgid "Connection type:"
msgstr "Type de connection:"
-#: src/mn-mailbox-properties-util.c:153
+#: src/mn-mailbox-properties-util.c:161
msgid "Port:"
msgstr "Port:"
-#: src/mn-mailbox-properties-util.c:180
+#: src/mn-mailbox-properties-util.c:189
msgid "_Authentication mechanism:"
-msgstr "Méchanisme d'_authentification:"
+msgstr "Mécanisme d'_authentification:"
#: src/mn-mailbox-properties.c:63
msgid "Label"
@@ -552,56 +638,56 @@ msgstr "Complet"
msgid "Whether the properties are completely filled or not"
msgstr "Si les propriétés sont complètement remplies ou pas"
-#: src/mn-mailbox-view.gob:91
-msgid "Unable to add mailbox"
-msgstr "Impossible d'ajouter la boîte aux lettres"
-
-#: src/mn-mailbox-view.gob:91
-msgid "The mailbox is already in the list."
-msgstr "La boîte aux lettres est déjà dans la liste."
-
-#: src/mn-mailbox-view.gob:283
+#: src/mn-mailbox-view.gob:254
msgid "Mailbox"
msgstr "Boîte aux lettres"
-#: src/mn-mailbox-view.gob:297
+#: src/mn-mailbox-view.gob:268
msgid "Format"
msgstr "Format"
-#: src/mn-mailbox.gob:88
+#: src/mn-mailbox-view.gob:543
+msgid "Unable to add mailbox"
+msgstr "Impossible d'ajouter la boîte aux lettres"
+
+#: src/mn-mailbox-view.gob:543
+msgid "The mailbox is already in the list."
+msgstr "La boîte aux lettres est déjà dans la liste."
+
+#: src/mn-mailbox.gob:122
msgid "The mailbox URI"
msgstr "L'URI de la boîte aux lettres"
-#: src/mn-mailbox.gob:98
+#: src/mn-mailbox.gob:133
msgid "The mailbox human-readable name"
msgstr "Le nom, lisible par un humain, de la boîte aux lettres"
-#: src/mn-mailbox.gob:102
+#: src/mn-mailbox.gob:137
msgid "Whether the mailbox has to be manually checked or not"
msgstr "Si la boîte aux lettres doit être vérifiée manuellement ou pas"
-#: src/mn-mailbox.gob:107
+#: src/mn-mailbox.gob:142
msgid "Whether the mailbox has new mail or not"
msgstr "Si la boîte aux lettres a du nouveau courrier ou pas"
-#: src/mn-mailbox.gob:112
+#: src/mn-mailbox.gob:147
msgid "The mailbox error, if any"
msgstr "L'erreur de la boîte aux lettres si il y en a une"
-#: src/mn-mailbox.gob:218
+#: src/mn-mailbox.gob:251
msgid "does not exist"
msgstr "n'existe pas"
-#: src/mn-mailbox.gob:255
+#: src/mn-mailbox.gob:287
msgid "unknown format"
msgstr "format inconnu"
-#: src/mn-mailbox.gob:316
+#: src/mn-mailbox.gob:355
#, c-format
msgid "unable to monitor %s: %s"
msgstr "impossible de surveiller %s: %s"
-#: src/mn-mailbox.gob:330
+#: src/mn-mailbox.gob:369
#, c-format
msgid ""
"As a fallback, they will be checked every %i second (this delay is "
@@ -616,7 +702,7 @@ msgstr[1] ""
"Comme solution de secours, elles seront vérifiées toutes les %i secondes (ce "
"délai est configurable depuis les Propriétés)."
-#: src/mn-mailbox.gob:341
+#: src/mn-mailbox.gob:380
#, c-format
msgid ""
"As a fallback, they will be checked every %i minute (this delay is "
@@ -631,7 +717,7 @@ msgstr[1] ""
"Comme solution de secours, elles seront vérifiées toutes les %i minutes (ce "
"délai est configurable depuis les Propriétés)."
-#: src/mn-mailbox.gob:352
+#: src/mn-mailbox.gob:391
#, c-format
msgid ""
"As a fallback, they will be checked approximately every %i minute (this "
@@ -646,60 +732,60 @@ msgstr[1] ""
"Comme solution de secours, elles seront vérifiées approximativement toutes "
"les %i minutes (ce délai est configurable depuis les Propriétés)."
-#: src/mn-mailbox.gob:366
+#: src/mn-mailbox.gob:405
msgid "A monitoring error has occurred"
msgstr "Une erreur de surveillance s'est produite"
-#: src/mn-mailbox.gob:367
+#: src/mn-mailbox.gob:406
#, c-format
msgid ""
-"Mail Notification was unable to enable automatic notification for one or "
+"Mail Notification was unable to enable immediate notification for one or "
"more mailboxes. %s"
msgstr ""
-"Notification de Courrier n'a pas été en mesure d'activer la notification "
-"automatique pour une ou plusieures boîtes aux lettres. %s"
+"La Notification de Courrier n'a pas été en mesure d'activer la notification "
+"immédiate pour une ou plusieures boîtes aux lettres. %s"
-#: src/mn-mailboxes.gob:130
+#: src/mn-mailboxes.gob:143
#, c-format
msgid "%s is unsupported: %s"
msgstr "%s n'est pas pris en charge: %s"
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has new mail"
msgstr "%s a du nouveau courrier"
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has no new mail"
msgstr "%s n'a pas de nouveau courrier"
-#: src/mn-mailboxes.gob:173
+#: src/mn-mailboxes.gob:186
#, c-format
msgid "%s reported an error: %s"
msgstr "%s a indiqué une erreur: %s"
-#: src/mn-maildir-mailbox.gob:98
+#: src/mn-maildir-mailbox.gob:109
#, c-format
msgid "unable to open folder \"new\": %s"
msgstr "impossible d'ouvrir le dossier \"new\": %s"
-#: src/mn-maildir-mailbox.gob:126
+#: src/mn-maildir-mailbox.gob:137
#, c-format
msgid "unable to close folder \"new\": %s"
msgstr "impossible de fermer le dossier \"new\": %s"
-#: src/mn-maildir-mailbox.gob:129
+#: src/mn-maildir-mailbox.gob:140
#, c-format
msgid "error while reading folder \"new\": %s"
msgstr "erreur lors de la lecture du dossier \"new\": %s"
-#: src/mn-main.c:86
+#: src/mn-main.c:85
#, c-format
msgid "Compiled-in mailbox backends: %s\n"
msgstr "Prises en charge de boîtes aux lettres disponibles: %s\n"
-#: src/mn-main.c:104
+#: src/mn-main.c:103
#, c-format
msgid "Compiled-in features: %s\n"
msgstr "Fonctionnalités disponibles: %s\n"
@@ -728,15 +814,19 @@ msgstr "Mettre à jour le status du courrier"
msgid "Report the mail status"
msgstr "Rapporter le status du courrier"
+#: src/mn-main.c:187
+msgid "Unset obsolete GConf configuration and exit"
+msgstr "Supprimer la configuration GConf obsolète et quitter"
+
#.
#. * We can't use mn_error_dialog() because gtk_init() has not been
#. * called yet.
#.
-#: src/mn-main.c:204
+#: src/mn-main.c:213
msgid "multi-threading is not available"
msgstr "le multi-threading n'est pas disponible"
-#: src/mn-main.c:243
+#: src/mn-main.c:258
msgid ""
"Bonobo could not locate the automation object. Please check your Mail "
"Notification installation."
@@ -744,19 +834,19 @@ msgstr ""
"Bonobo n'a pas pu localiser l'objet automation. Veuillez vérifier votre "
"installation de la Notification de Courrier."
-#: src/mn-main.c:248
+#: src/mn-main.c:263
msgid "Unable to initialize the GnomeVFS library."
msgstr "Impossible d'initialiser la bibliothèque GnomeVFS."
-#: src/mn-main.c:270
+#: src/mn-main.c:285
msgid "updating the mail status"
msgstr "mise à jour du status du courrier"
-#: src/mn-main.c:286
+#: src/mn-main.c:301
msgid "Mail Notification is already running"
msgstr "La Notification de Courrier est déjà en cours d'exécution"
-#: src/mn-main.c:293
+#: src/mn-main.c:308
msgid ""
"Bonobo could not locate the GNOME_MailNotification_Automation.server file. "
"Please check your Mail Notification installation."
@@ -764,7 +854,7 @@ msgstr ""
"Bonobo n'a pas pu localiser le fichier GNOME_MailNotification_Automation."
"server. Veuillez vérifier votre installation de la Notification de Courrier."
-#: src/mn-main.c:297
+#: src/mn-main.c:312
msgid ""
"Bonobo was unable to register the automation server. Please check your Mail "
"Notification installation."
@@ -772,22 +862,22 @@ msgstr ""
"Bonobo n'a pas été en mesure d'inscrire le serveur d'automation. Veuillez "
"vérifier votre installation de la Notification de Courrier."
-#: src/mn-mbox-mailbox.gob:165
+#: src/mn-mbox-mailbox.gob:171
#, c-format
msgid "error while reading mailbox: %s"
msgstr "erreur lors de la lecture de la boîte aux lettres: %s"
-#: src/mn-mbox-mailbox.gob:173
+#: src/mn-mbox-mailbox.gob:179
#, c-format
msgid "unable to open mailbox: %s"
msgstr "impossible d'ouvrir la boîte aux lettres: %s"
-#: src/mn-mh-mailbox.gob:111
+#: src/mn-mh-mailbox.gob:122
#, c-format
msgid "error while reading .mh_sequences: %s"
msgstr "erreur lors de la lecture de .mh_sequences: %s"
-#: src/mn-mh-mailbox.gob:119
+#: src/mn-mh-mailbox.gob:130
#, c-format
msgid "unable to open .mh_sequences: %s"
msgstr "impossible d'ouvrir .mh_sequences: %s"
@@ -796,21 +886,25 @@ msgstr "impossible d'ouvrir .mh_sequences: %s"
msgid "detecting"
msgstr "en cours de détection"
-#: src/mn-pi-mailbox-properties.gob:75
+#: src/mn-pi-mailbox-properties.gob:74
msgid "_Hostname:"
msgstr "Nom d'_hôte:"
-#: src/mn-pi-mailbox-properties.gob:93
+#: src/mn-pi-mailbox-properties.gob:92
msgid "_Details"
msgstr "_Détails"
-#: src/mn-pi-mailbox-properties.gob:105
+#: src/mn-pi-mailbox-properties.gob:104
msgid "sta_ndard"
msgstr "sta_ndard"
-#: src/mn-pi-mailbox-properties.gob:115
-msgid "_SSL"
-msgstr "_SSL"
+#: src/mn-pi-mailbox-properties.gob:114
+msgid "_in-band SSL/TLS"
+msgstr "SSL/TLS _interne"
+
+#: src/mn-pi-mailbox-properties.gob:124
+msgid "SSL/TLS on sepa_rate port"
+msgstr "SSL/TLS sur port sépa_ré"
#: src/mn-pop3-mailbox-properties.gob:84
msgid "The hostname or IP address of the POP3 server"
@@ -828,122 +922,122 @@ msgstr "Votre mot de passe sur le serveur POP3"
msgid "The port number of the POP3 server"
msgstr "Le numéro de port du serveur POP3"
-#: src/mn-pop3-mailbox.gob:137
-msgid "unable to parse POP3 URI"
-msgstr "impossible d'interpréter l'URI POP3"
-
-#: src/mn-pop3-mailbox.gob:267
+#: src/mn-pop3-mailbox.gob:256
msgid "invalid arguments for the LOGIN-DELAY capability"
msgstr "arguments invalides pour la possibilité LOGIN-DELAY"
-#: src/mn-pop3-mailbox.gob:495
+#: src/mn-pop3-mailbox.gob:523
#, c-format
msgid "honouring LOGIN-DELAY, sleeping for %i second"
msgid_plural "honouring LOGIN-DELAY, sleeping for %i seconds"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-pop3-mailbox.gob:653
+#: src/mn-pop3-mailbox.gob:682
msgid "server does not support APOP authentication"
msgstr "le serveur ne supporte pas l'authentification APOP"
-#: src/mn-pop3-mailbox.gob:681
+#: src/mn-pop3-mailbox.gob:710
msgid "falling back to APOP authentication"
msgstr "rétrogradation vers l'authentification APOP"
-#: src/mn-pop3-mailbox.gob:686
+#: src/mn-pop3-mailbox.gob:715
msgid "falling back to USER/PASS authentication"
msgstr "rétrogradation vers l'authentification USER/PASS"
-#: src/mn-properties.c:132
+#: src/mn-properties.c:151
msgid "No mailbox selected."
msgstr "Pas de boîte aux lettres sélectionnée."
-#: src/mn-properties.c:137
+#: src/mn-properties.c:156
#, c-format
msgid "%i mailbox selected."
msgid_plural "%i mailboxes selected."
msgstr[0] "%i boîte aux lettres sélectionnée"
msgstr[1] "%i boîtes aux lettres sélectionnées"
-#: src/mn-shell.gob:191
+#: src/mn-shell.gob:204
msgid "A command error has occurred"
msgstr "Une erreur de commande s'est produite"
-#: src/mn-shell.gob:192
+#: src/mn-shell.gob:205
#, c-format
msgid "Unable to execute double-clicked command: %s."
msgstr ""
"Impossible d'exécuter la commande associée au double-click sur l'icône: %s."
-#: src/mn-shell.gob:297
+#: src/mn-shell.gob:292
msgid "The following mailbox has new mail:\n"
msgid_plural "The following mailboxes have new mail:\n"
msgstr[0] "La boîte aux lettres suivante a du nouveau courrier:\n"
msgstr[1] "Les boîtes aux lettres suivantes ont du nouveau courrier:\n"
-#: src/mn-shell.gob:301
+#: src/mn-shell.gob:296
msgid "You have no new mail."
msgstr "Vous n'avez pas de nouveau courrier."
-#: src/mn-shell.gob:304
+#: src/mn-shell.gob:299
msgid "The following mailbox reported an error:\n"
msgid_plural "The following mailboxes reported an error:\n"
msgstr[0] "La boîte aux lettres suivante a indiqué une erreur:\n"
msgstr[1] "Les boîtes aux lettres suivantes ont indiqué une erreur:\n"
-#: src/mn-shell.gob:309
+#: src/mn-shell.gob:304
msgid "The following mailbox is unsupported:\n"
msgid_plural "The following mailboxes are unsupported:\n"
msgstr[0] "La boîte aux lettres suivante n'est pas prise en charge:\n"
msgstr[1] "Les boîtes aux lettres suivantes ne sont pas prises en charge:\n"
-#: src/mn-shell.gob:325
+#: src/mn-shell.gob:320
msgid "You have new mail."
msgstr "Vous avez du nouveau courrier."
-#: src/mn-shell.gob:338
+#: src/mn-shell.gob:330
msgid "A command error has occurred in Mail Notification"
msgstr "Une erreur de commande s'est produite dans la Notification de Courrier"
-#: src/mn-shell.gob:339
+#: src/mn-shell.gob:331
#, c-format
msgid "Unable to execute new mail command: %s."
msgstr ""
"Impossible d'exécuter la commande associée à l'arrivée de nouveau courrier: %"
"s"
+#: src/mn-ssl.c:79
+msgid "unknown SSL/TLS error"
+msgstr "erreur SSL/TLS inconnue"
+
#: src/mn-stock.c:28
msgid "Select _All"
msgstr "Sélectionner _Tout"
-#: src/mn-sylpheed-mailbox.gob:84
+#: src/mn-sylpheed-mailbox.gob:93
#, c-format
msgid "unable to open folder: %s"
msgstr "impossible d'ouvrir le dossier: %s"
-#: src/mn-sylpheed-mailbox.gob:118
+#: src/mn-sylpheed-mailbox.gob:127
#, c-format
msgid "unable to close folder: %s"
msgstr "impossible de fermer le dossier: %s"
-#: src/mn-sylpheed-mailbox.gob:121
+#: src/mn-sylpheed-mailbox.gob:130
#, c-format
msgid "error while reading folder: %s"
msgstr "erreur lors de la lecture du dossier: %s"
-#: src/mn-system-mailbox-properties.gob:33 src/mn-uri.c:672
+#: src/mn-system-mailbox-properties.gob:32 src/mn-uri.gob:391
msgid "System Mailbox"
msgstr "Boîte aux Lettres Système"
-#: src/mn-system-mailbox-properties.gob:56
+#: src/mn-system-mailbox-properties.gob:55
#, c-format
msgid "Your system mailbox (<span weight=\"bold\">%s</span>) will be used."
msgstr ""
"Votre boîte aux lettres système (<span weight=\"bold\">%s</span>) sera "
"utilisée."
-#: src/mn-system-mailbox-properties.gob:63
+#: src/mn-system-mailbox-properties.gob:62
msgid ""
"The location of your system mailbox could not be detected. Please set the "
"MAIL environment variable."
@@ -959,33 +1053,37 @@ msgstr "La raison pour laquelle la boîte aux lettres n'est pas prise en charge"
msgid "unsupported"
msgstr "non pris en charge"
-#: src/mn-util.c:116
+#: src/mn-util.c:199
#, c-format
msgid "error loading image: %s"
msgstr "erreur de chargement d'image: %s"
-#: src/mn-util.c:154
+#: src/mn-util.c:237
#, c-format
msgid "widget %s not found in interface %s"
msgstr "élément %s non trouvé dans interface %s"
-#: src/mn-util.c:261
+#: src/mn-util.c:355
msgid "received an invalid URI list"
msgstr "une liste d'URI invalide a été reçue"
-#: src/mn-util.c:297
+#: src/mn-util.c:391
msgid "received an invalid Mozilla URL"
msgstr "une URL Mozilla invalide a été reçue"
-#: src/mn-util.c:389
+#: src/mn-util.c:484
msgid "Unable to display help"
msgstr "Impossible d'afficher l'aide"
-#: src/mn-util.c:403
+#: src/mn-util.c:498
#, c-format
msgid "Unable to create a thread: %s."
msgstr "Impossible de créer un thread: %s."
+#: src/mn-util.c:701
+msgid "A fatal error has occurred in Mail Notification"
+msgstr "Une erreur fatale s'est produite dans la Notification de Courrier"
+
#: ui/mailbox-properties.glade.h:1
msgid "_Mailbox type:"
msgstr "_Type de boîte aux lettres:"
@@ -1035,24 +1133,45 @@ msgid "When double-click_ed:"
msgstr "Lorsque l'îcone est double-cliqué_e:"
#: ui/properties.glade.h:12
+msgid "Whether the status icon should blink on errors or not"
+msgstr "Si l'icône de status doit clignoter lors d'erreurs ou pas"
+
+#: ui/properties.glade.h:13
msgid "Whether to run a command when new mail arrives or not"
msgstr ""
"Si une commande doit être exécutée lorsque du nouveau courrier arrive ou pas"
-#: ui/properties.glade.h:13
+#: ui/properties.glade.h:14
msgid "Whether to run a command when the icon is double-clicked or not"
msgstr ""
"Si une commande doit être exécutée lorsque l'îcone est double-cliquée ou pas"
-#: ui/properties.glade.h:14
+#: ui/properties.glade.h:15
+msgid ""
+"Whether to start Mail Notification when you log into your GNOME session or "
+"not"
+msgstr ""
+"Si la Notification de Courrier doit être démarrée lorsque vous ouvrez votre "
+"session GNOME ou pas"
+
+#: ui/properties.glade.h:16
+msgid "_Blink on errors"
+msgstr "_Clignoter lors d'erreurs"
+
+#: ui/properties.glade.h:17
msgid "_Delay between mail checks:"
msgstr "_Délai entre les vérifications de courrier:"
-#: ui/properties.glade.h:15
+#: ui/properties.glade.h:18
+msgid "_Start Mail Notification on GNOME login"
+msgstr ""
+"_Démarrer la Notification de Courrier lors de l'ouverture de session GNOME"
+
+#: ui/properties.glade.h:19
msgid "minutes"
msgstr "minutes"
-#: ui/properties.glade.h:16
+#: ui/properties.glade.h:20
msgid "seconds"
msgstr "secondes"
@@ -1068,7 +1187,8 @@ msgid ""
"Note: this message will not be shown anymore. To configure Mail Notification "
"again, choose <span weight=\"bold\">Applications</span> → <span weight=\"bold"
"\">Desktop Preferences</span> → <span weight=\"bold\">Mail Notification</"
-"span>."
+"span> (or on some systems <span weight=\"bold\">Applications → Preferences → "
+"More Preferences → Mail Notification</span>)."
msgstr ""
"<span weight=\"bold\" size=\"larger\">Premier démarrage</span>\n"
"\n"
@@ -1080,7 +1200,10 @@ msgstr ""
"Note: ce message ne sera plus affiché à nouveau. Pour configurer la "
"Notification de Courrier ultérieurement, choisissez <span weight=\"bold"
"\">Applications</span> → <span weight=\"bold\">Préférences du bureau</span> "
-"→ <span weight=\"bold\">Notification de Courrier</span>."
+"→ <span weight=\"bold\">Notification de Courrier</span> (ou pour certains "
+"systèmes <span weight=\"bold\">Applications</span> → <span weight=\"bold"
+"\">Préférences</span> → <span weight=\"bold\">Plus de préférences</span> → "
+"<span weight=\"bold\">Notification de Courrier</span>)."
#: ui/welcome.glade.h:8
msgid "_Configure Mail Notification"
diff --git a/po/mail-notification.pot b/po/mail-notification.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2004-08-19 00:12+0200\n"
+"POT-Creation-Date: 2004-09-09 01:43+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -32,7 +32,7 @@ msgstr ""
#: data/mail-notification-properties.desktop.in.h:2
#: data/mail-notification.desktop.in.h:2
#: data/mail-notification.soundlist.in.h:1 src/mn-about-dialog.gob:38
-#: src/mn-mail-icon.gob:160 src/mn-main.c:212
+#: src/mn-mail-icon.gob:160 src/mn-main.c:221
msgid "Mail Notification"
msgstr ""
@@ -41,82 +41,109 @@ msgid "Get notified when new mail arrives"
msgstr ""
#: data/mail-notification.schemas.in.h:1
-msgid "Delay between mail checks (minutes part)."
+msgid "Blink on errors"
msgstr ""
#: data/mail-notification.schemas.in.h:2
-msgid "Delay between mail checks (seconds part)."
+msgid "Delay between mail checks (minutes part)."
msgstr ""
#: data/mail-notification.schemas.in.h:3
-msgid "Double-clicked command"
+msgid "Delay between mail checks (seconds part)."
msgstr ""
#: data/mail-notification.schemas.in.h:4
-msgid "Has already been run"
+msgid "Double-clicked command"
msgstr ""
#: data/mail-notification.schemas.in.h:5
-msgid "Height of properties dialog"
+msgid "Fingerprints of trusted X509 certificates"
msgstr ""
#: data/mail-notification.schemas.in.h:6
-msgid "Mailboxes list"
+msgid "Has already been run"
msgstr ""
#: data/mail-notification.schemas.in.h:7
-msgid "Minutes between mail checks"
+msgid "Height of properties dialog"
msgstr ""
#: data/mail-notification.schemas.in.h:8
-msgid "New mail command"
+msgid "Mailboxes list"
msgstr ""
#: data/mail-notification.schemas.in.h:9
-msgid "Run a command when new mail arrives"
+msgid "Minutes between mail checks"
msgstr ""
#: data/mail-notification.schemas.in.h:10
-msgid "Run a command when the icon is double-clicked"
+msgid "New mail command"
msgstr ""
#: data/mail-notification.schemas.in.h:11
-msgid "Seconds between mail checks"
+msgid "Run a command when new mail arrives"
msgstr ""
#: data/mail-notification.schemas.in.h:12
-msgid "The command to run when new mail arrives."
+msgid "Run a command when the icon is double-clicked"
msgstr ""
#: data/mail-notification.schemas.in.h:13
-msgid "The command to run when the icon is double-clicked."
+msgid "Seconds between mail checks"
msgstr ""
#: data/mail-notification.schemas.in.h:14
-msgid "The height of the properties dialog in pixels."
+msgid "The command to run when new mail arrives."
msgstr ""
#: data/mail-notification.schemas.in.h:15
-msgid "The list of mailboxes to monitor."
+msgid "The command to run when the icon is double-clicked."
msgstr ""
#: data/mail-notification.schemas.in.h:16
-msgid "The width of the properties dialog in pixels."
+msgid "The height of the properties dialog in pixels."
msgstr ""
#: data/mail-notification.schemas.in.h:17
-msgid "Whether Mail Notification has already been run or not."
+msgid "The list of mailboxes to monitor."
msgstr ""
#: data/mail-notification.schemas.in.h:18
-msgid "Whether to run a command when new mail arrives or not."
+msgid ""
+"The list of trusted SSL/TLS servers (hostname:port) lacking a X509 "
+"certificate."
msgstr ""
#: data/mail-notification.schemas.in.h:19
-msgid "Whether to run a command when the icon is double-clicked or not."
+msgid ""
+"The list of trusted X509 certificates, represented by their MD5 fingerprint."
msgstr ""
#: data/mail-notification.schemas.in.h:20
+msgid "The width of the properties dialog in pixels."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:21
+msgid "Trusted servers list"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:22
+msgid "Whether Mail Notification has already been run or not."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:23
+msgid "Whether the status icon should blink on errors or not."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:24
+msgid "Whether to run a command when new mail arrives or not."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:25
+msgid "Whether to run a command when the icon is double-clicked or not."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:26
msgid "Width of properties dialog"
msgstr ""
@@ -140,23 +167,23 @@ msgstr ""
msgid "Jean-Yves Lefort <jylefort@brutele.be>"
msgstr ""
-#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:36
+#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:35
msgid "<span style=\"italic\">autodetect</span>"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:67
+#: src/mn-autodetect-mailbox-properties.gob:66
msgid "_Location:"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:73
+#: src/mn-autodetect-mailbox-properties.gob:72
msgid "_Browse..."
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:80
+#: src/mn-autodetect-mailbox-properties.gob:79
msgid "The URI of the mailbox"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:117
+#: src/mn-autodetect-mailbox-properties.gob:116
msgid "Select a File or Folder"
msgstr ""
@@ -164,222 +191,270 @@ msgstr ""
msgid "Whether the image is blinking or not"
msgstr ""
-#: src/mn-client-session.c:195 src/mn-client-session.c:202
+#: src/mn-client-session.c:196 src/mn-client-session.c:203
#, c-format
msgid "unable to read from server: %s"
msgstr ""
-#: src/mn-client-session.c:200
+#: src/mn-client-session.c:201
msgid "unable to read from server: EOF"
msgstr ""
-#: src/mn-client-session.c:212
+#: src/mn-client-session.c:213
#, c-format
msgid "unable to decode data using SASL: %s"
msgstr ""
-#: src/mn-client-session.c:286
+#: src/mn-client-session.c:284
#, c-format
msgid "resolving %s"
msgstr ""
-#: src/mn-client-session.c:296
+#: src/mn-client-session.c:294
#, c-format
msgid "unable to resolve %s: %s"
msgstr ""
-#: src/mn-client-session.c:333
+#: src/mn-client-session.c:331
#, c-format
msgid "%s: unsupported address family"
msgstr ""
-#: src/mn-client-session.c:340
+#: src/mn-client-session.c:338
#, c-format
msgid "%s: unable to create socket: %s"
msgstr ""
-#: src/mn-client-session.c:344
+#: src/mn-client-session.c:342
#, c-format
msgid "connecting to %s (%s) port %i"
msgstr ""
-#: src/mn-client-session.c:347
+#: src/mn-client-session.c:345
#, c-format
msgid "unable to connect: %s"
msgstr ""
-#: src/mn-client-session.c:352
+#: src/mn-client-session.c:350
msgid "connected successfully"
msgstr ""
#. if reached, we couldn't find a working address
-#: src/mn-client-session.c:358
+#: src/mn-client-session.c:356
#, c-format
msgid "unable to connect to %s"
msgstr ""
-#: src/mn-client-session.c:374
+#: src/mn-client-session.c:372
#, c-format
msgid "unable to initialize the OpenSSL library: %s"
msgstr ""
-#: src/mn-client-session.c:382
+#: src/mn-client-session.c:380
#, c-format
-msgid "unable to create a SSL object: %s"
+msgid "unable to create a SSL/TLS object: %s"
+msgstr ""
+
+#: src/mn-client-session.c:386
+#, c-format
+msgid "unable to set the SSL/TLS file descriptor: %s"
+msgstr ""
+
+#: src/mn-client-session.c:392
+#, c-format
+msgid "unable to perform the SSL/TLS handshake: %s"
+msgstr ""
+
+#: src/mn-client-session.c:398
+msgid "untrusted server"
+msgstr ""
+
+#: src/mn-client-session.c:402
+#, c-format
+msgid "a SSL/TLS layer is now active (%s, %s %i-bit)"
+msgstr ""
+
+#: src/mn-client-session.c:449
+#, c-format
+msgid "%s, fingerprint: %s"
+msgstr ""
+
+#: src/mn-client-session.c:478
+msgid "missing certificate"
msgstr ""
-#: src/mn-client-session.c:388
+#: src/mn-client-session.c:504
#, c-format
-msgid "unable to set the SSL file descriptor: %s"
+msgid ""
+"Mail Notification was unable to trust \"%s\" (%s). It is possible that "
+"someone is intercepting your communication to obtain your confidential "
+"information.\n"
+"\n"
+"You should only connect to the server if you are certain you are connected "
+"to \"%s\". If you choose to connect to the server, this message will not be "
+"shown again."
msgstr ""
-#: src/mn-client-session.c:443
+#: src/mn-client-session.c:521
+msgid "Connect to untrusted server?"
+msgstr ""
+
+#: src/mn-client-session.c:526
+msgid "Co_nnect"
+msgstr ""
+
+#: src/mn-client-session.c:584
#, c-format
msgid "response \"%s\" is not valid in current context"
msgstr ""
-#: src/mn-client-session.c:469
+#: src/mn-client-session.c:610
#, c-format
msgid "unable to parse response \"%s\""
msgstr ""
-#: src/mn-client-session.c:516
+#: src/mn-client-session.c:657
#, c-format
msgid "unable to encode data using SASL: %s"
msgstr ""
-#: src/mn-client-session.c:545 src/mn-client-session.c:552
+#: src/mn-client-session.c:688 src/mn-client-session.c:695
#, c-format
msgid "unable to write to server: %s"
msgstr ""
-#: src/mn-client-session.c:550
+#: src/mn-client-session.c:693
msgid "unable to write to server: EOF"
msgstr ""
-#: src/mn-client-session.c:582
+#: src/mn-client-session.c:725
#, c-format
msgid "unable to encode Base64: %s"
msgstr ""
-#: src/mn-client-session.c:685
+#: src/mn-client-session.c:828
#, c-format
msgid "unable to initialize the SASL library: %s"
msgstr ""
-#: src/mn-client-session.c:694
+#: src/mn-client-session.c:837
#, c-format
msgid "unable to retrieve local address of socket: %s"
msgstr ""
-#: src/mn-client-session.c:700
+#: src/mn-client-session.c:843
#, c-format
msgid "unable to retrieve remote address of socket: %s"
msgstr ""
-#: src/mn-client-session.c:734
+#: src/mn-client-session.c:877
#, c-format
msgid "warning: unable to set SASL security properties: %s"
msgstr ""
-#: src/mn-client-session.c:773
+#: src/mn-client-session.c:916
msgid ""
"unable to start SASL authentication: SASL asked for something we did not know"
msgstr ""
-#: src/mn-client-session.c:777
+#: src/mn-client-session.c:920
#, c-format
msgid "unable to start SASL authentication: %s"
msgstr ""
-#: src/mn-client-session.c:781
+#: src/mn-client-session.c:924
#, c-format
msgid "unable to create a SASL connection: %s"
msgstr ""
-#: src/mn-client-session.c:831
+#: src/mn-client-session.c:974
msgid "SASL asked for something we did not know, aborting SASL authentication"
msgstr ""
-#: src/mn-client-session.c:835
+#: src/mn-client-session.c:978
#, c-format
msgid "%s, aborting SASL authentication"
msgstr ""
#. compliance error
-#: src/mn-client-session.c:840
+#: src/mn-client-session.c:983
#, c-format
msgid "unable to decode Base64 input from server: %s"
msgstr ""
-#: src/mn-client-session.c:843
+#: src/mn-client-session.c:986
msgid ""
"the server sent a SASL challenge, but there was a pending initial SASL "
"client response"
msgstr ""
-#: src/mn-client-session.c:857
+#: src/mn-client-session.c:1000
msgid ""
"the server did not send a SASL challenge, but there was no pending initial "
"SASL client response"
msgstr ""
-#: src/mn-client-session.c:880
+#: src/mn-client-session.c:1023
#, c-format
msgid "a SASL security layer of strength factor %i is now active"
msgstr ""
#. a security layer is active but we can't retrieve maxoutbuf -> fatal
-#: src/mn-client-session.c:885
+#: src/mn-client-session.c:1028
#, c-format
msgid "unable to get SASL_MAXOUTBUF property: %s"
msgstr ""
-#: src/mn-client-session.c:891
+#: src/mn-client-session.c:1034
#, c-format
msgid "warning: unable to get SASL_SSF property: %s"
msgstr ""
-#: src/mn-dialog.c:108
-msgid "A fatal error has occurred in Mail Notification"
+#: src/mn-conf.c:109
+#, c-format
+msgid "recursively unsetting %s"
msgstr ""
-#: src/mn-gmail-mailbox-properties.gob:78
-msgid "Your Gmail username"
+#: src/mn-conf.c:113
+msgid "syncing the GConf database"
msgstr ""
-#: src/mn-gmail-mailbox-properties.gob:79
-msgid "Your Gmail password"
+#: src/mn-conf.c:116
+msgid "completed"
msgstr ""
-#: src/mn-gmail-mailbox.gob:65
-msgid "unable to parse Gmail URI"
+#: src/mn-gmail-mailbox-properties.gob:77
+msgid "Your Gmail username"
+msgstr ""
+
+#: src/mn-gmail-mailbox-properties.gob:78
+msgid "Your Gmail password"
msgstr ""
-#: src/mn-gmail-mailbox.gob:182
+#: src/mn-gmail-mailbox.gob:220
msgid "logging in"
msgstr ""
-#: src/mn-gmail-mailbox.gob:201 src/mn-gmail-mailbox.gob:240
-#: src/mn-gmail-mailbox.gob:273 src/mn-gmail-mailbox.gob:377
+#: src/mn-gmail-mailbox.gob:239 src/mn-gmail-mailbox.gob:279
+#: src/mn-gmail-mailbox.gob:313 src/mn-gmail-mailbox.gob:418
#, c-format
msgid "unable to transfer data: %s"
msgstr ""
-#: src/mn-gmail-mailbox.gob:226 src/mn-gmail-mailbox.gob:259
-#: src/mn-gmail-mailbox.gob:293
+#: src/mn-gmail-mailbox.gob:265 src/mn-gmail-mailbox.gob:299
+#: src/mn-gmail-mailbox.gob:334
msgid "login failed"
msgstr ""
-#: src/mn-gmail-mailbox.gob:287
+#: src/mn-gmail-mailbox.gob:328
msgid "successfully logged in"
msgstr ""
-#: src/mn-gmail-mailbox.gob:365
+#: src/mn-gmail-mailbox.gob:406
msgid "searching for unread mail"
msgstr ""
-#: src/mn-gmail-mailbox.gob:384
+#: src/mn-gmail-mailbox.gob:427
msgid "unable to parse Gmail data"
msgstr ""
@@ -395,72 +470,72 @@ msgstr ""
msgid "oth_er:"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:121
+#: src/mn-imap-mailbox-properties.gob:122
msgid "The hostname or IP address of the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:122
+#: src/mn-imap-mailbox-properties.gob:123
msgid "Your username on the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:123
+#: src/mn-imap-mailbox-properties.gob:124
msgid "Your password on the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:124
#: src/mn-imap-mailbox-properties.gob:125
+#: src/mn-imap-mailbox-properties.gob:126
msgid "The port number of the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:126
+#: src/mn-imap-mailbox-properties.gob:127
msgid "The mailbox name"
msgstr ""
-#: src/mn-imap-mailbox.gob:124 src/mn-pop3-mailbox.gob:133
-msgid "SSL support has not been compiled in"
+#: src/mn-imap-mailbox.gob:112 src/mn-pop3-mailbox.gob:125
+msgid "SSL/TLS support has not been compiled in"
msgstr ""
-#: src/mn-imap-mailbox.gob:128
-msgid "unable to parse IMAP URI"
-msgstr ""
-
-#: src/mn-imap-mailbox.gob:195
+#: src/mn-imap-mailbox.gob:179
msgid "server did not send capabilities"
msgstr ""
-#: src/mn-imap-mailbox.gob:267
+#: src/mn-imap-mailbox.gob:292
msgid "server advertised LOGINDISABLED, not using LOGIN authentication"
msgstr ""
-#: src/mn-imap-mailbox.gob:268
+#: src/mn-imap-mailbox.gob:293
msgid "unable to login"
msgstr ""
#. compliance error
-#: src/mn-imap-mailbox.gob:336
+#: src/mn-imap-mailbox.gob:361
msgid "server did not send status"
msgstr ""
-#: src/mn-imap-mailbox.gob:554 src/mn-pop3-mailbox.gob:715
+#: src/mn-imap-mailbox.gob:583 src/mn-pop3-mailbox.gob:744
msgid "unknown server error"
msgstr ""
-#: src/mn-imap-mailbox.gob:625 src/mn-pop3-mailbox.gob:645
+#: src/mn-imap-mailbox.gob:656 src/mn-pop3-mailbox.gob:210
+msgid "server does not support in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-imap-mailbox.gob:675 src/mn-pop3-mailbox.gob:674
msgid ""
"a SASL authentication mechanism was selected but SASL support has not been "
"compiled in"
msgstr ""
-#: src/mn-imap-mailbox.gob:633 src/mn-pop3-mailbox.gob:657
+#: src/mn-imap-mailbox.gob:683 src/mn-pop3-mailbox.gob:686
#, c-format
msgid "unknown authentication mechanism \"%s\""
msgstr ""
-#: src/mn-imap-mailbox.gob:651
+#: src/mn-imap-mailbox.gob:701
msgid "falling back to IMAP LOGIN authentication"
msgstr ""
-#: src/mn-imap-mailbox.gob:655 src/mn-pop3-mailbox.gob:691
+#: src/mn-imap-mailbox.gob:705 src/mn-pop3-mailbox.gob:720
msgid "authentication failed"
msgstr ""
@@ -490,23 +565,23 @@ msgstr ""
msgid "%s Properties"
msgstr ""
-#: src/mn-mailbox-properties-util.c:75
+#: src/mn-mailbox-properties-util.c:77
msgid "_Username:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:79
+#: src/mn-mailbox-properties-util.c:87
msgid "_Password:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:146
+#: src/mn-mailbox-properties-util.c:154
msgid "Connection type:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:153
+#: src/mn-mailbox-properties-util.c:161
msgid "Port:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:180
+#: src/mn-mailbox-properties-util.c:189
msgid "_Authentication mechanism:"
msgstr ""
@@ -534,56 +609,56 @@ msgstr ""
msgid "Whether the properties are completely filled or not"
msgstr ""
-#: src/mn-mailbox-view.gob:91
-msgid "Unable to add mailbox"
+#: src/mn-mailbox-view.gob:254
+msgid "Mailbox"
msgstr ""
-#: src/mn-mailbox-view.gob:91
-msgid "The mailbox is already in the list."
+#: src/mn-mailbox-view.gob:268
+msgid "Format"
msgstr ""
-#: src/mn-mailbox-view.gob:283
-msgid "Mailbox"
+#: src/mn-mailbox-view.gob:543
+msgid "Unable to add mailbox"
msgstr ""
-#: src/mn-mailbox-view.gob:297
-msgid "Format"
+#: src/mn-mailbox-view.gob:543
+msgid "The mailbox is already in the list."
msgstr ""
-#: src/mn-mailbox.gob:88
+#: src/mn-mailbox.gob:122
msgid "The mailbox URI"
msgstr ""
-#: src/mn-mailbox.gob:98
+#: src/mn-mailbox.gob:133
msgid "The mailbox human-readable name"
msgstr ""
-#: src/mn-mailbox.gob:102
+#: src/mn-mailbox.gob:137
msgid "Whether the mailbox has to be manually checked or not"
msgstr ""
-#: src/mn-mailbox.gob:107
+#: src/mn-mailbox.gob:142
msgid "Whether the mailbox has new mail or not"
msgstr ""
-#: src/mn-mailbox.gob:112
+#: src/mn-mailbox.gob:147
msgid "The mailbox error, if any"
msgstr ""
-#: src/mn-mailbox.gob:218
+#: src/mn-mailbox.gob:251
msgid "does not exist"
msgstr ""
-#: src/mn-mailbox.gob:255
+#: src/mn-mailbox.gob:287
msgid "unknown format"
msgstr ""
-#: src/mn-mailbox.gob:316
+#: src/mn-mailbox.gob:355
#, c-format
msgid "unable to monitor %s: %s"
msgstr ""
-#: src/mn-mailbox.gob:330
+#: src/mn-mailbox.gob:369
#, c-format
msgid ""
"As a fallback, they will be checked every %i second (this delay is "
@@ -594,7 +669,7 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:341
+#: src/mn-mailbox.gob:380
#, c-format
msgid ""
"As a fallback, they will be checked every %i minute (this delay is "
@@ -605,7 +680,7 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:352
+#: src/mn-mailbox.gob:391
#, c-format
msgid ""
"As a fallback, they will be checked approximately every %i minute (this "
@@ -616,58 +691,58 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:366
+#: src/mn-mailbox.gob:405
msgid "A monitoring error has occurred"
msgstr ""
-#: src/mn-mailbox.gob:367
+#: src/mn-mailbox.gob:406
#, c-format
msgid ""
-"Mail Notification was unable to enable automatic notification for one or "
+"Mail Notification was unable to enable immediate notification for one or "
"more mailboxes. %s"
msgstr ""
-#: src/mn-mailboxes.gob:130
+#: src/mn-mailboxes.gob:143
#, c-format
msgid "%s is unsupported: %s"
msgstr ""
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has new mail"
msgstr ""
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has no new mail"
msgstr ""
-#: src/mn-mailboxes.gob:173
+#: src/mn-mailboxes.gob:186
#, c-format
msgid "%s reported an error: %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:98
+#: src/mn-maildir-mailbox.gob:109
#, c-format
msgid "unable to open folder \"new\": %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:126
+#: src/mn-maildir-mailbox.gob:137
#, c-format
msgid "unable to close folder \"new\": %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:129
+#: src/mn-maildir-mailbox.gob:140
#, c-format
msgid "error while reading folder \"new\": %s"
msgstr ""
-#: src/mn-main.c:86
+#: src/mn-main.c:85
#, c-format
msgid "Compiled-in mailbox backends: %s\n"
msgstr ""
-#: src/mn-main.c:104
+#: src/mn-main.c:103
#, c-format
msgid "Compiled-in features: %s\n"
msgstr ""
@@ -696,60 +771,64 @@ msgstr ""
msgid "Report the mail status"
msgstr ""
+#: src/mn-main.c:187
+msgid "Unset obsolete GConf configuration and exit"
+msgstr ""
+
#.
#. * We can't use mn_error_dialog() because gtk_init() has not been
#. * called yet.
#.
-#: src/mn-main.c:204
+#: src/mn-main.c:213
msgid "multi-threading is not available"
msgstr ""
-#: src/mn-main.c:243
+#: src/mn-main.c:258
msgid ""
"Bonobo could not locate the automation object. Please check your Mail "
"Notification installation."
msgstr ""
-#: src/mn-main.c:248
+#: src/mn-main.c:263
msgid "Unable to initialize the GnomeVFS library."
msgstr ""
-#: src/mn-main.c:270
+#: src/mn-main.c:285
msgid "updating the mail status"
msgstr ""
-#: src/mn-main.c:286
+#: src/mn-main.c:301
msgid "Mail Notification is already running"
msgstr ""
-#: src/mn-main.c:293
+#: src/mn-main.c:308
msgid ""
"Bonobo could not locate the GNOME_MailNotification_Automation.server file. "
"Please check your Mail Notification installation."
msgstr ""
-#: src/mn-main.c:297
+#: src/mn-main.c:312
msgid ""
"Bonobo was unable to register the automation server. Please check your Mail "
"Notification installation."
msgstr ""
-#: src/mn-mbox-mailbox.gob:165
+#: src/mn-mbox-mailbox.gob:171
#, c-format
msgid "error while reading mailbox: %s"
msgstr ""
-#: src/mn-mbox-mailbox.gob:173
+#: src/mn-mbox-mailbox.gob:179
#, c-format
msgid "unable to open mailbox: %s"
msgstr ""
-#: src/mn-mh-mailbox.gob:111
+#: src/mn-mh-mailbox.gob:122
#, c-format
msgid "error while reading .mh_sequences: %s"
msgstr ""
-#: src/mn-mh-mailbox.gob:119
+#: src/mn-mh-mailbox.gob:130
#, c-format
msgid "unable to open .mh_sequences: %s"
msgstr ""
@@ -758,20 +837,24 @@ msgstr ""
msgid "detecting"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:75
+#: src/mn-pi-mailbox-properties.gob:74
msgid "_Hostname:"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:93
+#: src/mn-pi-mailbox-properties.gob:92
msgid "_Details"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:105
+#: src/mn-pi-mailbox-properties.gob:104
msgid "sta_ndard"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:115
-msgid "_SSL"
+#: src/mn-pi-mailbox-properties.gob:114
+msgid "_in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-pi-mailbox-properties.gob:124
+msgid "SSL/TLS on sepa_rate port"
msgstr ""
#: src/mn-pop3-mailbox-properties.gob:84
@@ -790,117 +873,117 @@ msgstr ""
msgid "The port number of the POP3 server"
msgstr ""
-#: src/mn-pop3-mailbox.gob:137
-msgid "unable to parse POP3 URI"
-msgstr ""
-
-#: src/mn-pop3-mailbox.gob:267
+#: src/mn-pop3-mailbox.gob:256
msgid "invalid arguments for the LOGIN-DELAY capability"
msgstr ""
-#: src/mn-pop3-mailbox.gob:495
+#: src/mn-pop3-mailbox.gob:523
#, c-format
msgid "honouring LOGIN-DELAY, sleeping for %i second"
msgid_plural "honouring LOGIN-DELAY, sleeping for %i seconds"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-pop3-mailbox.gob:653
+#: src/mn-pop3-mailbox.gob:682
msgid "server does not support APOP authentication"
msgstr ""
-#: src/mn-pop3-mailbox.gob:681
+#: src/mn-pop3-mailbox.gob:710
msgid "falling back to APOP authentication"
msgstr ""
-#: src/mn-pop3-mailbox.gob:686
+#: src/mn-pop3-mailbox.gob:715
msgid "falling back to USER/PASS authentication"
msgstr ""
-#: src/mn-properties.c:132
+#: src/mn-properties.c:151
msgid "No mailbox selected."
msgstr ""
-#: src/mn-properties.c:137
+#: src/mn-properties.c:156
#, c-format
msgid "%i mailbox selected."
msgid_plural "%i mailboxes selected."
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:191
+#: src/mn-shell.gob:204
msgid "A command error has occurred"
msgstr ""
-#: src/mn-shell.gob:192
+#: src/mn-shell.gob:205
#, c-format
msgid "Unable to execute double-clicked command: %s."
msgstr ""
-#: src/mn-shell.gob:297
+#: src/mn-shell.gob:292
msgid "The following mailbox has new mail:\n"
msgid_plural "The following mailboxes have new mail:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:301
+#: src/mn-shell.gob:296
msgid "You have no new mail."
msgstr ""
-#: src/mn-shell.gob:304
+#: src/mn-shell.gob:299
msgid "The following mailbox reported an error:\n"
msgid_plural "The following mailboxes reported an error:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:309
+#: src/mn-shell.gob:304
msgid "The following mailbox is unsupported:\n"
msgid_plural "The following mailboxes are unsupported:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:325
+#: src/mn-shell.gob:320
msgid "You have new mail."
msgstr ""
-#: src/mn-shell.gob:338
+#: src/mn-shell.gob:330
msgid "A command error has occurred in Mail Notification"
msgstr ""
-#: src/mn-shell.gob:339
+#: src/mn-shell.gob:331
#, c-format
msgid "Unable to execute new mail command: %s."
msgstr ""
+#: src/mn-ssl.c:79
+msgid "unknown SSL/TLS error"
+msgstr ""
+
#: src/mn-stock.c:28
msgid "Select _All"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:84
+#: src/mn-sylpheed-mailbox.gob:93
#, c-format
msgid "unable to open folder: %s"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:118
+#: src/mn-sylpheed-mailbox.gob:127
#, c-format
msgid "unable to close folder: %s"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:121
+#: src/mn-sylpheed-mailbox.gob:130
#, c-format
msgid "error while reading folder: %s"
msgstr ""
-#: src/mn-system-mailbox-properties.gob:33 src/mn-uri.c:672
+#: src/mn-system-mailbox-properties.gob:32 src/mn-uri.gob:391
msgid "System Mailbox"
msgstr ""
-#: src/mn-system-mailbox-properties.gob:56
+#: src/mn-system-mailbox-properties.gob:55
#, c-format
msgid "Your system mailbox (<span weight=\"bold\">%s</span>) will be used."
msgstr ""
-#: src/mn-system-mailbox-properties.gob:63
+#: src/mn-system-mailbox-properties.gob:62
msgid ""
"The location of your system mailbox could not be detected. Please set the "
"MAIL environment variable."
@@ -914,33 +997,37 @@ msgstr ""
msgid "unsupported"
msgstr ""
-#: src/mn-util.c:116
+#: src/mn-util.c:199
#, c-format
msgid "error loading image: %s"
msgstr ""
-#: src/mn-util.c:154
+#: src/mn-util.c:237
#, c-format
msgid "widget %s not found in interface %s"
msgstr ""
-#: src/mn-util.c:261
+#: src/mn-util.c:355
msgid "received an invalid URI list"
msgstr ""
-#: src/mn-util.c:297
+#: src/mn-util.c:391
msgid "received an invalid Mozilla URL"
msgstr ""
-#: src/mn-util.c:389
+#: src/mn-util.c:484
msgid "Unable to display help"
msgstr ""
-#: src/mn-util.c:403
+#: src/mn-util.c:498
#, c-format
msgid "Unable to create a thread: %s."
msgstr ""
+#: src/mn-util.c:701
+msgid "A fatal error has occurred in Mail Notification"
+msgstr ""
+
#: ui/mailbox-properties.glade.h:1
msgid "_Mailbox type:"
msgstr ""
@@ -990,22 +1077,40 @@ msgid "When double-click_ed:"
msgstr ""
#: ui/properties.glade.h:12
-msgid "Whether to run a command when new mail arrives or not"
+msgid "Whether the status icon should blink on errors or not"
msgstr ""
#: ui/properties.glade.h:13
-msgid "Whether to run a command when the icon is double-clicked or not"
+msgid "Whether to run a command when new mail arrives or not"
msgstr ""
#: ui/properties.glade.h:14
-msgid "_Delay between mail checks:"
+msgid "Whether to run a command when the icon is double-clicked or not"
msgstr ""
#: ui/properties.glade.h:15
-msgid "minutes"
+msgid ""
+"Whether to start Mail Notification when you log into your GNOME session or "
+"not"
msgstr ""
#: ui/properties.glade.h:16
+msgid "_Blink on errors"
+msgstr ""
+
+#: ui/properties.glade.h:17
+msgid "_Delay between mail checks:"
+msgstr ""
+
+#: ui/properties.glade.h:18
+msgid "_Start Mail Notification on GNOME login"
+msgstr ""
+
+#: ui/properties.glade.h:19
+msgid "minutes"
+msgstr ""
+
+#: ui/properties.glade.h:20
msgid "seconds"
msgstr ""
@@ -1021,7 +1126,8 @@ msgid ""
"Note: this message will not be shown anymore. To configure Mail Notification "
"again, choose <span weight=\"bold\">Applications</span> → <span weight=\"bold"
"\">Desktop Preferences</span> → <span weight=\"bold\">Mail Notification</"
-"span>."
+"span> (or on some systems <span weight=\"bold\">Applications → Preferences → "
+"More Preferences → Mail Notification</span>)."
msgstr ""
#: ui/welcome.glade.h:8
diff --git a/po/pt.gmo b/po/pt.gmo
Binary files differ.
diff --git a/po/pt.po b/po/pt.po
@@ -0,0 +1,1204 @@
+# Portuguese translations for mail-notification.
+# Copyright (c) 2003, 2004 Jean-Yves Lefort.
+#
+# This file is distributed under the same license as the
+# mail-notification package.
+#
+# Duarte Henriques <duarte_henriques@myrealbox.com>, 2004.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: mail-notification 0.6.1\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2004-09-09 01:43+0200\n"
+"PO-Revision-Date: 2004-09-07 00:04+0200\n"
+"Last-Translator: Duarte Henriques <duarte_henriques@myrealbox.com>\n"
+"Language-Team: Duarte Henriques <duarte_henriques@myrealbox.com>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=2; plural=n>1;\n"
+
+#: data/GNOME_MailNotification_Automation.server.in.in.h:1
+msgid "Mail Notification automation"
+msgstr "Automação da Notificação de Correio"
+
+#: data/GNOME_MailNotification_Automation.server.in.in.h:2
+msgid "Mail Notification automation factory"
+msgstr "Fábrica de automação de Notificação de Correio"
+
+#: data/mail-notification-properties.desktop.in.h:1
+msgid "Configure Mail Notification"
+msgstr "Configurar Notificação de Correio"
+
+#: data/mail-notification-properties.desktop.in.h:2
+#: data/mail-notification.desktop.in.h:2
+#: data/mail-notification.soundlist.in.h:1 src/mn-about-dialog.gob:38
+#: src/mn-mail-icon.gob:160 src/mn-main.c:221
+msgid "Mail Notification"
+msgstr "Notificação de Correio"
+
+#: data/mail-notification.desktop.in.h:1
+msgid "Get notified when new mail arrives"
+msgstr "Notificar quando chega novo correio"
+
+#: data/mail-notification.schemas.in.h:1
+msgid "Blink on errors"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:2
+msgid "Delay between mail checks (minutes part)."
+msgstr "Intervalo entre verificações de correio (minutos)."
+
+#: data/mail-notification.schemas.in.h:3
+msgid "Delay between mail checks (seconds part)."
+msgstr "Intervalo entre verificações de correio (segundos)."
+
+#: data/mail-notification.schemas.in.h:4
+msgid "Double-clicked command"
+msgstr "Comando de duplo-clique"
+
+#: data/mail-notification.schemas.in.h:5
+msgid "Fingerprints of trusted X509 certificates"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:6
+msgid "Has already been run"
+msgstr "Já foi executado"
+
+#: data/mail-notification.schemas.in.h:7
+msgid "Height of properties dialog"
+msgstr "Altura do diálogo de propriedades"
+
+#: data/mail-notification.schemas.in.h:8
+msgid "Mailboxes list"
+msgstr "Lista de caixas de correio"
+
+#: data/mail-notification.schemas.in.h:9
+msgid "Minutes between mail checks"
+msgstr "Minutos entre verificações de correio"
+
+#: data/mail-notification.schemas.in.h:10
+msgid "New mail command"
+msgstr "Novo comando de correio"
+
+#: data/mail-notification.schemas.in.h:11
+msgid "Run a command when new mail arrives"
+msgstr "Executar um comando quando chega novo correio"
+
+#: data/mail-notification.schemas.in.h:12
+msgid "Run a command when the icon is double-clicked"
+msgstr "Executar um comando quando fizer duplo-clique no ícone"
+
+#: data/mail-notification.schemas.in.h:13
+msgid "Seconds between mail checks"
+msgstr "Segundos entre verificações de correio"
+
+#: data/mail-notification.schemas.in.h:14
+msgid "The command to run when new mail arrives."
+msgstr "O comando a executar quando chega novo correio."
+
+#: data/mail-notification.schemas.in.h:15
+msgid "The command to run when the icon is double-clicked."
+msgstr "O comando a executar quando fizer duplo-clique no ícone."
+
+#: data/mail-notification.schemas.in.h:16
+msgid "The height of the properties dialog in pixels."
+msgstr "A altura em pixeis do diálogo de propriedades."
+
+#: data/mail-notification.schemas.in.h:17
+msgid "The list of mailboxes to monitor."
+msgstr "A lista de caixas de correio a monitorizar."
+
+#: data/mail-notification.schemas.in.h:18
+msgid ""
+"The list of trusted SSL/TLS servers (hostname:port) lacking a X509 "
+"certificate."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:19
+msgid ""
+"The list of trusted X509 certificates, represented by their MD5 fingerprint."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:20
+msgid "The width of the properties dialog in pixels."
+msgstr "A largura em pixeis do diálogo de propriedades."
+
+#: data/mail-notification.schemas.in.h:21
+msgid "Trusted servers list"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:22
+msgid "Whether Mail Notification has already been run or not."
+msgstr "Se a Notificação de Correio já foi executada ou não."
+
+#: data/mail-notification.schemas.in.h:23
+#, fuzzy
+msgid "Whether the status icon should blink on errors or not."
+msgstr "Se a imagem pisca ou não"
+
+#: data/mail-notification.schemas.in.h:24
+msgid "Whether to run a command when new mail arrives or not."
+msgstr "Se um comando deverá ser executado quando chega novo correio."
+
+#: data/mail-notification.schemas.in.h:25
+msgid "Whether to run a command when the icon is double-clicked or not."
+msgstr "Se um comando deverá ser executado quando fizer duplo-clique no ícone."
+
+#: data/mail-notification.schemas.in.h:26
+msgid "Width of properties dialog"
+msgstr "Largura do diálogo de propriedades"
+
+#: data/mail-notification.soundlist.in.h:2
+msgid "New Mail"
+msgstr "Novo Correio"
+
+#: src/eggtrayicon.c:109
+msgid "Orientation"
+msgstr "Orientação"
+
+#: src/eggtrayicon.c:110
+msgid "The orientation of the tray."
+msgstr "A orientação do tabuleiro."
+
+#: src/mn-about-dialog.gob:41
+msgid "A Mail Notification Icon"
+msgstr "Um Ícone de Notificação de Correio"
+
+#: src/mn-about-dialog.gob:44
+msgid "Jean-Yves Lefort <jylefort@brutele.be>"
+msgstr "Duarte Henriques <duarte_henriques@myrealbox.com>"
+
+#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:35
+msgid "<span style=\"italic\">autodetect</span>"
+msgstr "<span style=\"italic\">autodetectar</span>"
+
+#: src/mn-autodetect-mailbox-properties.gob:66
+msgid "_Location:"
+msgstr "_Localização:"
+
+#: src/mn-autodetect-mailbox-properties.gob:72
+msgid "_Browse..."
+msgstr "_Procurar..."
+
+#: src/mn-autodetect-mailbox-properties.gob:79
+msgid "The URI of the mailbox"
+msgstr "O URI da caixa de correio"
+
+#: src/mn-autodetect-mailbox-properties.gob:116
+msgid "Select a File or Folder"
+msgstr "Escolha um Ficheiro ou Pasta"
+
+#: src/mn-blinking-image.gob:30
+msgid "Whether the image is blinking or not"
+msgstr "Se a imagem pisca ou não"
+
+#: src/mn-client-session.c:196 src/mn-client-session.c:203
+#, c-format
+msgid "unable to read from server: %s"
+msgstr "incapaz de ler do servidor: %s"
+
+#: src/mn-client-session.c:201
+msgid "unable to read from server: EOF"
+msgstr "incapaz de ler do servidor: EOF"
+
+#: src/mn-client-session.c:213
+#, c-format
+msgid "unable to decode data using SASL: %s"
+msgstr "incapaz de descodificar dados usando SASL: %s"
+
+#: src/mn-client-session.c:284
+#, c-format
+msgid "resolving %s"
+msgstr "resolvendo %s"
+
+#: src/mn-client-session.c:294
+#, c-format
+msgid "unable to resolve %s: %s"
+msgstr "incapaz de resolver %s: %s"
+
+#: src/mn-client-session.c:331
+#, c-format
+msgid "%s: unsupported address family"
+msgstr "%s: família de endereços não suportada"
+
+#: src/mn-client-session.c:338
+#, c-format
+msgid "%s: unable to create socket: %s"
+msgstr "%s: incapaz de criar socket: %s"
+
+#: src/mn-client-session.c:342
+#, c-format
+msgid "connecting to %s (%s) port %i"
+msgstr "ligando a %s (%s), porto %i"
+
+#: src/mn-client-session.c:345
+#, c-format
+msgid "unable to connect: %s"
+msgstr "incapaz de ligar: %s"
+
+#: src/mn-client-session.c:350
+msgid "connected successfully"
+msgstr "ligado com sucesso"
+
+#. if reached, we couldn't find a working address
+#: src/mn-client-session.c:356
+#, c-format
+msgid "unable to connect to %s"
+msgstr "incapaz de ligar a %s"
+
+#: src/mn-client-session.c:372
+#, c-format
+msgid "unable to initialize the OpenSSL library: %s"
+msgstr "incapaz de inicializar a biblioteca OpenSSL: %s"
+
+#: src/mn-client-session.c:380
+#, fuzzy, c-format
+msgid "unable to create a SSL/TLS object: %s"
+msgstr "incapaz de criar um objecto SSL: %s"
+
+#: src/mn-client-session.c:386
+#, fuzzy, c-format
+msgid "unable to set the SSL/TLS file descriptor: %s"
+msgstr "incapaz de definir o descritor de ficheiro SSL: %s"
+
+#: src/mn-client-session.c:392
+#, fuzzy, c-format
+msgid "unable to perform the SSL/TLS handshake: %s"
+msgstr "incapaz de definir o descritor de ficheiro SSL: %s"
+
+#: src/mn-client-session.c:398
+msgid "untrusted server"
+msgstr ""
+
+#: src/mn-client-session.c:402
+#, c-format
+msgid "a SSL/TLS layer is now active (%s, %s %i-bit)"
+msgstr ""
+
+#: src/mn-client-session.c:449
+#, c-format
+msgid "%s, fingerprint: %s"
+msgstr ""
+
+#: src/mn-client-session.c:478
+msgid "missing certificate"
+msgstr ""
+
+#: src/mn-client-session.c:504
+#, c-format
+msgid ""
+"Mail Notification was unable to trust \"%s\" (%s). It is possible that "
+"someone is intercepting your communication to obtain your confidential "
+"information.\n"
+"\n"
+"You should only connect to the server if you are certain you are connected "
+"to \"%s\". If you choose to connect to the server, this message will not be "
+"shown again."
+msgstr ""
+
+#: src/mn-client-session.c:521
+msgid "Connect to untrusted server?"
+msgstr ""
+
+#: src/mn-client-session.c:526
+msgid "Co_nnect"
+msgstr ""
+
+#: src/mn-client-session.c:584
+#, c-format
+msgid "response \"%s\" is not valid in current context"
+msgstr "a resposta \"%s\" não é válida no contexto actual"
+
+#: src/mn-client-session.c:610
+#, c-format
+msgid "unable to parse response \"%s\""
+msgstr "incapaz de processar resposta \"%s\""
+
+#: src/mn-client-session.c:657
+#, c-format
+msgid "unable to encode data using SASL: %s"
+msgstr "incapaz de encodificar dados usando SASL: %s"
+
+#: src/mn-client-session.c:688 src/mn-client-session.c:695
+#, c-format
+msgid "unable to write to server: %s"
+msgstr "incapaz de escrever para o servidor: %s"
+
+#: src/mn-client-session.c:693
+msgid "unable to write to server: EOF"
+msgstr "incapaz de escrever para o servidor: EOF"
+
+#: src/mn-client-session.c:725
+#, c-format
+msgid "unable to encode Base64: %s"
+msgstr "incapaz de encodificar em Base64: %s"
+
+#: src/mn-client-session.c:828
+#, c-format
+msgid "unable to initialize the SASL library: %s"
+msgstr "incapaz de inicializar a biblioteca SASL: %s"
+
+#: src/mn-client-session.c:837
+#, c-format
+msgid "unable to retrieve local address of socket: %s"
+msgstr "incapaz de obter o endereço local do socket: %s"
+
+#: src/mn-client-session.c:843
+#, c-format
+msgid "unable to retrieve remote address of socket: %s"
+msgstr "incapaz de obter endereço remoto do socket: %s"
+
+#: src/mn-client-session.c:877
+#, c-format
+msgid "warning: unable to set SASL security properties: %s"
+msgstr "aviso: incapaz de definir as propriedades de segurança SASL: %s"
+
+#: src/mn-client-session.c:916
+msgid ""
+"unable to start SASL authentication: SASL asked for something we did not know"
+msgstr ""
+"incapaz de iniciar a autenticação SASL: SASL perguntou algo que não sabíamos"
+
+#: src/mn-client-session.c:920
+#, c-format
+msgid "unable to start SASL authentication: %s"
+msgstr "incapaz de iniciar autenticação SASL: %s"
+
+#: src/mn-client-session.c:924
+#, c-format
+msgid "unable to create a SASL connection: %s"
+msgstr "incapaz de criar uma ligação SASL: %s"
+
+#: src/mn-client-session.c:974
+msgid "SASL asked for something we did not know, aborting SASL authentication"
+msgstr "SASL perguntou algo que não sabíamos, abortando a autenticação SASL"
+
+#: src/mn-client-session.c:978
+#, c-format
+msgid "%s, aborting SASL authentication"
+msgstr "%s, abortando a autenticação SASL"
+
+#. compliance error
+#: src/mn-client-session.c:983
+#, c-format
+msgid "unable to decode Base64 input from server: %s"
+msgstr "incapaz de descodificar o input em Base64 do servidor: %s"
+
+#: src/mn-client-session.c:986
+msgid ""
+"the server sent a SASL challenge, but there was a pending initial SASL "
+"client response"
+msgstr ""
+"o servidor enviou um desafio SASL, mas havia uma resposta SASL inicial "
+"pendente do cliente"
+
+#: src/mn-client-session.c:1000
+msgid ""
+"the server did not send a SASL challenge, but there was no pending initial "
+"SASL client response"
+msgstr ""
+"o servidor não enviou um desafio SASL, mas não havia uma resposta SASL "
+"inicial pendente do cliente"
+
+#: src/mn-client-session.c:1023
+#, c-format
+msgid "a SASL security layer of strength factor %i is now active"
+msgstr "está agora activa uma camada de segurança SASL com factor de força %i"
+
+#. a security layer is active but we can't retrieve maxoutbuf -> fatal
+#: src/mn-client-session.c:1028
+#, c-format
+msgid "unable to get SASL_MAXOUTBUF property: %s"
+msgstr "incapaz de obter a propriedade SASL_MAXOUTBUF: %s"
+
+#: src/mn-client-session.c:1034
+#, c-format
+msgid "warning: unable to get SASL_SSF property: %s"
+msgstr "aviso: incapaz de obter a propriedade SASL_SSF: %s"
+
+#: src/mn-conf.c:109
+#, c-format
+msgid "recursively unsetting %s"
+msgstr ""
+
+#: src/mn-conf.c:113
+msgid "syncing the GConf database"
+msgstr ""
+
+#: src/mn-conf.c:116
+#, fuzzy
+msgid "completed"
+msgstr "Completo"
+
+#: src/mn-gmail-mailbox-properties.gob:77
+msgid "Your Gmail username"
+msgstr "O seu nome de utilizador Gmail"
+
+#: src/mn-gmail-mailbox-properties.gob:78
+msgid "Your Gmail password"
+msgstr "A sua senha Gmail"
+
+#: src/mn-gmail-mailbox.gob:220
+msgid "logging in"
+msgstr "ligando-se"
+
+#: src/mn-gmail-mailbox.gob:239 src/mn-gmail-mailbox.gob:279
+#: src/mn-gmail-mailbox.gob:313 src/mn-gmail-mailbox.gob:418
+#, c-format
+msgid "unable to transfer data: %s"
+msgstr "incapaz de transferir dados: %s"
+
+#: src/mn-gmail-mailbox.gob:265 src/mn-gmail-mailbox.gob:299
+#: src/mn-gmail-mailbox.gob:334
+msgid "login failed"
+msgstr "login falhou"
+
+#: src/mn-gmail-mailbox.gob:328
+msgid "successfully logged in"
+msgstr "ligado com sucesso"
+
+#: src/mn-gmail-mailbox.gob:406
+msgid "searching for unread mail"
+msgstr "a procurar correio não lido"
+
+#: src/mn-gmail-mailbox.gob:427
+msgid "unable to parse Gmail data"
+msgstr "incapaz de processar dados Gmail"
+
+#: src/mn-imap-mailbox-properties.gob:92
+msgid "Mailbox:"
+msgstr "Caixa de Correio:"
+
+#: src/mn-imap-mailbox-properties.gob:96
+msgid "in_box"
+msgstr "caixa de _entrada"
+
+#: src/mn-imap-mailbox-properties.gob:107
+msgid "oth_er:"
+msgstr "_outros"
+
+#: src/mn-imap-mailbox-properties.gob:122
+msgid "The hostname or IP address of the IMAP server"
+msgstr "O hostname ou endereço IP do servidor IMAP"
+
+#: src/mn-imap-mailbox-properties.gob:123
+msgid "Your username on the IMAP server"
+msgstr "O seu nome de utilizador no servidor IMAP"
+
+#: src/mn-imap-mailbox-properties.gob:124
+msgid "Your password on the IMAP server"
+msgstr "A sua senha no servidor IMAP"
+
+#: src/mn-imap-mailbox-properties.gob:125
+#: src/mn-imap-mailbox-properties.gob:126
+msgid "The port number of the IMAP server"
+msgstr "O número do porto do servidor IMAP"
+
+#: src/mn-imap-mailbox-properties.gob:127
+msgid "The mailbox name"
+msgstr "O nome da caixa de correio"
+
+#: src/mn-imap-mailbox.gob:112 src/mn-pop3-mailbox.gob:125
+#, fuzzy
+msgid "SSL/TLS support has not been compiled in"
+msgstr "suporte SSL não foi compilado"
+
+#: src/mn-imap-mailbox.gob:179
+msgid "server did not send capabilities"
+msgstr "servidor não enviou habilidades"
+
+#: src/mn-imap-mailbox.gob:292
+msgid "server advertised LOGINDISABLED, not using LOGIN authentication"
+msgstr "servidor anunciou LOGINDISABLED, não usando a autenticação LOGIN"
+
+#: src/mn-imap-mailbox.gob:293
+msgid "unable to login"
+msgstr "incapaz de ligar"
+
+#. compliance error
+#: src/mn-imap-mailbox.gob:361
+msgid "server did not send status"
+msgstr "servidor não enviou estado"
+
+#: src/mn-imap-mailbox.gob:583 src/mn-pop3-mailbox.gob:744
+msgid "unknown server error"
+msgstr "erro de servidor desconhecido"
+
+#: src/mn-imap-mailbox.gob:656 src/mn-pop3-mailbox.gob:210
+#, fuzzy
+msgid "server does not support in-band SSL/TLS"
+msgstr "servidor não suporta autenticação APOP"
+
+#: src/mn-imap-mailbox.gob:675 src/mn-pop3-mailbox.gob:674
+msgid ""
+"a SASL authentication mechanism was selected but SASL support has not been "
+"compiled in"
+msgstr ""
+"foi escolhido um mecanismo de autenticação SASL, mas o suporte SASL não foi "
+"compilado"
+
+#: src/mn-imap-mailbox.gob:683 src/mn-pop3-mailbox.gob:686
+#, c-format
+msgid "unknown authentication mechanism \"%s\""
+msgstr "mecanismo de autenticação desconhecido \"%s\""
+
+#: src/mn-imap-mailbox.gob:701
+msgid "falling back to IMAP LOGIN authentication"
+msgstr "recorrendo à autenticação IMAP LOGIN"
+
+#: src/mn-imap-mailbox.gob:705 src/mn-pop3-mailbox.gob:720
+msgid "authentication failed"
+msgstr "autenticação falhou"
+
+#: src/mn-mail-icon.gob:81
+msgid "_Update"
+msgstr "_Actualizar"
+
+#: src/mn-mail-icon.gob:87
+msgid "R_emove From Notification Area"
+msgstr "_Remover da área de notificação"
+
+#: src/mn-mail-icon.gob:172
+#, c-format
+msgid "_Run %s"
+msgstr "_Executar %s"
+
+#: src/mn-mail-icon.gob:173
+msgid "_Run Default Action"
+msgstr "_Executar acção por omissão"
+
+#: src/mn-mailbox-properties-dialog.c:109
+msgid "Add a Mailbox"
+msgstr "Acrescentar uma Caixa de Correio"
+
+#: src/mn-mailbox-properties-dialog.c:331
+#, c-format
+msgid "%s Properties"
+msgstr "Propriedades de %s"
+
+#: src/mn-mailbox-properties-util.c:77
+msgid "_Username:"
+msgstr "Nome de _Utilizador:"
+
+#: src/mn-mailbox-properties-util.c:87
+msgid "_Password:"
+msgstr "_Senha:"
+
+#: src/mn-mailbox-properties-util.c:154
+msgid "Connection type:"
+msgstr "Tipo de ligação:"
+
+#: src/mn-mailbox-properties-util.c:161
+msgid "Port:"
+msgstr "Porto:"
+
+#: src/mn-mailbox-properties-util.c:189
+msgid "_Authentication mechanism:"
+msgstr "Mecanismo de _Autenticação:"
+
+#: src/mn-mailbox-properties.c:63
+msgid "Label"
+msgstr "Rótulo"
+
+#: src/mn-mailbox-properties.c:64
+msgid "The marked up text to show in the type combo box"
+msgstr "O texto que aparece na combo box de tipo"
+
+#: src/mn-mailbox-properties.c:69
+msgid "Size group"
+msgstr "Grupo de tamanho"
+
+#: src/mn-mailbox-properties.c:70
+msgid "A GtkSizeGroup for aligning control labels"
+msgstr "Um GtkSizeGroup para alinhar rótulos de controlo"
+
+#: src/mn-mailbox-properties.c:75
+msgid "Complete"
+msgstr "Completo"
+
+#: src/mn-mailbox-properties.c:76
+msgid "Whether the properties are completely filled or not"
+msgstr "Se as propriedades estão completamente preenchidas"
+
+#: src/mn-mailbox-view.gob:254
+msgid "Mailbox"
+msgstr "Caixa de Correio"
+
+#: src/mn-mailbox-view.gob:268
+msgid "Format"
+msgstr "Formato"
+
+#: src/mn-mailbox-view.gob:543
+msgid "Unable to add mailbox"
+msgstr "Incapaz de adicionar caixa de correio"
+
+#: src/mn-mailbox-view.gob:543
+msgid "The mailbox is already in the list."
+msgstr "A caixa de correio já está na lista."
+
+#: src/mn-mailbox.gob:122
+msgid "The mailbox URI"
+msgstr "O URI da caixa de correio"
+
+#: src/mn-mailbox.gob:133
+msgid "The mailbox human-readable name"
+msgstr "O nome legível da caixa de correio"
+
+#: src/mn-mailbox.gob:137
+msgid "Whether the mailbox has to be manually checked or not"
+msgstr "Se a caixa de correio tem de ser manualmente verificada"
+
+#: src/mn-mailbox.gob:142
+msgid "Whether the mailbox has new mail or not"
+msgstr "Se a caixa de correio tem novo correio"
+
+#: src/mn-mailbox.gob:147
+msgid "The mailbox error, if any"
+msgstr "O erro da caixa de correio, se houver"
+
+#: src/mn-mailbox.gob:251
+msgid "does not exist"
+msgstr "não existe"
+
+#: src/mn-mailbox.gob:287
+msgid "unknown format"
+msgstr "formato desconhecido"
+
+#: src/mn-mailbox.gob:355
+#, c-format
+msgid "unable to monitor %s: %s"
+msgstr "incapaz de monitorizar %s: %s"
+
+#: src/mn-mailbox.gob:369
+#, c-format
+msgid ""
+"As a fallback, they will be checked every %i second (this delay is "
+"configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked every %i seconds (this delay is "
+"configurable from the Properties Dialog)."
+msgstr[0] ""
+"Como medida de recurso, serão verificadas a cada %i segundo (este atraso é "
+"configurável no Diálogo de Propriedades)."
+msgstr[1] ""
+"Como medida de recurso, serão verificadas a cada %i segundos (este atraso é "
+"configurável no Diálogo de Propriedades)."
+
+#: src/mn-mailbox.gob:380
+#, c-format
+msgid ""
+"As a fallback, they will be checked every %i minute (this delay is "
+"configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked every %i minutes (this delay is "
+"configurable from the Properties Dialog)."
+msgstr[0] ""
+"Como medida de recurso, serão verificadas a cada %i minuto (este atraso é "
+"configurável no Diálogo de Propriedades)."
+msgstr[1] ""
+"Como medida de recurso, serão verificadas a cada %i minutos (este atraso é "
+"configurável no Diálogo de Propriedades)."
+
+#: src/mn-mailbox.gob:391
+#, c-format
+msgid ""
+"As a fallback, they will be checked approximately every %i minute (this "
+"delay is configurable from the Properties Dialog)."
+msgid_plural ""
+"As a fallback, they will be checked approximately every %i minutes (this "
+"delay is configurable from the Properties Dialog)."
+msgstr[0] ""
+"Como medida de recurso, serão verificadas aproximadamente cada %i minuto "
+"(este atraso é configurável no Diálogo de Propriedades)."
+msgstr[1] ""
+"Como medida de recurso, serão verificadas aproximadamente cada %i minutos "
+"(este atraso é configurável no Diálogo de Propriedades)."
+
+#: src/mn-mailbox.gob:405
+msgid "A monitoring error has occurred"
+msgstr "Ocorreu um erro de monitorização"
+
+#: src/mn-mailbox.gob:406
+#, fuzzy, c-format
+msgid ""
+"Mail Notification was unable to enable immediate notification for one or "
+"more mailboxes. %s"
+msgstr ""
+"A Notificação de Correio foi incapaz de activar notificação automática para "
+"uma ou mais caixas de correio. %s"
+
+#: src/mn-mailboxes.gob:143
+#, c-format
+msgid "%s is unsupported: %s"
+msgstr "%s não é suportado: %s"
+
+#: src/mn-mailboxes.gob:170
+#, c-format
+msgid "%s has new mail"
+msgstr "%s tem correio novo"
+
+#: src/mn-mailboxes.gob:170
+#, c-format
+msgid "%s has no new mail"
+msgstr "%s não tem correio novo"
+
+#: src/mn-mailboxes.gob:186
+#, c-format
+msgid "%s reported an error: %s"
+msgstr "%s relatou um erro: %s"
+
+#: src/mn-maildir-mailbox.gob:109
+#, c-format
+msgid "unable to open folder \"new\": %s"
+msgstr "incapaz de abrir pasta \"new\": %s"
+
+#: src/mn-maildir-mailbox.gob:137
+#, c-format
+msgid "unable to close folder \"new\": %s"
+msgstr "incapaz de fechar pasta \"new\": %s"
+
+#: src/mn-maildir-mailbox.gob:140
+#, c-format
+msgid "error while reading folder \"new\": %s"
+msgstr "erro ao ler pasta \"new\": %s"
+
+#: src/mn-main.c:85
+#, c-format
+msgid "Compiled-in mailbox backends: %s\n"
+msgstr "Backends mailbox compilados: %s\n"
+
+#: src/mn-main.c:103
+#, c-format
+msgid "Compiled-in features: %s\n"
+msgstr "Características compiladas: %s\n"
+
+#: src/mn-main.c:133
+msgid "Enable informational output"
+msgstr "Activar output informacional"
+
+#: src/mn-main.c:142
+msgid "List compiled-in features and exit"
+msgstr "Listar características compiladas e sair"
+
+#: src/mn-main.c:151
+msgid "Display the properties dialog"
+msgstr "Mostrar o diálogo de propriedades"
+
+#: src/mn-main.c:160
+msgid "Display the about dialog"
+msgstr "Mostrar o diálogo Sobre"
+
+#: src/mn-main.c:169
+msgid "Update the mail status"
+msgstr "Actualizar o estado do correio"
+
+#: src/mn-main.c:178
+msgid "Report the mail status"
+msgstr "Relatar o estado do correio"
+
+#: src/mn-main.c:187
+msgid "Unset obsolete GConf configuration and exit"
+msgstr ""
+
+#.
+#. * We can't use mn_error_dialog() because gtk_init() has not been
+#. * called yet.
+#.
+#: src/mn-main.c:213
+msgid "multi-threading is not available"
+msgstr "multi-threading não está disponível"
+
+#: src/mn-main.c:258
+msgid ""
+"Bonobo could not locate the automation object. Please check your Mail "
+"Notification installation."
+msgstr ""
+"Bonobo não conseguiu encontrar o objecto de automação. Por favor verifique a "
+"sua instalação de Notificação de Correio."
+
+#: src/mn-main.c:263
+msgid "Unable to initialize the GnomeVFS library."
+msgstr "Incapaz de inicializar a biblioteca GnomeVFS."
+
+#: src/mn-main.c:285
+msgid "updating the mail status"
+msgstr "actualizando o estado do correio"
+
+#: src/mn-main.c:301
+msgid "Mail Notification is already running"
+msgstr "Notificação de Correio já está a ser executado"
+
+#: src/mn-main.c:308
+msgid ""
+"Bonobo could not locate the GNOME_MailNotification_Automation.server file. "
+"Please check your Mail Notification installation."
+msgstr ""
+"Bonobo não conseguiu encontrar o ficheiro GNOME_MailNotification_Automation."
+"server. Por favor verifique a sua instalação da Notificação de Correio."
+
+#: src/mn-main.c:312
+msgid ""
+"Bonobo was unable to register the automation server. Please check your Mail "
+"Notification installation."
+msgstr ""
+"Bonobo foi incapaz de registar o servidor de automação. Por favor verifique "
+"a sua instalação da Notificação de Correio."
+
+#: src/mn-mbox-mailbox.gob:171
+#, c-format
+msgid "error while reading mailbox: %s"
+msgstr "erro ao ler a caixa de correio: %s"
+
+#: src/mn-mbox-mailbox.gob:179
+#, c-format
+msgid "unable to open mailbox: %s"
+msgstr "erro ao abrir a caixa de correio: %s"
+
+#: src/mn-mh-mailbox.gob:122
+#, c-format
+msgid "error while reading .mh_sequences: %s"
+msgstr "erro ao ler .mh_sequences: %s"
+
+#: src/mn-mh-mailbox.gob:130
+#, c-format
+msgid "unable to open .mh_sequences: %s"
+msgstr "erro ao abrir .mh_sequences: %s"
+
+#: src/mn-pending-mailbox.gob:33
+msgid "detecting"
+msgstr "detectando"
+
+#: src/mn-pi-mailbox-properties.gob:74
+msgid "_Hostname:"
+msgstr "_Hostname:"
+
+#: src/mn-pi-mailbox-properties.gob:92
+msgid "_Details"
+msgstr "_Detalhes"
+
+#: src/mn-pi-mailbox-properties.gob:104
+msgid "sta_ndard"
+msgstr "sta_ndard"
+
+#: src/mn-pi-mailbox-properties.gob:114
+msgid "_in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-pi-mailbox-properties.gob:124
+msgid "SSL/TLS on sepa_rate port"
+msgstr ""
+
+#: src/mn-pop3-mailbox-properties.gob:84
+msgid "The hostname or IP address of the POP3 server"
+msgstr "O hostname ou endereço IP do servidor POP3"
+
+#: src/mn-pop3-mailbox-properties.gob:85
+msgid "Your username on the POP3 server"
+msgstr "O seu nome de utilizador no servidor POP3"
+
+#: src/mn-pop3-mailbox-properties.gob:86
+msgid "Your password on the POP3 server"
+msgstr "A sua senha no servidor POP3"
+
+#: src/mn-pop3-mailbox-properties.gob:87 src/mn-pop3-mailbox-properties.gob:88
+msgid "The port number of the POP3 server"
+msgstr "O número do porto do servidor POP3"
+
+#: src/mn-pop3-mailbox.gob:256
+msgid "invalid arguments for the LOGIN-DELAY capability"
+msgstr "argumentos inválidos para a habilidade LOGIN-DELAY"
+
+#: src/mn-pop3-mailbox.gob:523
+#, c-format
+msgid "honouring LOGIN-DELAY, sleeping for %i second"
+msgid_plural "honouring LOGIN-DELAY, sleeping for %i seconds"
+msgstr[0] "honrando LOGIN-DELAY, dormindo por %i segundo"
+msgstr[1] "honrando LOGIN-DELAY, dormindo por %i segundos"
+
+#: src/mn-pop3-mailbox.gob:682
+msgid "server does not support APOP authentication"
+msgstr "servidor não suporta autenticação APOP"
+
+#: src/mn-pop3-mailbox.gob:710
+msgid "falling back to APOP authentication"
+msgstr "recorrendo a autenticação APOP"
+
+#: src/mn-pop3-mailbox.gob:715
+msgid "falling back to USER/PASS authentication"
+msgstr "recorrendo a autenticação USER/PASS"
+
+#: src/mn-properties.c:151
+msgid "No mailbox selected."
+msgstr "Nenhuma caixa de correio seleccionada."
+
+#: src/mn-properties.c:156
+#, c-format
+msgid "%i mailbox selected."
+msgid_plural "%i mailboxes selected."
+msgstr[0] "%i caixa de correio seleccionada."
+msgstr[1] "%i caixas de correio seleccionadas."
+
+#: src/mn-shell.gob:204
+msgid "A command error has occurred"
+msgstr "ocorreu um erro de comando"
+
+#: src/mn-shell.gob:205
+#, c-format
+msgid "Unable to execute double-clicked command: %s."
+msgstr "Incapaz de executar comando de duplo-clique: %s."
+
+#: src/mn-shell.gob:292
+msgid "The following mailbox has new mail:\n"
+msgid_plural "The following mailboxes have new mail:\n"
+msgstr[0] "A seguinte caixa de correio tem novo correio:\n"
+msgstr[1] "As seguintes caixas de correio têm novo correio:\n"
+
+#: src/mn-shell.gob:296
+msgid "You have no new mail."
+msgstr "Não tem correio novo."
+
+#: src/mn-shell.gob:299
+msgid "The following mailbox reported an error:\n"
+msgid_plural "The following mailboxes reported an error:\n"
+msgstr[0] "A seguinte caixa de correio relatou um erro:\n"
+msgstr[1] "As seguintes caixas de correios relataram um erro:\n"
+
+#: src/mn-shell.gob:304
+msgid "The following mailbox is unsupported:\n"
+msgid_plural "The following mailboxes are unsupported:\n"
+msgstr[0] "A seguinte caixa de correio não é suportada:\n"
+msgstr[1] "As seguintes caixas de correio não são suportadas:\n"
+
+#: src/mn-shell.gob:320
+msgid "You have new mail."
+msgstr "Tem novo correio."
+
+#: src/mn-shell.gob:330
+msgid "A command error has occurred in Mail Notification"
+msgstr "Ocorreu um erro de comando na Notificação de Correio"
+
+#: src/mn-shell.gob:331
+#, c-format
+msgid "Unable to execute new mail command: %s."
+msgstr "Incapaz de executar o novo comando de correio: %s."
+
+#: src/mn-ssl.c:79
+#, fuzzy
+msgid "unknown SSL/TLS error"
+msgstr "erro de servidor desconhecido"
+
+#: src/mn-stock.c:28
+msgid "Select _All"
+msgstr "Seleccionar _Todas"
+
+#: src/mn-sylpheed-mailbox.gob:93
+#, c-format
+msgid "unable to open folder: %s"
+msgstr "incapaz de abrir pasta: %s"
+
+#: src/mn-sylpheed-mailbox.gob:127
+#, c-format
+msgid "unable to close folder: %s"
+msgstr "incapaz de fechar pasta: %s"
+
+#: src/mn-sylpheed-mailbox.gob:130
+#, c-format
+msgid "error while reading folder: %s"
+msgstr "erro ao ler pasta: %s"
+
+#: src/mn-system-mailbox-properties.gob:32 src/mn-uri.gob:391
+msgid "System Mailbox"
+msgstr "Caixa de Correio de Sistema"
+
+#: src/mn-system-mailbox-properties.gob:55
+#, c-format
+msgid "Your system mailbox (<span weight=\"bold\">%s</span>) will be used."
+msgstr ""
+"Será usada a sua caixa de correio de sistema (<span weight=\"bold\">%s</"
+"span>)."
+
+#: src/mn-system-mailbox-properties.gob:62
+msgid ""
+"The location of your system mailbox could not be detected. Please set the "
+"MAIL environment variable."
+msgstr ""
+"A localização da sua caixa de correi ode sistema não pode ser detectada. Por "
+"favor defina a variável de ambiente MAIL."
+
+#: src/mn-unsupported-mailbox.gob:31
+msgid "The reason why the mailbox is unsupported"
+msgstr "A razão pela qual a caixa de correio não é suportada"
+
+#: src/mn-unsupported-mailbox.gob:38
+msgid "unsupported"
+msgstr "não suportado"
+
+#: src/mn-util.c:199
+#, c-format
+msgid "error loading image: %s"
+msgstr "erro ao carregar imagem: %s"
+
+#: src/mn-util.c:237
+#, c-format
+msgid "widget %s not found in interface %s"
+msgstr "widget %s não foi encontrada na interface %s"
+
+#: src/mn-util.c:355
+msgid "received an invalid URI list"
+msgstr "recebida uma lista de URIs inválida"
+
+#: src/mn-util.c:391
+msgid "received an invalid Mozilla URL"
+msgstr "recebido um URL Mozilla inválido"
+
+#: src/mn-util.c:484
+msgid "Unable to display help"
+msgstr "Incapaz de mostrar ajuda"
+
+#: src/mn-util.c:498
+#, c-format
+msgid "Unable to create a thread: %s."
+msgstr "Incapaz de criar uma thread: %s."
+
+#: src/mn-util.c:701
+msgid "A fatal error has occurred in Mail Notification"
+msgstr "Ocorreu um erro fatal na Notificação de Correio"
+
+#: ui/mailbox-properties.glade.h:1
+msgid "_Mailbox type:"
+msgstr "_Tipo de caixa de correio:"
+
+#: ui/properties.glade.h:1
+msgid " "
+msgstr " "
+
+#: ui/properties.glade.h:2
+msgid "*"
+msgstr "*"
+
+#: ui/properties.glade.h:3
+msgid "<span weight=\"bold\">Commands</span>"
+msgstr "<span weight=\"bold\">Comandos</span>"
+
+#: ui/properties.glade.h:4
+msgid "<span weight=\"bold\">General</span>"
+msgstr "<span weight=\"bold\">Geral</span>"
+
+#: ui/properties.glade.h:5
+msgid "<span weight=\"bold\">Mailboxes</span>"
+msgstr "<span weight=\"bold\">Caixas de Correio</span>"
+
+#: ui/properties.glade.h:6
+msgid "Mail Notification Properties"
+msgstr "Propriedades de Notificação de Correio"
+
+#: ui/properties.glade.h:7
+msgid "The amount of time to wait between mail checks"
+msgstr "A quantidade de tempo a esperar entre verificações de correio"
+
+#: ui/properties.glade.h:8
+msgid "The command to run when new mail arrives"
+msgstr "O comando a executar quando chega novo correio"
+
+#: ui/properties.glade.h:9
+msgid "The command to run when the icon is double-clicked"
+msgstr "O comando a executar quando fizer duplo-clique no ícone"
+
+#: ui/properties.glade.h:10
+msgid "When _new mail arrives:"
+msgstr "Quando chega _novo correio:"
+
+#: ui/properties.glade.h:11
+msgid "When double-click_ed:"
+msgstr "Quando há um duplo-clique:"
+
+#: ui/properties.glade.h:12
+#, fuzzy
+msgid "Whether the status icon should blink on errors or not"
+msgstr "Se a imagem pisca ou não"
+
+#: ui/properties.glade.h:13
+msgid "Whether to run a command when new mail arrives or not"
+msgstr "Se deve ser executado um comando quando chega novo correio"
+
+#: ui/properties.glade.h:14
+msgid "Whether to run a command when the icon is double-clicked or not"
+msgstr "Se deve ser executado um comando quando fizer duplo-clique no ícone"
+
+#: ui/properties.glade.h:15
+#, fuzzy
+msgid ""
+"Whether to start Mail Notification when you log into your GNOME session or "
+"not"
+msgstr "Se a Notificação de Correio já foi executada ou não."
+
+#: ui/properties.glade.h:16
+msgid "_Blink on errors"
+msgstr ""
+
+#: ui/properties.glade.h:17
+msgid "_Delay between mail checks:"
+msgstr "_Intervalo entre verificações de correio:"
+
+#: ui/properties.glade.h:18
+#, fuzzy
+msgid "_Start Mail Notification on GNOME login"
+msgstr "Um Ícone de Notificação de Correio"
+
+#: ui/properties.glade.h:19
+msgid "minutes"
+msgstr "minutos"
+
+#: ui/properties.glade.h:20
+msgid "seconds"
+msgstr "segundos"
+
+#: ui/welcome.glade.h:1
+#, fuzzy
+msgid ""
+"<span weight=\"bold\" size=\"larger\">First startup</span>\n"
+"\n"
+"Mail Notification has been loaded successfully.\n"
+"\n"
+"Since this is the first time you run Mail Notification, you might want to "
+"configure it.\n"
+"\n"
+"Note: this message will not be shown anymore. To configure Mail Notification "
+"again, choose <span weight=\"bold\">Applications</span> → <span weight=\"bold"
+"\">Desktop Preferences</span> → <span weight=\"bold\">Mail Notification</"
+"span> (or on some systems <span weight=\"bold\">Applications → Preferences → "
+"More Preferences → Mail Notification</span>)."
+msgstr ""
+"<span weight=\"bold\" size=\"larger\">Primeira Utilização</span>\n"
+"\n"
+"A Notificação de Correio foi carregada com sucesso.\n"
+"\n"
+"Como esta é a primeira vez que executa a Notificação de Correio, talvez "
+"queira configurá-la.\n"
+"\n"
+"Nota: esta mensagem não será mostrada de novo. Para configurar a Notificação "
+"de Correio outra vez, escolha <span weight=\"bold\">Aplicações</span> <span "
+"weight=\"bold\">Preferências do Ambiente</span> <span weight=\"bold"
+"\">Notificação de Correio</span>."
+
+#: ui/welcome.glade.h:8
+msgid "_Configure Mail Notification"
+msgstr "_Configurar Notificação de Correio"
+
+#: ui/welcome.glade.h:9
+msgid "_Skip configuration"
+msgstr "_Saltar configuração"
+
+#~ msgid "unable to parse Gmail URI"
+#~ msgstr "incapaz de processar URI Gmail"
+
+#~ msgid "unable to parse IMAP URI"
+#~ msgstr "incapaz de processar URI IMAP"
+
+#~ msgid "_SSL"
+#~ msgstr "_SSL"
+
+#~ msgid "unable to parse POP3 URI"
+#~ msgstr "incapaz de processar URI POP3"
diff --git a/po/ru.gmo b/po/ru.gmo
Binary files differ.
diff --git a/po/ru.po b/po/ru.po
@@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: mail-notification 0.5.0\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2004-08-19 00:12+0200\n"
+"POT-Creation-Date: 2004-09-09 01:43+0200\n"
"PO-Revision-Date: 2004-07-21 21:58+0200\n"
"Last-Translator: Dan Korostelev <dan@ats.energo.ru>\n"
"Language-Team: Russian\n"
@@ -38,7 +38,7 @@ msgstr "Иконка входящих сообщений"
#: data/mail-notification-properties.desktop.in.h:2
#: data/mail-notification.desktop.in.h:2
#: data/mail-notification.soundlist.in.h:1 src/mn-about-dialog.gob:38
-#: src/mn-mail-icon.gob:160 src/mn-main.c:212
+#: src/mn-mail-icon.gob:160 src/mn-main.c:221
msgid "Mail Notification"
msgstr "Иконка входящих сообщений"
@@ -48,95 +48,121 @@ msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
#: data/mail-notification.schemas.in.h:1
-msgid "Delay between mail checks (minutes part)."
+msgid "Blink on errors"
msgstr ""
#: data/mail-notification.schemas.in.h:2
-msgid "Delay between mail checks (seconds part)."
+msgid "Delay between mail checks (minutes part)."
msgstr ""
#: data/mail-notification.schemas.in.h:3
-msgid "Double-clicked command"
+msgid "Delay between mail checks (seconds part)."
msgstr ""
#: data/mail-notification.schemas.in.h:4
-msgid "Has already been run"
+msgid "Double-clicked command"
msgstr ""
#: data/mail-notification.schemas.in.h:5
-msgid "Height of properties dialog"
+msgid "Fingerprints of trusted X509 certificates"
msgstr ""
#: data/mail-notification.schemas.in.h:6
-msgid "Mailboxes list"
+msgid "Has already been run"
msgstr ""
#: data/mail-notification.schemas.in.h:7
-msgid "Minutes between mail checks"
+msgid "Height of properties dialog"
msgstr ""
#: data/mail-notification.schemas.in.h:8
-msgid "New mail command"
+msgid "Mailboxes list"
msgstr ""
#: data/mail-notification.schemas.in.h:9
+msgid "Minutes between mail checks"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:10
+msgid "New mail command"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:11
#, fuzzy
msgid "Run a command when new mail arrives"
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:10
+#: data/mail-notification.schemas.in.h:12
#, fuzzy
msgid "Run a command when the icon is double-clicked"
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:11
+#: data/mail-notification.schemas.in.h:13
msgid "Seconds between mail checks"
msgstr ""
-#: data/mail-notification.schemas.in.h:12
+#: data/mail-notification.schemas.in.h:14
#, fuzzy
msgid "The command to run when new mail arrives."
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:13
+#: data/mail-notification.schemas.in.h:15
#, fuzzy
msgid "The command to run when the icon is double-clicked."
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:14
+#: data/mail-notification.schemas.in.h:16
msgid "The height of the properties dialog in pixels."
msgstr ""
-#: data/mail-notification.schemas.in.h:15
+#: data/mail-notification.schemas.in.h:17
msgid "The list of mailboxes to monitor."
msgstr ""
-#: data/mail-notification.schemas.in.h:16
+#: data/mail-notification.schemas.in.h:18
+msgid ""
+"The list of trusted SSL/TLS servers (hostname:port) lacking a X509 "
+"certificate."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:19
+msgid ""
+"The list of trusted X509 certificates, represented by their MD5 fingerprint."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:20
msgid "The width of the properties dialog in pixels."
msgstr ""
-#: data/mail-notification.schemas.in.h:17
-#, fuzzy
+#: data/mail-notification.schemas.in.h:21
+msgid "Trusted servers list"
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:22
msgid "Whether Mail Notification has already been run or not."
-msgstr "Иконка входящих сообщений"
+msgstr ""
-#: data/mail-notification.schemas.in.h:18
+#: data/mail-notification.schemas.in.h:23
+msgid "Whether the status icon should blink on errors or not."
+msgstr ""
+
+#: data/mail-notification.schemas.in.h:24
#, fuzzy
msgid "Whether to run a command when new mail arrives or not."
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:19
+#: data/mail-notification.schemas.in.h:25
#, fuzzy
msgid "Whether to run a command when the icon is double-clicked or not."
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: data/mail-notification.schemas.in.h:20
+#: data/mail-notification.schemas.in.h:26
msgid "Width of properties dialog"
msgstr ""
@@ -160,23 +186,23 @@ msgstr ""
msgid "Jean-Yves Lefort <jylefort@brutele.be>"
msgstr "Dan Korostelev <dan@ats.energo.ru>"
-#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:36
+#: src/mn-auth-combo-box.gob:99 src/mn-autodetect-mailbox-properties.gob:35
msgid "<span style=\"italic\">autodetect</span>"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:67
+#: src/mn-autodetect-mailbox-properties.gob:66
msgid "_Location:"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:73
+#: src/mn-autodetect-mailbox-properties.gob:72
msgid "_Browse..."
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:80
+#: src/mn-autodetect-mailbox-properties.gob:79
msgid "The URI of the mailbox"
msgstr ""
-#: src/mn-autodetect-mailbox-properties.gob:117
+#: src/mn-autodetect-mailbox-properties.gob:116
msgid "Select a File or Folder"
msgstr ""
@@ -184,222 +210,270 @@ msgstr ""
msgid "Whether the image is blinking or not"
msgstr ""
-#: src/mn-client-session.c:195 src/mn-client-session.c:202
+#: src/mn-client-session.c:196 src/mn-client-session.c:203
#, c-format
msgid "unable to read from server: %s"
msgstr ""
-#: src/mn-client-session.c:200
+#: src/mn-client-session.c:201
msgid "unable to read from server: EOF"
msgstr ""
-#: src/mn-client-session.c:212
+#: src/mn-client-session.c:213
#, c-format
msgid "unable to decode data using SASL: %s"
msgstr ""
-#: src/mn-client-session.c:286
+#: src/mn-client-session.c:284
#, c-format
msgid "resolving %s"
msgstr ""
-#: src/mn-client-session.c:296
+#: src/mn-client-session.c:294
#, c-format
msgid "unable to resolve %s: %s"
msgstr ""
-#: src/mn-client-session.c:333
+#: src/mn-client-session.c:331
#, c-format
msgid "%s: unsupported address family"
msgstr ""
-#: src/mn-client-session.c:340
+#: src/mn-client-session.c:338
#, c-format
msgid "%s: unable to create socket: %s"
msgstr ""
-#: src/mn-client-session.c:344
+#: src/mn-client-session.c:342
#, c-format
msgid "connecting to %s (%s) port %i"
msgstr ""
-#: src/mn-client-session.c:347
+#: src/mn-client-session.c:345
#, c-format
msgid "unable to connect: %s"
msgstr ""
-#: src/mn-client-session.c:352
+#: src/mn-client-session.c:350
msgid "connected successfully"
msgstr ""
#. if reached, we couldn't find a working address
-#: src/mn-client-session.c:358
+#: src/mn-client-session.c:356
#, c-format
msgid "unable to connect to %s"
msgstr ""
-#: src/mn-client-session.c:374
+#: src/mn-client-session.c:372
#, c-format
msgid "unable to initialize the OpenSSL library: %s"
msgstr ""
-#: src/mn-client-session.c:382
+#: src/mn-client-session.c:380
+#, c-format
+msgid "unable to create a SSL/TLS object: %s"
+msgstr ""
+
+#: src/mn-client-session.c:386
#, c-format
-msgid "unable to create a SSL object: %s"
+msgid "unable to set the SSL/TLS file descriptor: %s"
+msgstr ""
+
+#: src/mn-client-session.c:392
+#, c-format
+msgid "unable to perform the SSL/TLS handshake: %s"
+msgstr ""
+
+#: src/mn-client-session.c:398
+msgid "untrusted server"
+msgstr ""
+
+#: src/mn-client-session.c:402
+#, c-format
+msgid "a SSL/TLS layer is now active (%s, %s %i-bit)"
+msgstr ""
+
+#: src/mn-client-session.c:449
+#, c-format
+msgid "%s, fingerprint: %s"
+msgstr ""
+
+#: src/mn-client-session.c:478
+msgid "missing certificate"
msgstr ""
-#: src/mn-client-session.c:388
+#: src/mn-client-session.c:504
#, c-format
-msgid "unable to set the SSL file descriptor: %s"
+msgid ""
+"Mail Notification was unable to trust \"%s\" (%s). It is possible that "
+"someone is intercepting your communication to obtain your confidential "
+"information.\n"
+"\n"
+"You should only connect to the server if you are certain you are connected "
+"to \"%s\". If you choose to connect to the server, this message will not be "
+"shown again."
+msgstr ""
+
+#: src/mn-client-session.c:521
+msgid "Connect to untrusted server?"
msgstr ""
-#: src/mn-client-session.c:443
+#: src/mn-client-session.c:526
+msgid "Co_nnect"
+msgstr ""
+
+#: src/mn-client-session.c:584
#, c-format
msgid "response \"%s\" is not valid in current context"
msgstr ""
-#: src/mn-client-session.c:469
+#: src/mn-client-session.c:610
#, c-format
msgid "unable to parse response \"%s\""
msgstr ""
-#: src/mn-client-session.c:516
+#: src/mn-client-session.c:657
#, c-format
msgid "unable to encode data using SASL: %s"
msgstr ""
-#: src/mn-client-session.c:545 src/mn-client-session.c:552
+#: src/mn-client-session.c:688 src/mn-client-session.c:695
#, c-format
msgid "unable to write to server: %s"
msgstr ""
-#: src/mn-client-session.c:550
+#: src/mn-client-session.c:693
msgid "unable to write to server: EOF"
msgstr ""
-#: src/mn-client-session.c:582
+#: src/mn-client-session.c:725
#, c-format
msgid "unable to encode Base64: %s"
msgstr ""
-#: src/mn-client-session.c:685
+#: src/mn-client-session.c:828
#, c-format
msgid "unable to initialize the SASL library: %s"
msgstr ""
-#: src/mn-client-session.c:694
+#: src/mn-client-session.c:837
#, c-format
msgid "unable to retrieve local address of socket: %s"
msgstr ""
-#: src/mn-client-session.c:700
+#: src/mn-client-session.c:843
#, c-format
msgid "unable to retrieve remote address of socket: %s"
msgstr ""
-#: src/mn-client-session.c:734
+#: src/mn-client-session.c:877
#, c-format
msgid "warning: unable to set SASL security properties: %s"
msgstr ""
-#: src/mn-client-session.c:773
+#: src/mn-client-session.c:916
msgid ""
"unable to start SASL authentication: SASL asked for something we did not know"
msgstr ""
-#: src/mn-client-session.c:777
+#: src/mn-client-session.c:920
#, c-format
msgid "unable to start SASL authentication: %s"
msgstr ""
-#: src/mn-client-session.c:781
+#: src/mn-client-session.c:924
#, c-format
msgid "unable to create a SASL connection: %s"
msgstr ""
-#: src/mn-client-session.c:831
+#: src/mn-client-session.c:974
msgid "SASL asked for something we did not know, aborting SASL authentication"
msgstr ""
-#: src/mn-client-session.c:835
+#: src/mn-client-session.c:978
#, c-format
msgid "%s, aborting SASL authentication"
msgstr ""
#. compliance error
-#: src/mn-client-session.c:840
+#: src/mn-client-session.c:983
#, c-format
msgid "unable to decode Base64 input from server: %s"
msgstr ""
-#: src/mn-client-session.c:843
+#: src/mn-client-session.c:986
msgid ""
"the server sent a SASL challenge, but there was a pending initial SASL "
"client response"
msgstr ""
-#: src/mn-client-session.c:857
+#: src/mn-client-session.c:1000
msgid ""
"the server did not send a SASL challenge, but there was no pending initial "
"SASL client response"
msgstr ""
-#: src/mn-client-session.c:880
+#: src/mn-client-session.c:1023
#, c-format
msgid "a SASL security layer of strength factor %i is now active"
msgstr ""
#. a security layer is active but we can't retrieve maxoutbuf -> fatal
-#: src/mn-client-session.c:885
+#: src/mn-client-session.c:1028
#, c-format
msgid "unable to get SASL_MAXOUTBUF property: %s"
msgstr ""
-#: src/mn-client-session.c:891
+#: src/mn-client-session.c:1034
#, c-format
msgid "warning: unable to get SASL_SSF property: %s"
msgstr ""
-#: src/mn-dialog.c:108
-msgid "A fatal error has occurred in Mail Notification"
+#: src/mn-conf.c:109
+#, c-format
+msgid "recursively unsetting %s"
msgstr ""
-#: src/mn-gmail-mailbox-properties.gob:78
-msgid "Your Gmail username"
+#: src/mn-conf.c:113
+msgid "syncing the GConf database"
msgstr ""
-#: src/mn-gmail-mailbox-properties.gob:79
-msgid "Your Gmail password"
+#: src/mn-conf.c:116
+msgid "completed"
msgstr ""
-#: src/mn-gmail-mailbox.gob:65
-msgid "unable to parse Gmail URI"
+#: src/mn-gmail-mailbox-properties.gob:77
+msgid "Your Gmail username"
msgstr ""
-#: src/mn-gmail-mailbox.gob:182
+#: src/mn-gmail-mailbox-properties.gob:78
+msgid "Your Gmail password"
+msgstr ""
+
+#: src/mn-gmail-mailbox.gob:220
msgid "logging in"
msgstr ""
-#: src/mn-gmail-mailbox.gob:201 src/mn-gmail-mailbox.gob:240
-#: src/mn-gmail-mailbox.gob:273 src/mn-gmail-mailbox.gob:377
+#: src/mn-gmail-mailbox.gob:239 src/mn-gmail-mailbox.gob:279
+#: src/mn-gmail-mailbox.gob:313 src/mn-gmail-mailbox.gob:418
#, c-format
msgid "unable to transfer data: %s"
msgstr ""
-#: src/mn-gmail-mailbox.gob:226 src/mn-gmail-mailbox.gob:259
-#: src/mn-gmail-mailbox.gob:293
+#: src/mn-gmail-mailbox.gob:265 src/mn-gmail-mailbox.gob:299
+#: src/mn-gmail-mailbox.gob:334
msgid "login failed"
msgstr ""
-#: src/mn-gmail-mailbox.gob:287
+#: src/mn-gmail-mailbox.gob:328
msgid "successfully logged in"
msgstr ""
-#: src/mn-gmail-mailbox.gob:365
+#: src/mn-gmail-mailbox.gob:406
msgid "searching for unread mail"
msgstr ""
-#: src/mn-gmail-mailbox.gob:384
+#: src/mn-gmail-mailbox.gob:427
msgid "unable to parse Gmail data"
msgstr ""
@@ -415,72 +489,72 @@ msgstr ""
msgid "oth_er:"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:121
+#: src/mn-imap-mailbox-properties.gob:122
msgid "The hostname or IP address of the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:122
+#: src/mn-imap-mailbox-properties.gob:123
msgid "Your username on the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:123
+#: src/mn-imap-mailbox-properties.gob:124
msgid "Your password on the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:124
#: src/mn-imap-mailbox-properties.gob:125
+#: src/mn-imap-mailbox-properties.gob:126
msgid "The port number of the IMAP server"
msgstr ""
-#: src/mn-imap-mailbox-properties.gob:126
+#: src/mn-imap-mailbox-properties.gob:127
msgid "The mailbox name"
msgstr ""
-#: src/mn-imap-mailbox.gob:124 src/mn-pop3-mailbox.gob:133
-msgid "SSL support has not been compiled in"
+#: src/mn-imap-mailbox.gob:112 src/mn-pop3-mailbox.gob:125
+msgid "SSL/TLS support has not been compiled in"
msgstr ""
-#: src/mn-imap-mailbox.gob:128
-msgid "unable to parse IMAP URI"
-msgstr ""
-
-#: src/mn-imap-mailbox.gob:195
+#: src/mn-imap-mailbox.gob:179
msgid "server did not send capabilities"
msgstr ""
-#: src/mn-imap-mailbox.gob:267
+#: src/mn-imap-mailbox.gob:292
msgid "server advertised LOGINDISABLED, not using LOGIN authentication"
msgstr ""
-#: src/mn-imap-mailbox.gob:268
+#: src/mn-imap-mailbox.gob:293
msgid "unable to login"
msgstr ""
#. compliance error
-#: src/mn-imap-mailbox.gob:336
+#: src/mn-imap-mailbox.gob:361
msgid "server did not send status"
msgstr ""
-#: src/mn-imap-mailbox.gob:554 src/mn-pop3-mailbox.gob:715
+#: src/mn-imap-mailbox.gob:583 src/mn-pop3-mailbox.gob:744
msgid "unknown server error"
msgstr ""
-#: src/mn-imap-mailbox.gob:625 src/mn-pop3-mailbox.gob:645
+#: src/mn-imap-mailbox.gob:656 src/mn-pop3-mailbox.gob:210
+msgid "server does not support in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-imap-mailbox.gob:675 src/mn-pop3-mailbox.gob:674
msgid ""
"a SASL authentication mechanism was selected but SASL support has not been "
"compiled in"
msgstr ""
-#: src/mn-imap-mailbox.gob:633 src/mn-pop3-mailbox.gob:657
+#: src/mn-imap-mailbox.gob:683 src/mn-pop3-mailbox.gob:686
#, c-format
msgid "unknown authentication mechanism \"%s\""
msgstr ""
-#: src/mn-imap-mailbox.gob:651
+#: src/mn-imap-mailbox.gob:701
msgid "falling back to IMAP LOGIN authentication"
msgstr ""
-#: src/mn-imap-mailbox.gob:655 src/mn-pop3-mailbox.gob:691
+#: src/mn-imap-mailbox.gob:705 src/mn-pop3-mailbox.gob:720
msgid "authentication failed"
msgstr ""
@@ -510,23 +584,23 @@ msgstr ""
msgid "%s Properties"
msgstr ""
-#: src/mn-mailbox-properties-util.c:75
+#: src/mn-mailbox-properties-util.c:77
msgid "_Username:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:79
+#: src/mn-mailbox-properties-util.c:87
msgid "_Password:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:146
+#: src/mn-mailbox-properties-util.c:154
msgid "Connection type:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:153
+#: src/mn-mailbox-properties-util.c:161
msgid "Port:"
msgstr ""
-#: src/mn-mailbox-properties-util.c:180
+#: src/mn-mailbox-properties-util.c:189
msgid "_Authentication mechanism:"
msgstr ""
@@ -554,56 +628,56 @@ msgstr ""
msgid "Whether the properties are completely filled or not"
msgstr ""
-#: src/mn-mailbox-view.gob:91
-msgid "Unable to add mailbox"
+#: src/mn-mailbox-view.gob:254
+msgid "Mailbox"
msgstr ""
-#: src/mn-mailbox-view.gob:91
-msgid "The mailbox is already in the list."
+#: src/mn-mailbox-view.gob:268
+msgid "Format"
msgstr ""
-#: src/mn-mailbox-view.gob:283
-msgid "Mailbox"
+#: src/mn-mailbox-view.gob:543
+msgid "Unable to add mailbox"
msgstr ""
-#: src/mn-mailbox-view.gob:297
-msgid "Format"
+#: src/mn-mailbox-view.gob:543
+msgid "The mailbox is already in the list."
msgstr ""
-#: src/mn-mailbox.gob:88
+#: src/mn-mailbox.gob:122
msgid "The mailbox URI"
msgstr ""
-#: src/mn-mailbox.gob:98
+#: src/mn-mailbox.gob:133
msgid "The mailbox human-readable name"
msgstr ""
-#: src/mn-mailbox.gob:102
+#: src/mn-mailbox.gob:137
msgid "Whether the mailbox has to be manually checked or not"
msgstr ""
-#: src/mn-mailbox.gob:107
+#: src/mn-mailbox.gob:142
msgid "Whether the mailbox has new mail or not"
msgstr ""
-#: src/mn-mailbox.gob:112
+#: src/mn-mailbox.gob:147
msgid "The mailbox error, if any"
msgstr ""
-#: src/mn-mailbox.gob:218
+#: src/mn-mailbox.gob:251
msgid "does not exist"
msgstr ""
-#: src/mn-mailbox.gob:255
+#: src/mn-mailbox.gob:287
msgid "unknown format"
msgstr ""
-#: src/mn-mailbox.gob:316
+#: src/mn-mailbox.gob:355
#, c-format
msgid "unable to monitor %s: %s"
msgstr ""
-#: src/mn-mailbox.gob:330
+#: src/mn-mailbox.gob:369
#, c-format
msgid ""
"As a fallback, they will be checked every %i second (this delay is "
@@ -614,7 +688,7 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:341
+#: src/mn-mailbox.gob:380
#, c-format
msgid ""
"As a fallback, they will be checked every %i minute (this delay is "
@@ -625,7 +699,7 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:352
+#: src/mn-mailbox.gob:391
#, c-format
msgid ""
"As a fallback, they will be checked approximately every %i minute (this "
@@ -636,58 +710,58 @@ msgid_plural ""
msgstr[0] ""
msgstr[1] ""
-#: src/mn-mailbox.gob:366
+#: src/mn-mailbox.gob:405
msgid "A monitoring error has occurred"
msgstr ""
-#: src/mn-mailbox.gob:367
+#: src/mn-mailbox.gob:406
#, c-format
msgid ""
-"Mail Notification was unable to enable automatic notification for one or "
+"Mail Notification was unable to enable immediate notification for one or "
"more mailboxes. %s"
msgstr ""
-#: src/mn-mailboxes.gob:130
+#: src/mn-mailboxes.gob:143
#, c-format
msgid "%s is unsupported: %s"
msgstr ""
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has new mail"
msgstr ""
-#: src/mn-mailboxes.gob:157
+#: src/mn-mailboxes.gob:170
#, c-format
msgid "%s has no new mail"
msgstr ""
-#: src/mn-mailboxes.gob:173
+#: src/mn-mailboxes.gob:186
#, c-format
msgid "%s reported an error: %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:98
+#: src/mn-maildir-mailbox.gob:109
#, c-format
msgid "unable to open folder \"new\": %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:126
+#: src/mn-maildir-mailbox.gob:137
#, c-format
msgid "unable to close folder \"new\": %s"
msgstr ""
-#: src/mn-maildir-mailbox.gob:129
+#: src/mn-maildir-mailbox.gob:140
#, c-format
msgid "error while reading folder \"new\": %s"
msgstr ""
-#: src/mn-main.c:86
+#: src/mn-main.c:85
#, c-format
msgid "Compiled-in mailbox backends: %s\n"
msgstr ""
-#: src/mn-main.c:104
+#: src/mn-main.c:103
#, c-format
msgid "Compiled-in features: %s\n"
msgstr ""
@@ -716,61 +790,65 @@ msgstr ""
msgid "Report the mail status"
msgstr ""
+#: src/mn-main.c:187
+msgid "Unset obsolete GConf configuration and exit"
+msgstr ""
+
#.
#. * We can't use mn_error_dialog() because gtk_init() has not been
#. * called yet.
#.
-#: src/mn-main.c:204
+#: src/mn-main.c:213
msgid "multi-threading is not available"
msgstr ""
-#: src/mn-main.c:243
+#: src/mn-main.c:258
msgid ""
"Bonobo could not locate the automation object. Please check your Mail "
"Notification installation."
msgstr ""
-#: src/mn-main.c:248
+#: src/mn-main.c:263
msgid "Unable to initialize the GnomeVFS library."
msgstr ""
-#: src/mn-main.c:270
+#: src/mn-main.c:285
msgid "updating the mail status"
msgstr ""
-#: src/mn-main.c:286
+#: src/mn-main.c:301
#, fuzzy
msgid "Mail Notification is already running"
msgstr "Иконка входящих сообщений"
-#: src/mn-main.c:293
+#: src/mn-main.c:308
msgid ""
"Bonobo could not locate the GNOME_MailNotification_Automation.server file. "
"Please check your Mail Notification installation."
msgstr ""
-#: src/mn-main.c:297
+#: src/mn-main.c:312
msgid ""
"Bonobo was unable to register the automation server. Please check your Mail "
"Notification installation."
msgstr ""
-#: src/mn-mbox-mailbox.gob:165
+#: src/mn-mbox-mailbox.gob:171
#, c-format
msgid "error while reading mailbox: %s"
msgstr ""
-#: src/mn-mbox-mailbox.gob:173
+#: src/mn-mbox-mailbox.gob:179
#, c-format
msgid "unable to open mailbox: %s"
msgstr ""
-#: src/mn-mh-mailbox.gob:111
+#: src/mn-mh-mailbox.gob:122
#, c-format
msgid "error while reading .mh_sequences: %s"
msgstr ""
-#: src/mn-mh-mailbox.gob:119
+#: src/mn-mh-mailbox.gob:130
#, c-format
msgid "unable to open .mh_sequences: %s"
msgstr ""
@@ -779,20 +857,24 @@ msgstr ""
msgid "detecting"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:75
+#: src/mn-pi-mailbox-properties.gob:74
msgid "_Hostname:"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:93
+#: src/mn-pi-mailbox-properties.gob:92
msgid "_Details"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:105
+#: src/mn-pi-mailbox-properties.gob:104
msgid "sta_ndard"
msgstr ""
-#: src/mn-pi-mailbox-properties.gob:115
-msgid "_SSL"
+#: src/mn-pi-mailbox-properties.gob:114
+msgid "_in-band SSL/TLS"
+msgstr ""
+
+#: src/mn-pi-mailbox-properties.gob:124
+msgid "SSL/TLS on sepa_rate port"
msgstr ""
#: src/mn-pop3-mailbox-properties.gob:84
@@ -811,117 +893,117 @@ msgstr ""
msgid "The port number of the POP3 server"
msgstr ""
-#: src/mn-pop3-mailbox.gob:137
-msgid "unable to parse POP3 URI"
-msgstr ""
-
-#: src/mn-pop3-mailbox.gob:267
+#: src/mn-pop3-mailbox.gob:256
msgid "invalid arguments for the LOGIN-DELAY capability"
msgstr ""
-#: src/mn-pop3-mailbox.gob:495
+#: src/mn-pop3-mailbox.gob:523
#, c-format
msgid "honouring LOGIN-DELAY, sleeping for %i second"
msgid_plural "honouring LOGIN-DELAY, sleeping for %i seconds"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-pop3-mailbox.gob:653
+#: src/mn-pop3-mailbox.gob:682
msgid "server does not support APOP authentication"
msgstr ""
-#: src/mn-pop3-mailbox.gob:681
+#: src/mn-pop3-mailbox.gob:710
msgid "falling back to APOP authentication"
msgstr ""
-#: src/mn-pop3-mailbox.gob:686
+#: src/mn-pop3-mailbox.gob:715
msgid "falling back to USER/PASS authentication"
msgstr ""
-#: src/mn-properties.c:132
+#: src/mn-properties.c:151
msgid "No mailbox selected."
msgstr ""
-#: src/mn-properties.c:137
+#: src/mn-properties.c:156
#, c-format
msgid "%i mailbox selected."
msgid_plural "%i mailboxes selected."
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:191
+#: src/mn-shell.gob:204
msgid "A command error has occurred"
msgstr ""
-#: src/mn-shell.gob:192
+#: src/mn-shell.gob:205
#, c-format
msgid "Unable to execute double-clicked command: %s."
msgstr ""
-#: src/mn-shell.gob:297
+#: src/mn-shell.gob:292
msgid "The following mailbox has new mail:\n"
msgid_plural "The following mailboxes have new mail:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:301
+#: src/mn-shell.gob:296
msgid "You have no new mail."
msgstr ""
-#: src/mn-shell.gob:304
+#: src/mn-shell.gob:299
msgid "The following mailbox reported an error:\n"
msgid_plural "The following mailboxes reported an error:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:309
+#: src/mn-shell.gob:304
msgid "The following mailbox is unsupported:\n"
msgid_plural "The following mailboxes are unsupported:\n"
msgstr[0] ""
msgstr[1] ""
-#: src/mn-shell.gob:325
+#: src/mn-shell.gob:320
msgid "You have new mail."
msgstr ""
-#: src/mn-shell.gob:338
+#: src/mn-shell.gob:330
msgid "A command error has occurred in Mail Notification"
msgstr ""
-#: src/mn-shell.gob:339
+#: src/mn-shell.gob:331
#, c-format
msgid "Unable to execute new mail command: %s."
msgstr ""
+#: src/mn-ssl.c:79
+msgid "unknown SSL/TLS error"
+msgstr ""
+
#: src/mn-stock.c:28
msgid "Select _All"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:84
+#: src/mn-sylpheed-mailbox.gob:93
#, c-format
msgid "unable to open folder: %s"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:118
+#: src/mn-sylpheed-mailbox.gob:127
#, c-format
msgid "unable to close folder: %s"
msgstr ""
-#: src/mn-sylpheed-mailbox.gob:121
+#: src/mn-sylpheed-mailbox.gob:130
#, c-format
msgid "error while reading folder: %s"
msgstr ""
-#: src/mn-system-mailbox-properties.gob:33 src/mn-uri.c:672
+#: src/mn-system-mailbox-properties.gob:32 src/mn-uri.gob:391
msgid "System Mailbox"
msgstr ""
-#: src/mn-system-mailbox-properties.gob:56
+#: src/mn-system-mailbox-properties.gob:55
#, c-format
msgid "Your system mailbox (<span weight=\"bold\">%s</span>) will be used."
msgstr ""
-#: src/mn-system-mailbox-properties.gob:63
+#: src/mn-system-mailbox-properties.gob:62
msgid ""
"The location of your system mailbox could not be detected. Please set the "
"MAIL environment variable."
@@ -935,33 +1017,37 @@ msgstr ""
msgid "unsupported"
msgstr ""
-#: src/mn-util.c:116
+#: src/mn-util.c:199
#, c-format
msgid "error loading image: %s"
msgstr ""
-#: src/mn-util.c:154
+#: src/mn-util.c:237
#, c-format
msgid "widget %s not found in interface %s"
msgstr ""
-#: src/mn-util.c:261
+#: src/mn-util.c:355
msgid "received an invalid URI list"
msgstr ""
-#: src/mn-util.c:297
+#: src/mn-util.c:391
msgid "received an invalid Mozilla URL"
msgstr ""
-#: src/mn-util.c:389
+#: src/mn-util.c:484
msgid "Unable to display help"
msgstr ""
-#: src/mn-util.c:403
+#: src/mn-util.c:498
#, c-format
msgid "Unable to create a thread: %s."
msgstr ""
+#: src/mn-util.c:701
+msgid "A fatal error has occurred in Mail Notification"
+msgstr ""
+
#: ui/mailbox-properties.glade.h:1
msgid "_Mailbox type:"
msgstr ""
@@ -1014,24 +1100,43 @@ msgid "When double-click_ed:"
msgstr ""
#: ui/properties.glade.h:12
-msgid "Whether to run a command when new mail arrives or not"
+msgid "Whether the status icon should blink on errors or not"
msgstr ""
#: ui/properties.glade.h:13
+msgid "Whether to run a command when new mail arrives or not"
+msgstr ""
+
+#: ui/properties.glade.h:14
#, fuzzy
msgid "Whether to run a command when the icon is double-clicked or not"
msgstr ""
"Иконка в области уведомления панели, уведомляющая о приходе новой почты."
-#: ui/properties.glade.h:14
+#: ui/properties.glade.h:15
+msgid ""
+"Whether to start Mail Notification when you log into your GNOME session or "
+"not"
+msgstr ""
+
+#: ui/properties.glade.h:16
+msgid "_Blink on errors"
+msgstr ""
+
+#: ui/properties.glade.h:17
msgid "_Delay between mail checks:"
msgstr ""
-#: ui/properties.glade.h:15
+#: ui/properties.glade.h:18
+#, fuzzy
+msgid "_Start Mail Notification on GNOME login"
+msgstr "Иконка входящих сообщений"
+
+#: ui/properties.glade.h:19
msgid "minutes"
msgstr ""
-#: ui/properties.glade.h:16
+#: ui/properties.glade.h:20
msgid "seconds"
msgstr ""
@@ -1047,7 +1152,8 @@ msgid ""
"Note: this message will not be shown anymore. To configure Mail Notification "
"again, choose <span weight=\"bold\">Applications</span> → <span weight=\"bold"
"\">Desktop Preferences</span> → <span weight=\"bold\">Mail Notification</"
-"span>."
+"span> (or on some systems <span weight=\"bold\">Applications → Preferences → "
+"More Preferences → Mail Notification</span>)."
msgstr ""
#: ui/welcome.glade.h:8
diff --git a/src/Makefile.am b/src/Makefile.am
@@ -125,7 +125,8 @@ gob_sources = \
mn-pending-mailbox.gob \
mn-shell.gob \
mn-system-mailbox-properties.gob \
- mn-unsupported-mailbox.gob
+ mn-unsupported-mailbox.gob \
+ mn-uri.gob
gob_built_sources = \
$(mbox_gob_built_sources) \
$(mh_gob_built_sources) \
@@ -170,7 +171,10 @@ gob_built_sources = \
mn-system-mailbox-properties.h \
mn-unsupported-mailbox-private.h \
mn-unsupported-mailbox.c \
- mn-unsupported-mailbox.h
+ mn-unsupported-mailbox.h \
+ mn-uri-private.h \
+ mn-uri.c \
+ mn-uri.h
nodist_mail_notification_SOURCES = $(idl_built_sources)
mail_notification_SOURCES = \
@@ -186,8 +190,6 @@ mail_notification_SOURCES = \
eggtrayicon.h \
mn-conf.c \
mn-conf.h \
- mn-dialog.c \
- mn-dialog.h \
mn-mailbox-properties-dialog.c \
mn-mailbox-properties-dialog.h \
mn-mailbox-properties-util.c \
@@ -199,8 +201,6 @@ mail_notification_SOURCES = \
mn-properties.h \
mn-stock.c \
mn-stock.h \
- mn-uri.c \
- mn-uri.h \
mn-util.c \
mn-util.h \
mn-vfs.c \
diff --git a/src/Makefile.in b/src/Makefile.in
@@ -41,8 +41,8 @@ subdir = src
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/openssl.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/sasl2.m4 \
- $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/sasl2.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
@@ -62,11 +62,11 @@ am__mail_notification_SOURCES_DIST = MNAutomation.idl \
mn-blinking-image.gob mn-mail-icon.gob mn-mailbox-view.gob \
mn-mailbox.gob mn-mailboxes.gob mn-pending-mailbox.gob \
mn-shell.gob mn-system-mailbox-properties.gob \
- mn-unsupported-mailbox.gob mn-mbox-mailbox-private.h \
- mn-mbox-mailbox.c mn-mbox-mailbox.h mn-mh-mailbox-private.h \
- mn-mh-mailbox.c mn-mh-mailbox.h mn-maildir-mailbox-private.h \
- mn-maildir-mailbox.c mn-maildir-mailbox.h \
- mn-pop3-mailbox-properties-private.h \
+ mn-unsupported-mailbox.gob mn-uri.gob \
+ mn-mbox-mailbox-private.h mn-mbox-mailbox.c mn-mbox-mailbox.h \
+ mn-mh-mailbox-private.h mn-mh-mailbox.c mn-mh-mailbox.h \
+ mn-maildir-mailbox-private.h mn-maildir-mailbox.c \
+ mn-maildir-mailbox.h mn-pop3-mailbox-properties-private.h \
mn-pop3-mailbox-properties.c mn-pop3-mailbox-properties.h \
mn-pop3-mailbox-private.h mn-pop3-mailbox.c mn-pop3-mailbox.h \
mn-imap-mailbox-properties-private.h \
@@ -93,15 +93,15 @@ am__mail_notification_SOURCES_DIST = MNAutomation.idl \
mn-shell.c mn-shell.h mn-system-mailbox-properties-private.h \
mn-system-mailbox-properties.c mn-system-mailbox-properties.h \
mn-unsupported-mailbox-private.h mn-unsupported-mailbox.c \
- mn-unsupported-mailbox.h mn-md5.c mn-md5.h mn-client-session.c \
- mn-client-session.h mn-soup.c mn-soup.h mn-ssl.c mn-ssl.h \
- mn-sasl.c mn-sasl.h eggtrayicon.c eggtrayicon.h mn-conf.c \
- mn-conf.h mn-dialog.c mn-dialog.h \
+ mn-unsupported-mailbox.h mn-uri-private.h mn-uri.c mn-uri.h \
+ mn-md5.c mn-md5.h mn-client-session.c mn-client-session.h \
+ mn-soup.c mn-soup.h mn-ssl.c mn-ssl.h mn-sasl.c mn-sasl.h \
+ eggtrayicon.c eggtrayicon.h mn-conf.c mn-conf.h \
mn-mailbox-properties-dialog.c mn-mailbox-properties-dialog.h \
mn-mailbox-properties-util.c mn-mailbox-properties-util.h \
mn-mailbox-properties.c mn-mailbox-properties.h mn-main.c \
- mn-properties.c mn-properties.h mn-stock.c mn-stock.h mn-uri.c \
- mn-uri.h mn-util.c mn-util.h mn-vfs.c mn-vfs.h
+ mn-properties.c mn-properties.h mn-stock.c mn-stock.h \
+ mn-util.c mn-util.h mn-vfs.c mn-vfs.h
am__objects_1 =
am__objects_2 = $(am__objects_1) $(am__objects_1) $(am__objects_1) \
$(am__objects_1) $(am__objects_1) $(am__objects_1) \
@@ -128,7 +128,7 @@ am__objects_11 = $(am__objects_3) $(am__objects_4) $(am__objects_5) \
mn-mailbox.$(OBJEXT) mn-mailboxes.$(OBJEXT) \
mn-pending-mailbox.$(OBJEXT) mn-shell.$(OBJEXT) \
mn-system-mailbox-properties.$(OBJEXT) \
- mn-unsupported-mailbox.$(OBJEXT)
+ mn-unsupported-mailbox.$(OBJEXT) mn-uri.$(OBJEXT)
@WITH_POP3_TRUE@am__objects_12 = mn-md5.$(OBJEXT)
@WITH_POP3_OR_IMAP_TRUE@am__objects_13 = mn-client-session.$(OBJEXT)
@HAVE_SOUP_TRUE@am__objects_14 = mn-soup.$(OBJEXT)
@@ -137,12 +137,12 @@ am__objects_11 = $(am__objects_3) $(am__objects_4) $(am__objects_5) \
am_mail_notification_OBJECTS = $(am__objects_1) $(am__objects_2) \
$(am__objects_11) $(am__objects_12) $(am__objects_13) \
$(am__objects_14) $(am__objects_15) $(am__objects_16) \
- eggtrayicon.$(OBJEXT) mn-conf.$(OBJEXT) mn-dialog.$(OBJEXT) \
+ eggtrayicon.$(OBJEXT) mn-conf.$(OBJEXT) \
mn-mailbox-properties-dialog.$(OBJEXT) \
mn-mailbox-properties-util.$(OBJEXT) \
mn-mailbox-properties.$(OBJEXT) mn-main.$(OBJEXT) \
- mn-properties.$(OBJEXT) mn-stock.$(OBJEXT) mn-uri.$(OBJEXT) \
- mn-util.$(OBJEXT) mn-vfs.$(OBJEXT)
+ mn-properties.$(OBJEXT) mn-stock.$(OBJEXT) mn-util.$(OBJEXT) \
+ mn-vfs.$(OBJEXT)
am__objects_17 = MNAutomation-common.$(OBJEXT) \
MNAutomation-stubs.$(OBJEXT) MNAutomation-skels.$(OBJEXT)
nodist_mail_notification_OBJECTS = $(am__objects_17)
@@ -162,7 +162,7 @@ am__depfiles_maybe = depfiles
@AMDEP_TRUE@ ./$(DEPDIR)/mn-automation.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/mn-blinking-image.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/mn-client-session.Po \
-@AMDEP_TRUE@ ./$(DEPDIR)/mn-conf.Po ./$(DEPDIR)/mn-dialog.Po \
+@AMDEP_TRUE@ ./$(DEPDIR)/mn-conf.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/mn-gmail-mailbox-properties.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/mn-gmail-mailbox.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/mn-imap-mailbox-properties.Po \
@@ -459,7 +459,8 @@ gob_sources = \
mn-pending-mailbox.gob \
mn-shell.gob \
mn-system-mailbox-properties.gob \
- mn-unsupported-mailbox.gob
+ mn-unsupported-mailbox.gob \
+ mn-uri.gob
gob_built_sources = \
$(mbox_gob_built_sources) \
@@ -505,7 +506,10 @@ gob_built_sources = \
mn-system-mailbox-properties.h \
mn-unsupported-mailbox-private.h \
mn-unsupported-mailbox.c \
- mn-unsupported-mailbox.h
+ mn-unsupported-mailbox.h \
+ mn-uri-private.h \
+ mn-uri.c \
+ mn-uri.h
nodist_mail_notification_SOURCES = $(idl_built_sources)
mail_notification_SOURCES = \
@@ -521,8 +525,6 @@ mail_notification_SOURCES = \
eggtrayicon.h \
mn-conf.c \
mn-conf.h \
- mn-dialog.c \
- mn-dialog.h \
mn-mailbox-properties-dialog.c \
mn-mailbox-properties-dialog.h \
mn-mailbox-properties-util.c \
@@ -534,8 +536,6 @@ mail_notification_SOURCES = \
mn-properties.h \
mn-stock.c \
mn-stock.h \
- mn-uri.c \
- mn-uri.h \
mn-util.c \
mn-util.h \
mn-vfs.c \
@@ -633,7 +633,6 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-blinking-image.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-client-session.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-conf.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-dialog.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-gmail-mailbox-properties.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-gmail-mailbox.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mn-imap-mailbox-properties.Po@am__quote@
diff --git a/src/mn-about-dialog.c b/src/mn-about-dialog.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
diff --git a/src/mn-auth-combo-box.c b/src/mn-auth-combo-box.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
diff --git a/src/mn-autodetect-mailbox-properties-private.h b/src/mn-autodetect-mailbox-properties-private.h
@@ -10,11 +10,11 @@ extern "C" {
#endif /* __cplusplus */
struct _MNAutodetectMailboxPropertiesPrivate {
-#line 38 "mn-autodetect-mailbox-properties.gob"
+#line 37 "mn-autodetect-mailbox-properties.gob"
GtkSizeGroup * size_group;
-#line 50 "mn-autodetect-mailbox-properties.gob"
+#line 49 "mn-autodetect-mailbox-properties.gob"
GtkTooltips * tooltips;
-#line 51 "mn-autodetect-mailbox-properties.gob"
+#line 50 "mn-autodetect-mailbox-properties.gob"
GtkWidget * location_entry;
#line 20 "mn-autodetect-mailbox-properties-private.h"
};
diff --git a/src/mn-autodetect-mailbox-properties.c b/src/mn-autodetect-mailbox-properties.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -27,12 +27,11 @@
#include <glib/gi18n-lib.h>
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
-#include "mn-uri.h"
#include "mn-util.h"
static char *current_folder_uri = NULL;
-#line 36 "mn-autodetect-mailbox-properties.c"
+#line 35 "mn-autodetect-mailbox-properties.c"
/* self casting macros */
#define SELF(x) MN_AUTODETECT_MAILBOX_PROPERTIES(x)
#define SELF_CONST(x) MN_AUTODETECT_MAILBOX_PROPERTIES_CONST(x)
@@ -55,8 +54,8 @@ static GObject * ___1_mn_autodetect_mailbox_properties_constructor (GType type,
static void mn_autodetect_mailbox_properties_entry_changed_h (GtkEditable * editable, gpointer user_data) G_GNUC_UNUSED;
static void mn_autodetect_mailbox_properties_browse_clicked_h (GtkButton * button, gpointer user_data) G_GNUC_UNUSED;
static void mn_autodetect_mailbox_properties_current_folder_changed_h (GtkFileChooser * chooser, gpointer user_data) G_GNUC_UNUSED;
-static gboolean mn_autodetect_mailbox_properties_set_uri (MNMailboxProperties * self, const char * uri) G_GNUC_UNUSED;
-static char * mn_autodetect_mailbox_properties_get_uri (MNMailboxProperties * self) G_GNUC_UNUSED;
+static gboolean mn_autodetect_mailbox_properties_set_uri (MNMailboxProperties * self, MNURI * uri) G_GNUC_UNUSED;
+static MNURI * mn_autodetect_mailbox_properties_get_uri (MNMailboxProperties * self) G_GNUC_UNUSED;
enum {
PROP_0,
@@ -79,11 +78,11 @@ static GtkHBoxClass *parent_class = NULL;
static void
___MN_Mailbox_Properties_init (MNMailboxPropertiesIface *iface)
{
-#line 156 "mn-autodetect-mailbox-properties.gob"
+#line 155 "mn-autodetect-mailbox-properties.gob"
iface->set_uri = self_set_uri;
-#line 164 "mn-autodetect-mailbox-properties.gob"
+#line 163 "mn-autodetect-mailbox-properties.gob"
iface->get_uri = self_get_uri;
-#line 87 "mn-autodetect-mailbox-properties.c"
+#line 86 "mn-autodetect-mailbox-properties.c"
}
GType
@@ -145,12 +144,12 @@ ___dispose (GObject *obj_self)
MNAutodetectMailboxProperties *self G_GNUC_UNUSED = MN_AUTODETECT_MAILBOX_PROPERTIES (obj_self);
if (G_OBJECT_CLASS (parent_class)->dispose) \
(* G_OBJECT_CLASS (parent_class)->dispose) (obj_self);
-#line 38 "mn-autodetect-mailbox-properties.gob"
+#line 37 "mn-autodetect-mailbox-properties.gob"
if(self->_priv->size_group) { ((*(void (*)(void *))g_object_unref)) (self->_priv->size_group); self->_priv->size_group = NULL; }
-#line 151 "mn-autodetect-mailbox-properties.c"
-#line 50 "mn-autodetect-mailbox-properties.gob"
+#line 150 "mn-autodetect-mailbox-properties.c"
+#line 49 "mn-autodetect-mailbox-properties.gob"
if(self->_priv->tooltips) { ((*(void (*)(void *))g_object_unref)) (self->_priv->tooltips); self->_priv->tooltips = NULL; }
-#line 154 "mn-autodetect-mailbox-properties.c"
+#line 153 "mn-autodetect-mailbox-properties.c"
}
#undef __GOB_FUNCTION__
@@ -172,9 +171,9 @@ mn_autodetect_mailbox_properties_init (MNAutodetectMailboxProperties * o G_GNUC_
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::init"
o->_priv = g_new0 (MNAutodetectMailboxPropertiesPrivate, 1);
-#line 50 "mn-autodetect-mailbox-properties.gob"
+#line 49 "mn-autodetect-mailbox-properties.gob"
o->_priv->tooltips = mn_tooltips_new();
-#line 178 "mn-autodetect-mailbox-properties.c"
+#line 177 "mn-autodetect-mailbox-properties.c"
}
#undef __GOB_FUNCTION__
static void
@@ -185,9 +184,9 @@ mn_autodetect_mailbox_properties_class_init (MNAutodetectMailboxPropertiesClass
parent_class = g_type_class_ref (GTK_TYPE_HBOX);
-#line 53 "mn-autodetect-mailbox-properties.gob"
+#line 52 "mn-autodetect-mailbox-properties.gob"
g_object_class->constructor = ___1_mn_autodetect_mailbox_properties_constructor;
-#line 191 "mn-autodetect-mailbox-properties.c"
+#line 190 "mn-autodetect-mailbox-properties.c"
g_object_class->dispose = ___dispose;
g_object_class->finalize = ___finalize;
g_object_class->get_property = ___object_get_property;
@@ -220,9 +219,9 @@ ___object_set_property (GObject *object,
switch (property_id) {
case PROP_SIZE_GROUP:
{
-#line 39 "mn-autodetect-mailbox-properties.gob"
+#line 38 "mn-autodetect-mailbox-properties.gob"
{ GObject *___old = (GObject *)self->_priv->size_group; self->_priv->size_group = (void *)g_value_dup_object (VAL); if (___old != NULL) { g_object_unref (G_OBJECT (___old)); } }
-#line 226 "mn-autodetect-mailbox-properties.c"
+#line 225 "mn-autodetect-mailbox-properties.c"
}
break;
default:
@@ -251,28 +250,28 @@ ___object_get_property (GObject *object,
switch (property_id) {
case PROP_LABEL:
{
-#line 36 "mn-autodetect-mailbox-properties.gob"
+#line 35 "mn-autodetect-mailbox-properties.gob"
g_value_set_string(VAL, _("<span style=\"italic\">autodetect</span>"));
-#line 257 "mn-autodetect-mailbox-properties.c"
+#line 256 "mn-autodetect-mailbox-properties.c"
}
break;
case PROP_SIZE_GROUP:
{
-#line 39 "mn-autodetect-mailbox-properties.gob"
+#line 38 "mn-autodetect-mailbox-properties.gob"
g_value_set_object (VAL, (gpointer)self->_priv->size_group);
-#line 264 "mn-autodetect-mailbox-properties.c"
+#line 263 "mn-autodetect-mailbox-properties.c"
}
break;
case PROP_COMPLETE:
{
-#line 43 "mn-autodetect-mailbox-properties.gob"
+#line 42 "mn-autodetect-mailbox-properties.gob"
const char *location;
location = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->location_entry));
g_value_set_boolean(VAL, *location != 0);
-#line 276 "mn-autodetect-mailbox-properties.c"
+#line 275 "mn-autodetect-mailbox-properties.c"
}
break;
default:
@@ -289,10 +288,10 @@ g_value_set_object (VAL, (gpointer)self->_priv->size_group);
-#line 53 "mn-autodetect-mailbox-properties.gob"
+#line 52 "mn-autodetect-mailbox-properties.gob"
static GObject *
___1_mn_autodetect_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_construct_properties, GObjectConstructParam * construct_params)
-#line 296 "mn-autodetect-mailbox-properties.c"
+#line 295 "mn-autodetect-mailbox-properties.c"
#define PARENT_HANDLER(___type,___n_construct_properties,___construct_params) \
((G_OBJECT_CLASS(parent_class)->constructor)? \
(* G_OBJECT_CLASS(parent_class)->constructor)(___type,___n_construct_properties,___construct_params): \
@@ -300,7 +299,7 @@ ___1_mn_autodetect_mailbox_properties_constructor (GType type G_GNUC_UNUSED, gui
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::constructor"
{
-#line 55 "mn-autodetect-mailbox-properties.gob"
+#line 54 "mn-autodetect-mailbox-properties.gob"
GObject *object;
Self *self;
@@ -344,47 +343,47 @@ ___1_mn_autodetect_mailbox_properties_constructor (GType type G_GNUC_UNUSED, gui
return object;
}}
-#line 348 "mn-autodetect-mailbox-properties.c"
+#line 347 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 99 "mn-autodetect-mailbox-properties.gob"
+#line 98 "mn-autodetect-mailbox-properties.gob"
static void
mn_autodetect_mailbox_properties_entry_changed_h (GtkEditable * editable, gpointer user_data)
-#line 355 "mn-autodetect-mailbox-properties.c"
+#line 354 "mn-autodetect-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::entry_changed_h"
-#line 99 "mn-autodetect-mailbox-properties.gob"
+#line 98 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (editable != NULL);
-#line 99 "mn-autodetect-mailbox-properties.gob"
+#line 98 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (GTK_IS_EDITABLE (editable));
-#line 99 "mn-autodetect-mailbox-properties.gob"
+#line 98 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (user_data != NULL);
-#line 364 "mn-autodetect-mailbox-properties.c"
+#line 363 "mn-autodetect-mailbox-properties.c"
{
-#line 102 "mn-autodetect-mailbox-properties.gob"
+#line 101 "mn-autodetect-mailbox-properties.gob"
Self *self = user_data;
g_object_notify(G_OBJECT(self), "complete");
}}
-#line 371 "mn-autodetect-mailbox-properties.c"
+#line 370 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 107 "mn-autodetect-mailbox-properties.gob"
+#line 106 "mn-autodetect-mailbox-properties.gob"
static void
mn_autodetect_mailbox_properties_browse_clicked_h (GtkButton * button, gpointer user_data)
-#line 377 "mn-autodetect-mailbox-properties.c"
+#line 376 "mn-autodetect-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::browse_clicked_h"
-#line 107 "mn-autodetect-mailbox-properties.gob"
+#line 106 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (button != NULL);
-#line 107 "mn-autodetect-mailbox-properties.gob"
+#line 106 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (GTK_IS_BUTTON (button));
-#line 107 "mn-autodetect-mailbox-properties.gob"
+#line 106 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (user_data != NULL);
-#line 386 "mn-autodetect-mailbox-properties.c"
+#line 385 "mn-autodetect-mailbox-properties.c"
{
-#line 110 "mn-autodetect-mailbox-properties.gob"
+#line 109 "mn-autodetect-mailbox-properties.gob"
Self *self = user_data;
GtkWidget *toplevel;
@@ -422,69 +421,71 @@ mn_autodetect_mailbox_properties_browse_clicked_h (GtkButton * button, gpointer
gtk_widget_destroy(chooser);
}}
-#line 426 "mn-autodetect-mailbox-properties.c"
+#line 425 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 148 "mn-autodetect-mailbox-properties.gob"
+#line 147 "mn-autodetect-mailbox-properties.gob"
static void
mn_autodetect_mailbox_properties_current_folder_changed_h (GtkFileChooser * chooser, gpointer user_data)
-#line 432 "mn-autodetect-mailbox-properties.c"
+#line 431 "mn-autodetect-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::current_folder_changed_h"
-#line 148 "mn-autodetect-mailbox-properties.gob"
+#line 147 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (chooser != NULL);
-#line 148 "mn-autodetect-mailbox-properties.gob"
+#line 147 "mn-autodetect-mailbox-properties.gob"
g_return_if_fail (GTK_IS_FILE_CHOOSER (chooser));
-#line 439 "mn-autodetect-mailbox-properties.c"
+#line 438 "mn-autodetect-mailbox-properties.c"
{
-#line 151 "mn-autodetect-mailbox-properties.gob"
+#line 150 "mn-autodetect-mailbox-properties.gob"
g_free(current_folder_uri);
current_folder_uri = gtk_file_chooser_get_current_folder_uri(chooser);
}}
-#line 446 "mn-autodetect-mailbox-properties.c"
+#line 445 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 156 "mn-autodetect-mailbox-properties.gob"
+#line 155 "mn-autodetect-mailbox-properties.gob"
static gboolean
-mn_autodetect_mailbox_properties_set_uri (MNMailboxProperties * self, const char * uri)
-#line 452 "mn-autodetect-mailbox-properties.c"
+mn_autodetect_mailbox_properties_set_uri (MNMailboxProperties * self, MNURI * uri)
+#line 451 "mn-autodetect-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::set_uri"
-#line 156 "mn-autodetect-mailbox-properties.gob"
+#line 155 "mn-autodetect-mailbox-properties.gob"
g_return_val_if_fail (self != NULL, (gboolean )0);
-#line 156 "mn-autodetect-mailbox-properties.gob"
+#line 155 "mn-autodetect-mailbox-properties.gob"
g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (gboolean )0);
-#line 156 "mn-autodetect-mailbox-properties.gob"
+#line 155 "mn-autodetect-mailbox-properties.gob"
g_return_val_if_fail (uri != NULL, (gboolean )0);
-#line 461 "mn-autodetect-mailbox-properties.c"
+#line 155 "mn-autodetect-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_URI (uri), (gboolean )0);
+#line 462 "mn-autodetect-mailbox-properties.c"
{
-#line 159 "mn-autodetect-mailbox-properties.gob"
+#line 158 "mn-autodetect-mailbox-properties.gob"
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->location_entry), uri);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->location_entry), uri->text);
return TRUE;
}}
-#line 468 "mn-autodetect-mailbox-properties.c"
+#line 469 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 164 "mn-autodetect-mailbox-properties.gob"
-static char *
+#line 163 "mn-autodetect-mailbox-properties.gob"
+static MNURI *
mn_autodetect_mailbox_properties_get_uri (MNMailboxProperties * self)
-#line 474 "mn-autodetect-mailbox-properties.c"
+#line 475 "mn-autodetect-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Autodetect:Mailbox:Properties::get_uri"
-#line 164 "mn-autodetect-mailbox-properties.gob"
- g_return_val_if_fail (self != NULL, (char * )0);
-#line 164 "mn-autodetect-mailbox-properties.gob"
- g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (char * )0);
-#line 481 "mn-autodetect-mailbox-properties.c"
+#line 163 "mn-autodetect-mailbox-properties.gob"
+ g_return_val_if_fail (self != NULL, (MNURI * )0);
+#line 163 "mn-autodetect-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (MNURI * )0);
+#line 482 "mn-autodetect-mailbox-properties.c"
{
-#line 166 "mn-autodetect-mailbox-properties.gob"
+#line 165 "mn-autodetect-mailbox-properties.gob"
const char *location;
location = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->location_entry));
- return g_strdup(location);
+ return mn_uri_new(location);
}}
-#line 490 "mn-autodetect-mailbox-properties.c"
+#line 491 "mn-autodetect-mailbox-properties.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-autodetect-mailbox-properties.gob b/src/mn-autodetect-mailbox-properties.gob
@@ -24,7 +24,6 @@
#include <glib/gi18n-lib.h>
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
-#include "mn-uri.h"
#include "mn-util.h"
static char *current_folder_uri = NULL;
@@ -155,18 +154,18 @@ class MN:Autodetect:Mailbox:Properties from Gtk:HBox (interface MN:Mailbox:Prope
interface MN:Mailbox:Properties private gboolean
set_uri (MN:Mailbox:Properties *self (check null type),
- const char *uri (check null))
+ MN:URI *uri (check null type))
{
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->location_entry), uri);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->location_entry), uri->text);
return TRUE;
}
- interface MN:Mailbox:Properties private char *
+ interface MN:Mailbox:Properties private MNURI *
get_uri (MN:Mailbox:Properties *self (check null type))
{
const char *location;
location = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->location_entry));
- return g_strdup(location);
+ return mn_uri_new(location);
}
}
diff --git a/src/mn-automation.c b/src/mn-automation.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
diff --git a/src/mn-blinking-image.c b/src/mn-blinking-image.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
diff --git a/src/mn-client-session.c b/src/mn-client-session.c
@@ -31,6 +31,7 @@
#include <errno.h>
#include <glib.h>
#include <glib/gi18n-lib.h>
+#include <eel/eel-alert-dialog.h>
#ifdef WITH_SSL
#include <openssl/err.h>
#include "mn-ssl.h"
@@ -42,6 +43,7 @@
#endif /* WITH_SASL */
#include "mn-util.h"
#include "mn-client-session.h"
+#include "mn-conf.h"
/*** cpp *********************************************************************/
@@ -63,7 +65,6 @@ struct _MNClientSession
MNClientSessionPrivate *private;
#ifdef WITH_SSL
- gboolean use_ssl;
SSL *ssl;
#endif
@@ -97,7 +98,9 @@ static struct addrinfo *mn_client_session_resolve (MNClientSession *session);
static int mn_client_session_connect (MNClientSession *session, struct addrinfo *addrinfo);
#ifdef WITH_SSL
-static gboolean mn_client_session_init_ssl (MNClientSession *session);
+static gboolean mn_client_session_ssl_verify (MNClientSession *session);
+static gboolean mn_client_session_run_untrusted_dialog (const char *hostname,
+ const char *reason);
#endif
static int mn_client_session_enter_state (MNClientSession *session, int id);
@@ -148,10 +151,6 @@ mn_client_session_run (MNClientSessionState *states,
session.password = g_strdup(password);
session.private = private;
-#ifdef WITH_SSL
- session.use_ssl = use_ssl;
-#endif
-
addrinfo = mn_client_session_resolve(&session);
if (! addrinfo)
goto end;
@@ -162,9 +161,9 @@ mn_client_session_run (MNClientSessionState *states,
goto end;
#ifdef WITH_SSL
- if (session.use_ssl)
+ if (use_ssl)
{
- if (! mn_client_session_init_ssl(&session))
+ if (! mn_client_session_enable_ssl(&session))
goto end;
}
#endif /* WITH_SSL */
@@ -182,17 +181,19 @@ mn_client_session_run (MNClientSessionState *states,
gboolean cont = TRUE;
#ifdef WITH_SSL
- if (session.use_ssl)
+ if (session.ssl)
bytes_read = SSL_read(session.ssl, buf, sizeof(buf));
else
#endif /* WITH_SSL */
- bytes_read = read(session.s, buf, sizeof(buf));
+ do
+ bytes_read = read(session.s, buf, sizeof(buf));
+ while (bytes_read < 0 && errno == EINTR);
if (bytes_read <= 0)
{
#ifdef WITH_SSL
- if (session.use_ssl)
- mn_client_session_error(&session, _("unable to read from server: %s"), ERR_reason_error_string(ERR_get_error()));
+ if (session.ssl)
+ mn_client_session_error(&session, _("unable to read from server: %s"), mn_ssl_get_error());
else
#endif /* WITH_SSL */
{
@@ -239,13 +240,10 @@ mn_client_session_run (MNClientSessionState *states,
g_free(session.username);
g_free(session.password);
if (session.s >= 0)
- close(session.s);
+ while (close(session.s) < 0 && errno == EINTR);
#ifdef WITH_SSL
- if (session.use_ssl)
- {
- if (session.ssl)
- SSL_free(session.ssl);
- }
+ if (session.ssl)
+ SSL_free(session.ssl);
#endif /* WITH_SSL */
#ifdef WITH_SASL
if (session.sasl_available)
@@ -360,8 +358,8 @@ mn_client_session_connect (MNClientSession *session, struct addrinfo *addrinfo)
}
#ifdef WITH_SSL
-static gboolean
-mn_client_session_init_ssl (MNClientSession *session)
+gboolean
+mn_client_session_enable_ssl (MNClientSession *session)
{
SSL_CTX *ctx;
GError *err = NULL;
@@ -379,20 +377,163 @@ mn_client_session_init_ssl (MNClientSession *session)
session->ssl = SSL_new(ctx);
if (! session->ssl)
{
- mn_client_session_error(session, _("unable to create a SSL object: %s"), ERR_reason_error_string(ERR_get_error()));
+ mn_client_session_error(session, _("unable to create a SSL/TLS object: %s"), mn_ssl_get_error());
return FALSE;
}
if (! SSL_set_fd(session->ssl, session->s))
{
- mn_client_session_error(session, _("unable to set the SSL file descriptor: %s"), ERR_reason_error_string(ERR_get_error()));
+ mn_client_session_error(session, _("unable to set the SSL/TLS file descriptor: %s"), mn_ssl_get_error());
return FALSE;
}
- SSL_set_connect_state(session->ssl);
+ if (SSL_connect(session->ssl) != 1)
+ {
+ mn_client_session_error(session, _("unable to perform the SSL/TLS handshake: %s"), mn_ssl_get_error());
+ return FALSE;
+ }
+
+ if (! mn_client_session_ssl_verify(session))
+ {
+ mn_client_session_error(session, _("untrusted server"));
+ return FALSE;
+ }
+
+ mn_client_session_notice(session, _("a SSL/TLS layer is now active (%s, %s %i-bit)"),
+ SSL_get_version(session->ssl),
+ SSL_get_cipher(session->ssl),
+ SSL_get_cipher_bits(session->ssl, NULL));
return TRUE;
}
+
+static gboolean
+mn_client_session_ssl_verify (MNClientSession *session)
+{
+ X509 *cert;
+ gboolean status = FALSE;
+
+ g_return_val_if_fail(session->ssl != NULL, FALSE);
+
+ cert = SSL_get_peer_certificate(session->ssl);
+ if (cert)
+ {
+ long verify_result;
+
+ verify_result = SSL_get_verify_result(session->ssl);
+ if (verify_result == X509_V_OK)
+ status = TRUE;
+ else
+ {
+ unsigned char md5sum[16];
+ unsigned char fingerprint[40];
+ int md5len;
+ int i;
+ unsigned char *f;
+ GSList *gconf_fingerprints;
+
+ /* calculate the MD5 hash of the raw certificate */
+ md5len = sizeof(md5sum);
+ X509_digest(cert, EVP_md5(), md5sum, &md5len);
+ for (i = 0, f = fingerprint; i < 16; i++, f += 3)
+ sprintf(f, "%.2x%c", md5sum[i], i != 15 ? ':' : '\0');
+
+ gconf_fingerprints = eel_gconf_get_string_list(MN_CONF_TRUSTED_X509_CERTIFICATES);
+
+ if (mn_g_str_slist_find(gconf_fingerprints, fingerprint) != NULL)
+ status = TRUE;
+ else
+ {
+ char *reason;
+
+ reason = g_strdup_printf(_("%s, fingerprint: %s"),
+ X509_verify_cert_error_string(verify_result),
+ fingerprint);
+
+ if (mn_client_session_run_untrusted_dialog(session->hostname, reason))
+ {
+ status = TRUE;
+ gconf_fingerprints = g_slist_append(gconf_fingerprints, g_strdup(fingerprint));
+ eel_gconf_set_string_list(MN_CONF_TRUSTED_X509_CERTIFICATES, gconf_fingerprints);
+ }
+ }
+
+ eel_g_slist_free_deep(gconf_fingerprints);
+ }
+
+ X509_free(cert);
+ }
+ else
+ {
+ char *server;
+ GSList *gconf_servers = NULL;
+
+ server = g_strdup_printf("%s:%i", session->hostname, session->port);
+ gconf_servers = eel_gconf_get_string_list(MN_CONF_TRUSTED_SERVERS);
+
+ if (mn_g_str_slist_find(gconf_servers, server) != NULL)
+ status = TRUE;
+ else
+ {
+ if (mn_client_session_run_untrusted_dialog(session->hostname, _("missing certificate")))
+ {
+ status = TRUE;
+ gconf_servers = g_slist_append(gconf_servers, g_strdup(server));
+ eel_gconf_set_string_list(MN_CONF_TRUSTED_SERVERS, gconf_servers);
+ }
+ }
+
+ g_free(server);
+ eel_g_slist_free_deep(gconf_servers);
+ }
+
+ return status;
+}
+
+static gboolean
+mn_client_session_run_untrusted_dialog (const char *hostname,
+ const char *reason)
+{
+ GtkWidget *dialog;
+ char *secondary;
+ gboolean status;
+
+ g_return_val_if_fail(hostname != NULL, FALSE);
+ g_return_val_if_fail(reason != NULL, FALSE);
+
+ secondary = g_strdup_printf(_("Mail Notification was unable to trust \"%s\" "
+ "(%s). It is possible that someone is "
+ "intercepting your communication to obtain "
+ "your confidential information.\n"
+ "\n"
+ "You should only connect to the server if you "
+ "are certain you are connected to \"%s\". "
+ "If you choose to connect to the server, this "
+ "message will not be shown again."),
+ hostname, reason, hostname);
+
+ GDK_THREADS_ENTER();
+
+ dialog = eel_alert_dialog_new(NULL,
+ GTK_DIALOG_DESTROY_WITH_PARENT,
+ GTK_MESSAGE_WARNING,
+ GTK_BUTTONS_NONE,
+ _("Connect to untrusted server?"),
+ secondary,
+ NULL);
+
+ gtk_dialog_add_button(GTK_DIALOG(dialog), GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL);
+ gtk_dialog_add_button(GTK_DIALOG(dialog), _("Co_nnect"), GTK_RESPONSE_OK);
+
+ status = gtk_dialog_run(GTK_DIALOG(dialog)) == GTK_RESPONSE_OK;
+ gtk_widget_destroy(dialog);
+
+ gdk_flush();
+ GDK_THREADS_LEAVE();
+
+ g_free(secondary);
+ return status;
+}
#endif /* WITH_SSL */
static int
@@ -532,17 +673,19 @@ mn_client_session_write (MNClientSession *session,
}
#ifdef WITH_SSL
- if (session->use_ssl)
+ if (session->ssl)
bytes_written = SSL_write(session->ssl, array->data, array->len);
else
#endif /* WITH_SSL */
- bytes_written = write(session->s, array->data, array->len);
+ do
+ bytes_written = write(session->s, array->data, array->len);
+ while (bytes_written < 0 && errno == EINTR);
if (bytes_written <= 0)
{
#ifdef WITH_SSL
- if (session->use_ssl)
- result = mn_client_session_error(session, _("unable to write to server: %s"), ERR_reason_error_string(ERR_get_error()));
+ if (session->ssl)
+ result = mn_client_session_error(session, _("unable to write to server: %s"), mn_ssl_get_error());
else
#endif /* WITH_SSL */
{
@@ -722,7 +865,7 @@ mn_client_session_sasl_authentication_start (MNClientSession *session,
security.maxbufsize = READ_BUFSIZE;
/* only permit plaintext mechanisms if SSL is in use */
#ifdef WITH_SSL
- if (session->use_ssl)
+ if (session->ssl)
security.security_flags = 0;
else
#endif /* WITH_SSL */
diff --git a/src/mn-client-session.h b/src/mn-client-session.h
@@ -81,6 +81,10 @@ int mn_client_session_write (MNClientSession *session,
const char *format,
...);
+#ifdef WITH_SSL
+gboolean mn_client_session_enable_ssl (MNClientSession *session);
+#endif
+
#ifdef WITH_SASL
gboolean mn_client_session_sasl_authentication_start (MNClientSession *session,
const char *service,
diff --git a/src/mn-conf.c b/src/mn-conf.c
@@ -1,4 +1,5 @@
/*
+ * Copyright (c) 1999 Free Software Foundation, Inc.
* Copyright (c) 2003, 2004 Jean-Yves Lefort <jylefort@brutele.be>
*
* This program is free software; you can redistribute it and/or modify
@@ -18,15 +19,28 @@
#include "config.h"
#include <stdarg.h>
+#include <gnome.h>
#include <eel/eel.h>
#include "mn-util.h"
#include "mn-conf.h"
/*** cpp *********************************************************************/
+#define SESSION_MANUAL_CONFIG_PREFIX "session-manual/"
+#define SESSION_MANUAL_NAME "Default"
+
#define WINDOW_WIDTH_KEY "mn-conf-window-width-key"
#define WINDOW_HEIGHT_KEY "mn-conf-window-height-key"
+/*** types *******************************************************************/
+
+typedef struct
+{
+ int order;
+ int argc;
+ char **argv;
+} StartupClient;
+
/*** functions ***************************************************************/
static gboolean mn_conf_link_window_h (GtkWidget *widget,
@@ -60,38 +74,61 @@ static void mn_conf_link_entry_notify_cb (GConfClient *client,
static void mn_conf_link_weak_notify_cb (gpointer data,
GObject *former_object);
+static void mn_conf_startup_client_free (StartupClient *client);
+static void mn_conf_startup_clients_free (GSList *list);
+
+static int mn_conf_startup_client_compare (gconstpointer a, gconstpointer b);
+
+static GSList *mn_conf_startup_list_read (const char *name);
+static void mn_conf_startup_list_write (GSList *list, const char *name);
+
+static GSList *mn_conf_get_autostart_elem (GSList *list);
+
/*** implementation **********************************************************/
void
mn_conf_init (void)
{
- GSList *gconf_mailboxes;
- GSList *l;
-
- /* convert old style locators */
+ /* monitor our namespace */
+ eel_gconf_monitor_add(MN_CONF_NAMESPACE);
+}
- gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
- MN_LIST_FOREACH(l, gconf_mailboxes)
+void
+mn_conf_unset_obsolete (void)
+{
+ const char *obsolete[] = {
+ MN_CONF_LOCAL_NAMESPACE,
+ MN_CONF_REMOTE_NAMESPACE,
+ MN_CONF_COMMANDS_CLICKED_NAMESPACE,
+ MN_CONF_PREFERENCES_DIALOG
+ };
+ int i;
+
+ for (i = 0; i < G_N_ELEMENTS(obsolete); i++)
{
- char *locator_or_uri = l->data;
- char *uri;
-
- if (locator_or_uri[0] == '/')
- uri = g_strconcat("file://", locator_or_uri, NULL);
- else if (! strncmp(locator_or_uri, "pop3:", 5))
- uri = g_strconcat("pop://", locator_or_uri + 5, NULL);
- else
- uri = g_strdup(locator_or_uri);
-
- g_free(locator_or_uri);
- l->data = uri;
+ g_message(_("recursively unsetting %s"), obsolete[i]);
+ mn_conf_recursive_unset(obsolete[i], GCONF_UNSET_INCLUDING_SCHEMA_NAMES);
}
- eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+
+ g_message(_("syncing the GConf database"));
+ eel_gconf_suggest_sync();
- /* monitor our namespace */
+ g_message(_("completed"));
+}
- eel_gconf_monitor_add(MN_CONF_NAMESPACE);
+void
+mn_conf_recursive_unset (const char *key, GConfUnsetFlags flags)
+{
+ GConfClient *client;
+ GError *err = NULL;
+
+ g_return_if_fail(key != NULL);
+
+ client = eel_gconf_client_get_global();
+ g_return_if_fail(client != NULL);
+
+ gconf_client_recursive_unset(client, key, flags, &err);
+ eel_gconf_handle_error(&err);
}
void
@@ -192,12 +229,16 @@ mn_conf_link_window_notify_cb (GConfClient *client,
gpointer user_data)
{
GtkWindow *window = user_data;
- const char *width_key = g_object_get_data(G_OBJECT(window), WINDOW_WIDTH_KEY);
- const char *height_key = g_object_get_data(G_OBJECT(window), WINDOW_HEIGHT_KEY);
+ const char *width_key;
+ const char *height_key;
+ GDK_THREADS_ENTER();
+ width_key = g_object_get_data(G_OBJECT(window), WINDOW_WIDTH_KEY);
+ height_key = g_object_get_data(G_OBJECT(window), WINDOW_HEIGHT_KEY);
gtk_window_resize(window,
eel_gconf_get_integer(width_key),
eel_gconf_get_integer(height_key));
+ GDK_THREADS_LEAVE();
}
static void
@@ -216,7 +257,9 @@ mn_conf_link_toggle_button_notify_cb (GConfClient *client,
GConfValue *value = gconf_entry_get_value(entry);
GtkToggleButton *button = user_data;
+ GDK_THREADS_ENTER();
gtk_toggle_button_set_active(button, gconf_value_get_bool(value));
+ GDK_THREADS_LEAVE();
}
static void
@@ -235,7 +278,9 @@ mn_conf_link_spin_button_notify_cb (GConfClient *client,
GConfValue *value = gconf_entry_get_value(entry);
GtkSpinButton *button = user_data;
+ GDK_THREADS_ENTER();
gtk_spin_button_set_value(button, gconf_value_get_int(value));
+ GDK_THREADS_LEAVE();
}
static void
@@ -261,9 +306,11 @@ mn_conf_link_entry_notify_cb (GConfClient *client,
GtkEntry *entry_widget = user_data;
const char *str = NULL;
+ GDK_THREADS_ENTER();
if (value)
str = gconf_value_get_string(value);
gtk_entry_set_text(entry_widget, str ? str : "");
+ GDK_THREADS_LEAVE();
}
static void
@@ -272,3 +319,191 @@ mn_conf_link_weak_notify_cb (gpointer data, GObject *former_object)
unsigned int notification_id = GPOINTER_TO_UINT(data);
eel_gconf_notification_remove(notification_id);
}
+
+/*
+ * The mn_conf_startup_* functions are based on code taken from
+ * startup-programs.c in gnome-session, written by Owen Taylor.
+ */
+
+static void
+mn_conf_startup_client_free (StartupClient *client)
+{
+ int i;
+
+ g_return_if_fail(client != NULL);
+
+ for (i = 0; i < client->argc; i++)
+ g_free(client->argv[i]);
+
+ g_free(client->argv);
+ g_free(client);
+}
+
+static void
+mn_conf_startup_clients_free (GSList *list)
+{
+ eel_g_slist_free_deep_custom(list, (GFunc) mn_conf_startup_client_free, NULL);
+}
+
+static int
+mn_conf_startup_client_compare (gconstpointer a, gconstpointer b)
+{
+ const StartupClient *client_a = a;
+ const StartupClient *client_b = b;
+
+ return client_a->order - client_b->order;
+}
+
+static GSList *
+mn_conf_startup_list_read (const char *name)
+{
+ GSList *list = NULL;
+ gpointer iterator;
+ char *p;
+ StartupClient *client = NULL;
+ char *handle = NULL;
+
+ g_return_val_if_fail(name != NULL, NULL);
+
+ gnome_config_push_prefix(SESSION_MANUAL_CONFIG_PREFIX);
+
+ iterator = gnome_config_init_iterator(name);
+ while (iterator)
+ {
+ char *key;
+ char *value;
+
+ iterator = gnome_config_iterator_next(iterator, &key, &value);
+ if (! iterator)
+ break;
+
+ p = strchr(key, ',');
+ if (p)
+ {
+ *p = 0;
+
+ if (! client || strcmp(handle, key))
+ {
+ g_free(handle);
+ handle = g_strdup(key);
+
+ client = g_new0(StartupClient, 1);
+ list = g_slist_append(list, client);
+ }
+
+ if (! strcmp(p + 1, "Priority"))
+ client->order = atoi(value);
+ else if (! strcmp(p + 1, "RestartCommand"))
+ gnome_config_make_vector(value, &client->argc, &client->argv);
+ }
+
+ g_free(key);
+ g_free(value);
+ }
+
+ g_free(handle);
+ gnome_config_pop_prefix();
+
+ return g_slist_sort(list, mn_conf_startup_client_compare);
+}
+
+static void
+mn_conf_startup_list_write (GSList *list, const char *name)
+{
+ char *prefix;
+ int i = 0;
+ GSList *l;
+
+ g_return_if_fail(name != NULL);
+
+ gnome_config_push_prefix(SESSION_MANUAL_CONFIG_PREFIX);
+ gnome_config_clean_section(name);
+ gnome_config_pop_prefix();
+
+ prefix = g_strconcat(SESSION_MANUAL_CONFIG_PREFIX, name, "/", NULL);
+ gnome_config_push_prefix(prefix);
+ g_free(prefix);
+
+ gnome_config_set_int("num_clients", g_slist_length(list));
+
+ MN_LIST_FOREACH(l, list)
+ {
+ StartupClient *client = l->data;
+ char *key;
+
+ key = g_strdup_printf("%d,%s", i, "RestartStyleHint");
+ gnome_config_set_int(key, 3); /* RestartNever */
+ g_free(key);
+
+ key = g_strdup_printf("%d,%s", i, "Priority");
+ gnome_config_set_int(key, client->order);
+ g_free(key);
+
+ key = g_strdup_printf("%d,%s", i, "RestartCommand");
+ gnome_config_set_vector(key, client->argc, (const char * const *) client->argv);
+ g_free(key);
+
+ i++;
+ }
+
+ gnome_config_pop_prefix();
+ gnome_config_sync();
+}
+
+static GSList *
+mn_conf_get_autostart_elem (GSList *list)
+{
+ GSList *l;
+
+ MN_LIST_FOREACH(l, list)
+ {
+ StartupClient *client = l->data;
+
+ if (client->argc > 0 && ! strcmp(client->argv[0], "mail-notification"))
+ return l;
+ }
+
+ return NULL;
+}
+
+gboolean
+mn_conf_get_autostart (void)
+{
+ GSList *clients;
+ gboolean autostart;
+
+ clients = mn_conf_startup_list_read(SESSION_MANUAL_NAME);
+ autostart = mn_conf_get_autostart_elem(clients) != NULL;
+ mn_conf_startup_clients_free(clients);
+
+ return autostart;
+}
+
+void
+mn_conf_set_autostart (gboolean autostart)
+{
+ GSList *clients;
+ GSList *elem;
+
+ clients = mn_conf_startup_list_read(SESSION_MANUAL_NAME);
+ elem = mn_conf_get_autostart_elem(clients);
+ if ((elem != NULL) != autostart)
+ {
+ if (autostart)
+ {
+ StartupClient *client;
+
+ client = g_new0(StartupClient, 1);
+ client->order = 50;
+ gnome_config_make_vector("mail-notification", &client->argc, &client->argv);
+
+ clients = g_slist_append(clients, client);
+ clients = g_slist_sort(clients, mn_conf_startup_client_compare);
+ }
+ else
+ clients = mn_g_slist_delete_link_deep_custom(clients, elem, (GFunc) mn_conf_startup_client_free, NULL);
+
+ mn_conf_startup_list_write(clients, SESSION_MANUAL_NAME);
+ }
+ mn_conf_startup_clients_free(clients);
+}
diff --git a/src/mn-conf.h b/src/mn-conf.h
@@ -22,33 +22,77 @@
#include <stdarg.h>
#include <eel/eel.h>
-#define MN_CONF_NAMESPACE "/apps/mail-notification"
-#define MN_CONF_LOCAL_NAMESPACE MN_CONF_NAMESPACE "/local" /* obsolete */
-#define MN_CONF_LOCAL_ENABLED MN_CONF_LOCAL_NAMESPACE "/enabled" /* obsolete */
-#define MN_CONF_LOCAL_DELAY_MINUTES MN_CONF_LOCAL_NAMESPACE "/delay/minutes" /* obsolete */
-#define MN_CONF_LOCAL_DELAY_SECONDS MN_CONF_LOCAL_NAMESPACE "/delay/seconds" /* obsolete */
-#define MN_CONF_REMOTE_NAMESPACE MN_CONF_NAMESPACE "/remote" /* obsolete */
-#define MN_CONF_REMOTE_ENABLED MN_CONF_REMOTE_NAMESPACE "/enabled" /* obsolete */
-#define MN_CONF_REMOTE_DELAY_MINUTES MN_CONF_REMOTE_NAMESPACE "/delay/minutes" /* obsolete */
-#define MN_CONF_REMOTE_DELAY_SECONDS MN_CONF_REMOTE_NAMESPACE "/delay/seconds" /* obsolete */
-#define MN_CONF_DELAY_NAMESPACE MN_CONF_NAMESPACE "/delay"
-#define MN_CONF_DELAY_MINUTES MN_CONF_DELAY_NAMESPACE "/minutes"
-#define MN_CONF_DELAY_SECONDS MN_CONF_DELAY_NAMESPACE "/seconds"
-#define MN_CONF_COMMANDS_NEW_MAIL_ENABLED MN_CONF_NAMESPACE "/commands/new-mail/enabled"
-#define MN_CONF_COMMANDS_NEW_MAIL_COMMAND MN_CONF_NAMESPACE "/commands/new-mail/command"
-#define MN_CONF_COMMANDS_CLICKED_ENABLED MN_CONF_NAMESPACE "/commands/clicked/enabled" /* obsolete */
-#define MN_CONF_COMMANDS_CLICKED_COMMAND MN_CONF_NAMESPACE "/commands/clicked/command" /* obsolete */
-#define MN_CONF_COMMANDS_DOUBLE_CLICKED_ENABLED MN_CONF_NAMESPACE "/commands/double-clicked/enabled"
-#define MN_CONF_COMMANDS_DOUBLE_CLICKED_COMMAND MN_CONF_NAMESPACE "/commands/double-clicked/command"
-#define MN_CONF_MAILBOXES MN_CONF_NAMESPACE "/mailboxes"
-#define MN_CONF_UI_NAMESPACE MN_CONF_NAMESPACE "/ui"
-#define MN_CONF_PREFERENCES_DIALOG MN_CONF_UI_NAMESPACE "/preferences-dialog" /* obsolete */
-#define MN_CONF_PROPERTIES_DIALOG MN_CONF_UI_NAMESPACE "/properties-dialog"
-#define MN_CONF_ALREADY_RUN MN_CONF_NAMESPACE "/already-run"
+#define MN_CONF_NAMESPACE \
+ "/apps/mail-notification"
+#define MN_CONF_LOCAL_NAMESPACE \
+ MN_CONF_NAMESPACE "/local" /* obsolete */
+#define MN_CONF_LOCAL_ENABLED \
+ MN_CONF_LOCAL_NAMESPACE "/enabled" /* obsolete */
+#define MN_CONF_LOCAL_DELAY_MINUTES \
+ MN_CONF_LOCAL_NAMESPACE "/delay/minutes" /* obsolete */
+#define MN_CONF_LOCAL_DELAY_SECONDS \
+ MN_CONF_LOCAL_NAMESPACE "/delay/seconds" /* obsolete */
+#define MN_CONF_REMOTE_NAMESPACE \
+ MN_CONF_NAMESPACE "/remote" /* obsolete */
+#define MN_CONF_REMOTE_ENABLED \
+ MN_CONF_REMOTE_NAMESPACE "/enabled" /* obsolete */
+#define MN_CONF_REMOTE_DELAY_MINUTES \
+ MN_CONF_REMOTE_NAMESPACE "/delay/minutes" /* obsolete */
+#define MN_CONF_REMOTE_DELAY_SECONDS \
+ MN_CONF_REMOTE_NAMESPACE "/delay/seconds" /* obsolete */
+#define MN_CONF_DELAY_NAMESPACE \
+ MN_CONF_NAMESPACE "/delay"
+#define MN_CONF_DELAY_MINUTES \
+ MN_CONF_DELAY_NAMESPACE "/minutes"
+#define MN_CONF_DELAY_SECONDS \
+ MN_CONF_DELAY_NAMESPACE "/seconds"
+#define MN_CONF_COMMANDS_NAMESPACE \
+ MN_CONF_NAMESPACE "/commands"
+#define MN_CONF_COMMANDS_NEW_MAIL_NAMESPACE \
+ MN_CONF_COMMANDS_NAMESPACE "/new-mail"
+#define MN_CONF_COMMANDS_NEW_MAIL_ENABLED \
+ MN_CONF_COMMANDS_NEW_MAIL_NAMESPACE "/enabled"
+#define MN_CONF_COMMANDS_NEW_MAIL_COMMAND \
+ MN_CONF_COMMANDS_NEW_MAIL_NAMESPACE "/command"
+#define MN_CONF_COMMANDS_CLICKED_NAMESPACE \
+ MN_CONF_COMMANDS_NAMESPACE "/clicked" /* obsolete */
+#define MN_CONF_COMMANDS_CLICKED_ENABLED \
+ MN_CONF_COMMANDS_CLICKED_NAMESPACE "/enabled" /* obsolete */
+#define MN_CONF_COMMANDS_CLICKED_COMMAND \
+ MN_CONF_COMMANDS_CLICKED_NAMESPACE "/command" /* obsolete */
+#define MN_CONF_COMMANDS_DOUBLE_CLICKED_NAMESPACE \
+ MN_CONF_COMMANDS_NAMESPACE "/double-clicked"
+#define MN_CONF_COMMANDS_DOUBLE_CLICKED_ENABLED \
+ MN_CONF_COMMANDS_DOUBLE_CLICKED_NAMESPACE "/enabled"
+#define MN_CONF_COMMANDS_DOUBLE_CLICKED_COMMAND \
+ MN_CONF_COMMANDS_DOUBLE_CLICKED_NAMESPACE "/command"
+#define MN_CONF_MAILBOXES \
+ MN_CONF_NAMESPACE "/mailboxes"
+#define MN_CONF_UI_NAMESPACE \
+ MN_CONF_NAMESPACE "/ui"
+#define MN_CONF_PREFERENCES_DIALOG \
+ MN_CONF_UI_NAMESPACE "/preferences-dialog" /* obsolete */
+#define MN_CONF_PROPERTIES_DIALOG \
+ MN_CONF_UI_NAMESPACE "/properties-dialog"
+#define MN_CONF_ALREADY_RUN \
+ MN_CONF_NAMESPACE "/already-run"
+#define MN_CONF_BLINK_ON_ERRORS \
+ MN_CONF_NAMESPACE "/blink-on-errors"
+#define MN_CONF_TRUSTED_X509_CERTIFICATES \
+ MN_CONF_NAMESPACE "/trusted-x509-certificates"
+#define MN_CONF_TRUSTED_SERVERS \
+ MN_CONF_NAMESPACE "/trusted-servers"
void mn_conf_init (void);
+void mn_conf_unset_obsolete (void);
+
+void mn_conf_recursive_unset (const char *key,
+ GConfUnsetFlags flags);
void mn_conf_link (GtkWidget *widget,
...);
+gboolean mn_conf_get_autostart (void);
+void mn_conf_set_autostart (gboolean autostart);
+
#endif /* _MN_CONF_H */
diff --git a/src/mn-dialog.c b/src/mn-dialog.c
@@ -1,112 +0,0 @@
-/*
- * Copyright (c) 2003, 2004 Jean-Yves Lefort <jylefort@brutele.be>
- *
- * 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.
- */
-
-#include "config.h"
-#include <stdarg.h>
-#include <stdlib.h>
-#include <glib/gi18n-lib.h>
-#include <gtk/gtk.h>
-#include "mn-util.h"
-
-/*** implementation **********************************************************/
-
-/*
- * Displays an HIG-compliant modal dialog.
- *
- * Actually, it won't fully comply to the HIG because of
- * http://bugzilla.gnome.org/show_bug.cgi?id=98779.
- */
-void
-mn_error_dialog (const char *help_link_id,
- const char *primary,
- const char *format,
- ...)
-{
- GtkWidget *dialog;
- GtkWidget *label;
- char *secondary = NULL;
- GString *message;
- char *escaped;
-
- mn_create_interface("dialog",
- "dialog", &dialog,
- "label", &label,
- NULL);
-
- gtk_window_set_title(GTK_WINDOW(dialog), "");
-
- if (help_link_id != NULL)
- gtk_dialog_add_button(GTK_DIALOG(dialog), GTK_STOCK_HELP, GTK_RESPONSE_HELP);
- gtk_dialog_add_button(GTK_DIALOG(dialog), GTK_STOCK_OK, GTK_RESPONSE_OK);
-
- message = g_string_new(NULL);
-
- if (format)
- {
- va_list args;
-
- va_start(args, format);
- secondary = g_strdup_vprintf(format, args);
- va_end(args);
- }
-
- if (primary)
- {
- escaped = g_markup_printf_escaped("<span weight=\"bold\" size=\"larger\">%s</span>", primary);
- g_string_append(message, escaped);
- g_free(escaped);
- }
-
- if (secondary)
- {
- if (primary)
- g_string_append(message, "\n\n");
-
- escaped = g_markup_escape_text(secondary, -1);
- g_free(secondary);
-
- g_string_append(message, escaped);
- g_free(escaped);
- }
-
- gtk_label_set_markup(GTK_LABEL(label), message->str);
- g_string_free(message, TRUE);
-
- while (gtk_dialog_run(GTK_DIALOG(dialog)) == GTK_RESPONSE_HELP)
- mn_display_help(help_link_id);
-
- gtk_widget_destroy(dialog);
-}
-
-void
-mn_fatal_error_dialog (const char *format, ...)
-{
- va_list args;
- char *secondary;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
- secondary = g_strdup_vprintf(format, args);
- va_end(args);
-
- mn_error_dialog(NULL, _("A fatal error has occurred in Mail Notification"), "%s", secondary);
- g_free(secondary);
-
- exit(1);
-}
diff --git a/src/mn-dialog.h b/src/mn-dialog.h
@@ -1,31 +0,0 @@
-/*
- * Copyright (c) 2003 Jean-Yves Lefort <jylefort@brutele.be>
- *
- * 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.
- */
-
-#ifndef _MN_DIALOG_H
-#define _MN_DIALOG_H
-
-#include <stdarg.h>
-
-void mn_error_dialog (const char *help_link_id,
- const char *primary,
- const char *format,
- ...);
-void mn_fatal_error_dialog (const char *format,
- ...);
-
-#endif /* _MN_DIALOG_H */
diff --git a/src/mn-gmail-mailbox-private.h b/src/mn-gmail-mailbox-private.h
@@ -10,15 +10,11 @@ extern "C" {
#endif /* __cplusplus */
struct _MNGmailMailboxPrivate {
-#line 38 "mn-gmail-mailbox.gob"
- char * username;
-#line 39 "mn-gmail-mailbox.gob"
- char * password;
-#line 40 "mn-gmail-mailbox.gob"
+#line 37 "mn-gmail-mailbox.gob"
GHashTable * cookies;
-#line 41 "mn-gmail-mailbox.gob"
+#line 38 "mn-gmail-mailbox.gob"
gboolean logged_in;
-#line 22 "mn-gmail-mailbox-private.h"
+#line 18 "mn-gmail-mailbox-private.h"
};
#ifdef __cplusplus
diff --git a/src/mn-gmail-mailbox-properties-private.h b/src/mn-gmail-mailbox-properties-private.h
@@ -10,13 +10,13 @@ extern "C" {
#endif /* __cplusplus */
struct _MNGmailMailboxPropertiesPrivate {
-#line 36 "mn-gmail-mailbox-properties.gob"
+#line 35 "mn-gmail-mailbox-properties.gob"
GtkSizeGroup * size_group;
-#line 51 "mn-gmail-mailbox-properties.gob"
+#line 50 "mn-gmail-mailbox-properties.gob"
GtkWidget * username_entry;
-#line 52 "mn-gmail-mailbox-properties.gob"
+#line 51 "mn-gmail-mailbox-properties.gob"
GtkWidget * password_entry;
-#line 53 "mn-gmail-mailbox-properties.gob"
+#line 52 "mn-gmail-mailbox-properties.gob"
GtkTooltips * tooltips;
#line 22 "mn-gmail-mailbox-properties-private.h"
};
diff --git a/src/mn-gmail-mailbox-properties.c b/src/mn-gmail-mailbox-properties.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -27,10 +27,9 @@
#include <glib/gi18n-lib.h>
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
-#include "mn-uri.h"
#include "mn-util.h"
-#line 34 "mn-gmail-mailbox-properties.c"
+#line 33 "mn-gmail-mailbox-properties.c"
/* self casting macros */
#define SELF(x) MN_GMAIL_MAILBOX_PROPERTIES(x)
#define SELF_CONST(x) MN_GMAIL_MAILBOX_PROPERTIES_CONST(x)
@@ -51,8 +50,8 @@ static void mn_gmail_mailbox_properties_init (MNGmailMailboxProperties * o) G_GN
static void mn_gmail_mailbox_properties_class_init (MNGmailMailboxPropertiesClass * c) G_GNUC_UNUSED;
static GObject * ___1_mn_gmail_mailbox_properties_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_params) G_GNUC_UNUSED;
static void mn_gmail_mailbox_properties_entry_changed_h (GtkEditable * editable, gpointer user_data) G_GNUC_UNUSED;
-static gboolean mn_gmail_mailbox_properties_set_uri (MNMailboxProperties * self, const char * uri) G_GNUC_UNUSED;
-static char * mn_gmail_mailbox_properties_get_uri (MNMailboxProperties * self) G_GNUC_UNUSED;
+static gboolean mn_gmail_mailbox_properties_set_uri (MNMailboxProperties * self, MNURI * uri) G_GNUC_UNUSED;
+static MNURI * mn_gmail_mailbox_properties_get_uri (MNMailboxProperties * self) G_GNUC_UNUSED;
enum {
PROP_0,
@@ -73,11 +72,11 @@ static GtkVBoxClass *parent_class = NULL;
static void
___MN_Mailbox_Properties_init (MNMailboxPropertiesIface *iface)
{
-#line 100 "mn-gmail-mailbox-properties.gob"
+#line 99 "mn-gmail-mailbox-properties.gob"
iface->set_uri = self_set_uri;
-#line 121 "mn-gmail-mailbox-properties.gob"
+#line 114 "mn-gmail-mailbox-properties.gob"
iface->get_uri = self_get_uri;
-#line 81 "mn-gmail-mailbox-properties.c"
+#line 80 "mn-gmail-mailbox-properties.c"
}
GType
@@ -139,12 +138,12 @@ ___dispose (GObject *obj_self)
MNGmailMailboxProperties *self G_GNUC_UNUSED = MN_GMAIL_MAILBOX_PROPERTIES (obj_self);
if (G_OBJECT_CLASS (parent_class)->dispose) \
(* G_OBJECT_CLASS (parent_class)->dispose) (obj_self);
-#line 36 "mn-gmail-mailbox-properties.gob"
+#line 35 "mn-gmail-mailbox-properties.gob"
if(self->_priv->size_group) { ((*(void (*)(void *))g_object_unref)) (self->_priv->size_group); self->_priv->size_group = NULL; }
-#line 145 "mn-gmail-mailbox-properties.c"
-#line 53 "mn-gmail-mailbox-properties.gob"
+#line 144 "mn-gmail-mailbox-properties.c"
+#line 52 "mn-gmail-mailbox-properties.gob"
if(self->_priv->tooltips) { ((*(void (*)(void *))g_object_unref)) (self->_priv->tooltips); self->_priv->tooltips = NULL; }
-#line 148 "mn-gmail-mailbox-properties.c"
+#line 147 "mn-gmail-mailbox-properties.c"
}
#undef __GOB_FUNCTION__
@@ -166,9 +165,9 @@ mn_gmail_mailbox_properties_init (MNGmailMailboxProperties * o G_GNUC_UNUSED)
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox:Properties::init"
o->_priv = g_new0 (MNGmailMailboxPropertiesPrivate, 1);
-#line 53 "mn-gmail-mailbox-properties.gob"
+#line 52 "mn-gmail-mailbox-properties.gob"
o->_priv->tooltips = mn_tooltips_new();
-#line 172 "mn-gmail-mailbox-properties.c"
+#line 171 "mn-gmail-mailbox-properties.c"
}
#undef __GOB_FUNCTION__
static void
@@ -179,9 +178,9 @@ mn_gmail_mailbox_properties_class_init (MNGmailMailboxPropertiesClass * c G_GNUC
parent_class = g_type_class_ref (GTK_TYPE_VBOX);
-#line 55 "mn-gmail-mailbox-properties.gob"
+#line 54 "mn-gmail-mailbox-properties.gob"
g_object_class->constructor = ___1_mn_gmail_mailbox_properties_constructor;
-#line 185 "mn-gmail-mailbox-properties.c"
+#line 184 "mn-gmail-mailbox-properties.c"
g_object_class->dispose = ___dispose;
g_object_class->finalize = ___finalize;
g_object_class->get_property = ___object_get_property;
@@ -214,9 +213,9 @@ ___object_set_property (GObject *object,
switch (property_id) {
case PROP_SIZE_GROUP:
{
-#line 37 "mn-gmail-mailbox-properties.gob"
+#line 36 "mn-gmail-mailbox-properties.gob"
{ GObject *___old = (GObject *)self->_priv->size_group; self->_priv->size_group = (void *)g_value_dup_object (VAL); if (___old != NULL) { g_object_unref (G_OBJECT (___old)); } }
-#line 220 "mn-gmail-mailbox-properties.c"
+#line 219 "mn-gmail-mailbox-properties.c"
}
break;
default:
@@ -245,21 +244,21 @@ ___object_get_property (GObject *object,
switch (property_id) {
case PROP_LABEL:
{
-#line 34 "mn-gmail-mailbox-properties.gob"
+#line 33 "mn-gmail-mailbox-properties.gob"
g_value_set_string(VAL, "Gmail");
-#line 251 "mn-gmail-mailbox-properties.c"
+#line 250 "mn-gmail-mailbox-properties.c"
}
break;
case PROP_SIZE_GROUP:
{
-#line 37 "mn-gmail-mailbox-properties.gob"
+#line 36 "mn-gmail-mailbox-properties.gob"
g_value_set_object (VAL, (gpointer)self->_priv->size_group);
-#line 258 "mn-gmail-mailbox-properties.c"
+#line 257 "mn-gmail-mailbox-properties.c"
}
break;
case PROP_COMPLETE:
{
-#line 41 "mn-gmail-mailbox-properties.gob"
+#line 40 "mn-gmail-mailbox-properties.gob"
const char *username;
const char *password;
@@ -269,7 +268,7 @@ g_value_set_object (VAL, (gpointer)self->_priv->size_group);
g_value_set_boolean(VAL, *username && *password);
-#line 273 "mn-gmail-mailbox-properties.c"
+#line 272 "mn-gmail-mailbox-properties.c"
}
break;
default:
@@ -286,10 +285,10 @@ g_value_set_object (VAL, (gpointer)self->_priv->size_group);
-#line 55 "mn-gmail-mailbox-properties.gob"
+#line 54 "mn-gmail-mailbox-properties.gob"
static GObject *
___1_mn_gmail_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_construct_properties, GObjectConstructParam * construct_params)
-#line 293 "mn-gmail-mailbox-properties.c"
+#line 292 "mn-gmail-mailbox-properties.c"
#define PARENT_HANDLER(___type,___n_construct_properties,___construct_params) \
((G_OBJECT_CLASS(parent_class)->constructor)? \
(* G_OBJECT_CLASS(parent_class)->constructor)(___type,___n_construct_properties,___construct_params): \
@@ -297,7 +296,7 @@ ___1_mn_gmail_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox:Properties::constructor"
{
-#line 57 "mn-gmail-mailbox-properties.gob"
+#line 56 "mn-gmail-mailbox-properties.gob"
GObject *object;
Self *self;
@@ -332,80 +331,76 @@ ___1_mn_gmail_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_
return object;
}}
-#line 336 "mn-gmail-mailbox-properties.c"
+#line 335 "mn-gmail-mailbox-properties.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 92 "mn-gmail-mailbox-properties.gob"
+#line 91 "mn-gmail-mailbox-properties.gob"
static void
mn_gmail_mailbox_properties_entry_changed_h (GtkEditable * editable, gpointer user_data)
-#line 343 "mn-gmail-mailbox-properties.c"
+#line 342 "mn-gmail-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox:Properties::entry_changed_h"
-#line 92 "mn-gmail-mailbox-properties.gob"
+#line 91 "mn-gmail-mailbox-properties.gob"
g_return_if_fail (editable != NULL);
-#line 92 "mn-gmail-mailbox-properties.gob"
+#line 91 "mn-gmail-mailbox-properties.gob"
g_return_if_fail (GTK_IS_EDITABLE (editable));
-#line 92 "mn-gmail-mailbox-properties.gob"
+#line 91 "mn-gmail-mailbox-properties.gob"
g_return_if_fail (user_data != NULL);
-#line 352 "mn-gmail-mailbox-properties.c"
+#line 351 "mn-gmail-mailbox-properties.c"
{
-#line 95 "mn-gmail-mailbox-properties.gob"
+#line 94 "mn-gmail-mailbox-properties.gob"
Self *self = user_data;
g_object_notify(G_OBJECT(self), "complete");
}}
-#line 359 "mn-gmail-mailbox-properties.c"
+#line 358 "mn-gmail-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 100 "mn-gmail-mailbox-properties.gob"
+#line 99 "mn-gmail-mailbox-properties.gob"
static gboolean
-mn_gmail_mailbox_properties_set_uri (MNMailboxProperties * self, const char * uri)
-#line 365 "mn-gmail-mailbox-properties.c"
+mn_gmail_mailbox_properties_set_uri (MNMailboxProperties * self, MNURI * uri)
+#line 364 "mn-gmail-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox:Properties::set_uri"
-#line 100 "mn-gmail-mailbox-properties.gob"
+#line 99 "mn-gmail-mailbox-properties.gob"
g_return_val_if_fail (self != NULL, (gboolean )0);
-#line 100 "mn-gmail-mailbox-properties.gob"
+#line 99 "mn-gmail-mailbox-properties.gob"
g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (gboolean )0);
-#line 100 "mn-gmail-mailbox-properties.gob"
+#line 99 "mn-gmail-mailbox-properties.gob"
g_return_val_if_fail (uri != NULL, (gboolean )0);
-#line 374 "mn-gmail-mailbox-properties.c"
+#line 99 "mn-gmail-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_URI (uri), (gboolean )0);
+#line 375 "mn-gmail-mailbox-properties.c"
{
-#line 103 "mn-gmail-mailbox-properties.gob"
+#line 102 "mn-gmail-mailbox-properties.gob"
- char *username;
- char *password;
-
- if (mn_uri_parse_gmail(uri, &username, &password))
+ if (MN_URI_IS_GMAIL(uri))
{
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->username_entry), username);
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->password_entry), password);
-
- g_free(username);
- g_free(password);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->username_entry), uri->username);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->password_entry), uri->password);
return TRUE;
}
else
return FALSE;
}}
-#line 394 "mn-gmail-mailbox-properties.c"
+#line 389 "mn-gmail-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 121 "mn-gmail-mailbox-properties.gob"
-static char *
+#line 114 "mn-gmail-mailbox-properties.gob"
+static MNURI *
mn_gmail_mailbox_properties_get_uri (MNMailboxProperties * self)
-#line 400 "mn-gmail-mailbox-properties.c"
+#line 395 "mn-gmail-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox:Properties::get_uri"
-#line 121 "mn-gmail-mailbox-properties.gob"
- g_return_val_if_fail (self != NULL, (char * )0);
-#line 121 "mn-gmail-mailbox-properties.gob"
- g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (char * )0);
-#line 407 "mn-gmail-mailbox-properties.c"
+#line 114 "mn-gmail-mailbox-properties.gob"
+ g_return_val_if_fail (self != NULL, (MNURI * )0);
+#line 114 "mn-gmail-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (self), (MNURI * )0);
+#line 402 "mn-gmail-mailbox-properties.c"
{
-#line 123 "mn-gmail-mailbox-properties.gob"
+#line 116 "mn-gmail-mailbox-properties.gob"
const char *username;
const char *password;
@@ -413,7 +408,7 @@ mn_gmail_mailbox_properties_get_uri (MNMailboxProperties * self)
username = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->username_entry));
password = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->password_entry));
- return mn_uri_build_gmail(username, password);
+ return mn_uri_new_gmail(username, password);
}}
-#line 419 "mn-gmail-mailbox-properties.c"
+#line 414 "mn-gmail-mailbox-properties.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-gmail-mailbox-properties.gob b/src/mn-gmail-mailbox-properties.gob
@@ -24,7 +24,6 @@
#include <glib/gi18n-lib.h>
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
-#include "mn-uri.h"
#include "mn-util.h"
%}
@@ -99,18 +98,12 @@ class MN:Gmail:Mailbox:Properties from Gtk:VBox (interface MN:Mailbox:Properties
interface MN:Mailbox:Properties private gboolean
set_uri (MN:Mailbox:Properties *self (check null type),
- const char *uri (check null))
+ MN:URI *uri (check null type))
{
- char *username;
- char *password;
-
- if (mn_uri_parse_gmail(uri, &username, &password))
+ if (MN_URI_IS_GMAIL(uri))
{
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->username_entry), username);
- gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->password_entry), password);
-
- g_free(username);
- g_free(password);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->username_entry), uri->username);
+ gtk_entry_set_text(GTK_ENTRY(SELF(self)->_priv->password_entry), uri->password);
return TRUE;
}
@@ -118,7 +111,7 @@ class MN:Gmail:Mailbox:Properties from Gtk:VBox (interface MN:Mailbox:Properties
return FALSE;
}
- interface MN:Mailbox:Properties private char *
+ interface MN:Mailbox:Properties private MNURI *
get_uri (MN:Mailbox:Properties *self (check null type))
{
const char *username;
@@ -127,6 +120,6 @@ class MN:Gmail:Mailbox:Properties from Gtk:VBox (interface MN:Mailbox:Properties
username = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->username_entry));
password = gtk_entry_get_text(GTK_ENTRY(SELF(self)->_priv->password_entry));
- return mn_uri_build_gmail(username, password);
+ return mn_uri_new_gmail(username, password);
}
}
diff --git a/src/mn-gmail-mailbox.c b/src/mn-gmail-mailbox.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -30,12 +30,11 @@
#include <libgnomevfs/gnome-vfs-utils.h>
#include <libsoup/soup.h>
#include "mn-mailbox-private.h"
-#include "mn-uri.h"
#include "mn-util.h"
#include "mn-stock.h"
#include "mn-soup.h"
-#line 39 "mn-gmail-mailbox.c"
+#line 38 "mn-gmail-mailbox.c"
/* self casting macros */
#define SELF(x) MN_GMAIL_MAILBOX(x)
#define SELF_CONST(x) MN_GMAIL_MAILBOX_CONST(x)
@@ -54,9 +53,13 @@ static void mn_gmail_mailbox_init (MNGmailMailbox * o) G_GNUC_UNUSED;
static void mn_gmail_mailbox_class_init (MNGmailMailboxClass * class) G_GNUC_UNUSED;
static GObject * ___2_mn_gmail_mailbox_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_params) G_GNUC_UNUSED;
static void ___3_mn_gmail_mailbox_finalize (GObject * object) G_GNUC_UNUSED;
-static gboolean ___4_mn_gmail_mailbox_impl_is (MNMailbox * dummy, const char * uri) G_GNUC_UNUSED;
+static gboolean ___4_mn_gmail_mailbox_impl_is (MNMailbox * dummy, MNURI * uri) G_GNUC_UNUSED;
static void ___5_mn_gmail_mailbox_impl_check (MNMailbox * mailbox) G_GNUC_UNUSED;
static void mn_gmail_mailbox_get (MNGmailMailbox * self, const char * uri, SoupCallbackFn callback) G_GNUC_UNUSED;
+static void mn_gmail_mailbox_dump_request (MNGmailMailbox * self, SoupMessage * message) G_GNUC_UNUSED;
+static void mn_gmail_mailbox_dump_request_cb (gpointer key, gpointer value, gpointer user_data) G_GNUC_UNUSED;
+static void mn_gmail_mailbox_dump_response (MNGmailMailbox * self, SoupMessage * message) G_GNUC_UNUSED;
+static void mn_gmail_mailbox_dump_response_cb (gpointer key, gpointer value, gpointer user_data) G_GNUC_UNUSED;
static char * mn_gmail_mailbox_get_token (const char * str, const char * pre, const char * post, gboolean include_pre, gboolean include_post) G_GNUC_UNUSED;
static void mn_gmail_mailbox_login (MNGmailMailbox * self) G_GNUC_UNUSED;
static void mn_gmail_mailbox_login_cb1 (SoupMessage * message, gpointer user_data) G_GNUC_UNUSED;
@@ -74,6 +77,10 @@ static MNMailboxClass *parent_class = NULL;
/* Short form macros */
#define self_get mn_gmail_mailbox_get
+#define self_dump_request mn_gmail_mailbox_dump_request
+#define self_dump_request_cb mn_gmail_mailbox_dump_request_cb
+#define self_dump_response mn_gmail_mailbox_dump_response
+#define self_dump_response_cb mn_gmail_mailbox_dump_response_cb
#define self_get_token mn_gmail_mailbox_get_token
#define self_login mn_gmail_mailbox_login
#define self_login_cb1 mn_gmail_mailbox_login_cb1
@@ -134,18 +141,12 @@ ___finalize(GObject *obj_self)
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::finalize"
MNGmailMailbox *self G_GNUC_UNUSED = MN_GMAIL_MAILBOX (obj_self);
gpointer priv = self->_priv;
-#line 70 "mn-gmail-mailbox.gob"
+#line 58 "mn-gmail-mailbox.gob"
___3_mn_gmail_mailbox_finalize(obj_self);
-#line 140 "mn-gmail-mailbox.c"
-#line 38 "mn-gmail-mailbox.gob"
- if(self->_priv->username) { ((*(void (*)(void *))g_free)) (self->_priv->username); self->_priv->username = NULL; }
-#line 143 "mn-gmail-mailbox.c"
-#line 39 "mn-gmail-mailbox.gob"
- if(self->_priv->password) { ((*(void (*)(void *))g_free)) (self->_priv->password); self->_priv->password = NULL; }
-#line 146 "mn-gmail-mailbox.c"
-#line 40 "mn-gmail-mailbox.gob"
+#line 147 "mn-gmail-mailbox.c"
+#line 37 "mn-gmail-mailbox.gob"
if(self->_priv->cookies) { ((*(void (*)(void *))g_hash_table_destroy)) (self->_priv->cookies); self->_priv->cookies = NULL; }
-#line 149 "mn-gmail-mailbox.c"
+#line 150 "mn-gmail-mailbox.c"
g_free (priv);
}
#undef __GOB_FUNCTION__
@@ -157,10 +158,10 @@ mn_gmail_mailbox_init (MNGmailMailbox * o G_GNUC_UNUSED)
o->_priv = g_new0 (MNGmailMailboxPrivate, 1);
}
#undef __GOB_FUNCTION__
-#line 43 "mn-gmail-mailbox.gob"
+#line 40 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_class_init (MNGmailMailboxClass * class G_GNUC_UNUSED)
-#line 164 "mn-gmail-mailbox.c"
+#line 165 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::class_init"
GObjectClass *g_object_class G_GNUC_UNUSED = (GObjectClass*) class;
@@ -168,32 +169,32 @@ mn_gmail_mailbox_class_init (MNGmailMailboxClass * class G_GNUC_UNUSED)
parent_class = g_type_class_ref (MN_TYPE_MAILBOX);
-#line 49 "mn-gmail-mailbox.gob"
+#line 46 "mn-gmail-mailbox.gob"
g_object_class->constructor = ___2_mn_gmail_mailbox_constructor;
-#line 70 "mn-gmail-mailbox.gob"
+#line 58 "mn-gmail-mailbox.gob"
g_object_class->finalize = ___finalize;
-#line 77 "mn-gmail-mailbox.gob"
+#line 65 "mn-gmail-mailbox.gob"
mn_mailbox_class->impl_is = ___4_mn_gmail_mailbox_impl_is;
-#line 90 "mn-gmail-mailbox.gob"
+#line 71 "mn-gmail-mailbox.gob"
mn_mailbox_class->impl_check = ___5_mn_gmail_mailbox_impl_check;
-#line 180 "mn-gmail-mailbox.c"
+#line 181 "mn-gmail-mailbox.c"
{
-#line 44 "mn-gmail-mailbox.gob"
+#line 41 "mn-gmail-mailbox.gob"
MN_MAILBOX_CLASS(class)->stock_id = MN_STOCK_GMAIL;
MN_MAILBOX_CLASS(class)->format = "Gmail";
-#line 187 "mn-gmail-mailbox.c"
+#line 188 "mn-gmail-mailbox.c"
}
}
#undef __GOB_FUNCTION__
-#line 49 "mn-gmail-mailbox.gob"
+#line 46 "mn-gmail-mailbox.gob"
static GObject *
___2_mn_gmail_mailbox_constructor (GType type G_GNUC_UNUSED, guint n_construct_properties, GObjectConstructParam * construct_params)
-#line 197 "mn-gmail-mailbox.c"
+#line 198 "mn-gmail-mailbox.c"
#define PARENT_HANDLER(___type,___n_construct_properties,___construct_params) \
((G_OBJECT_CLASS(parent_class)->constructor)? \
(* G_OBJECT_CLASS(parent_class)->constructor)(___type,___n_construct_properties,___construct_params): \
@@ -201,93 +202,79 @@ ___2_mn_gmail_mailbox_constructor (GType type G_GNUC_UNUSED, guint n_construct_p
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::constructor"
{
-#line 51 "mn-gmail-mailbox.gob"
+#line 48 "mn-gmail-mailbox.gob"
GObject *object;
- MNMailbox *mailbox;
- Self *self;
object = PARENT_HANDLER(type, n_construct_properties, construct_params);
- mailbox = MN_MAILBOX(object);
- self = SELF(object);
mn_soup_use();
- if (! mn_uri_parse_gmail(mn_mailbox_get_uri(mailbox),
- &selfp->username,
- &selfp->password))
- mn_mailbox_set_init_error(mailbox, _("unable to parse Gmail URI"));
-
return object;
}}
-#line 224 "mn-gmail-mailbox.c"
+#line 216 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 70 "mn-gmail-mailbox.gob"
+#line 58 "mn-gmail-mailbox.gob"
static void
___3_mn_gmail_mailbox_finalize (GObject * object G_GNUC_UNUSED)
-#line 231 "mn-gmail-mailbox.c"
+#line 223 "mn-gmail-mailbox.c"
#define PARENT_HANDLER(___object) \
{ if(G_OBJECT_CLASS(parent_class)->finalize) \
(* G_OBJECT_CLASS(parent_class)->finalize)(___object); }
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::finalize"
{
-#line 72 "mn-gmail-mailbox.gob"
+#line 60 "mn-gmail-mailbox.gob"
mn_soup_unuse();
PARENT_HANDLER(object);
}}
-#line 243 "mn-gmail-mailbox.c"
+#line 235 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 77 "mn-gmail-mailbox.gob"
+#line 65 "mn-gmail-mailbox.gob"
static gboolean
-___4_mn_gmail_mailbox_impl_is (MNMailbox * dummy G_GNUC_UNUSED, const char * uri)
-#line 250 "mn-gmail-mailbox.c"
+___4_mn_gmail_mailbox_impl_is (MNMailbox * dummy G_GNUC_UNUSED, MNURI * uri)
+#line 242 "mn-gmail-mailbox.c"
#define PARENT_HANDLER(___dummy,___uri) \
((MN_MAILBOX_CLASS(parent_class)->impl_is)? \
(* MN_MAILBOX_CLASS(parent_class)->impl_is)(___dummy,___uri): \
((gboolean )0))
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::impl_is"
-#line 77 "mn-gmail-mailbox.gob"
+#line 65 "mn-gmail-mailbox.gob"
g_return_val_if_fail (uri != NULL, (gboolean )0);
-#line 259 "mn-gmail-mailbox.c"
+#line 65 "mn-gmail-mailbox.gob"
+ g_return_val_if_fail (MN_IS_URI (uri), (gboolean )0);
+#line 253 "mn-gmail-mailbox.c"
{
-#line 79 "mn-gmail-mailbox.gob"
+#line 67 "mn-gmail-mailbox.gob"
- char *scheme;
- gboolean is;
-
- scheme = gnome_vfs_get_uri_scheme(uri);
- is = scheme && ! strcmp(scheme, "gmail");
- g_free(scheme);
-
- return is;
+ return MN_URI_IS_GMAIL(uri);
}}
-#line 272 "mn-gmail-mailbox.c"
+#line 259 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 90 "mn-gmail-mailbox.gob"
+#line 71 "mn-gmail-mailbox.gob"
static void
___5_mn_gmail_mailbox_impl_check (MNMailbox * mailbox G_GNUC_UNUSED)
-#line 279 "mn-gmail-mailbox.c"
+#line 266 "mn-gmail-mailbox.c"
#define PARENT_HANDLER(___mailbox) \
{ if(MN_MAILBOX_CLASS(parent_class)->impl_check) \
(* MN_MAILBOX_CLASS(parent_class)->impl_check)(___mailbox); }
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::impl_check"
-#line 90 "mn-gmail-mailbox.gob"
+#line 71 "mn-gmail-mailbox.gob"
g_return_if_fail (mailbox != NULL);
-#line 90 "mn-gmail-mailbox.gob"
+#line 71 "mn-gmail-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (mailbox));
-#line 289 "mn-gmail-mailbox.c"
+#line 276 "mn-gmail-mailbox.c"
{
-#line 92 "mn-gmail-mailbox.gob"
+#line 73 "mn-gmail-mailbox.gob"
Self *self = SELF(mailbox);
@@ -296,27 +283,27 @@ ___5_mn_gmail_mailbox_impl_check (MNMailbox * mailbox G_GNUC_UNUSED)
else
self_login(self);
}}
-#line 300 "mn-gmail-mailbox.c"
+#line 287 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 101 "mn-gmail-mailbox.gob"
+#line 82 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_get (MNGmailMailbox * self, const char * uri, SoupCallbackFn callback)
-#line 307 "mn-gmail-mailbox.c"
+#line 294 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::get"
-#line 101 "mn-gmail-mailbox.gob"
+#line 82 "mn-gmail-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 101 "mn-gmail-mailbox.gob"
+#line 82 "mn-gmail-mailbox.gob"
g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
-#line 101 "mn-gmail-mailbox.gob"
+#line 82 "mn-gmail-mailbox.gob"
g_return_if_fail (uri != NULL);
-#line 101 "mn-gmail-mailbox.gob"
+#line 82 "mn-gmail-mailbox.gob"
g_return_if_fail (callback != NULL);
-#line 318 "mn-gmail-mailbox.c"
+#line 305 "mn-gmail-mailbox.c"
{
-#line 105 "mn-gmail-mailbox.gob"
+#line 86 "mn-gmail-mailbox.gob"
SoupContext *context;
SoupMessage *message;
@@ -334,10 +321,123 @@ mn_gmail_mailbox_get (MNGmailMailbox * self, const char * uri, SoupCallbackFn ca
g_free(cookie);
}
+ self_dump_request(self, message);
soup_message_queue(message, callback, self);
/* message will be freed by libsoup after invoking the callback */
}}
-#line 341 "mn-gmail-mailbox.c"
+#line 329 "mn-gmail-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 108 "mn-gmail-mailbox.gob"
+static void
+mn_gmail_mailbox_dump_request (MNGmailMailbox * self, SoupMessage * message)
+#line 335 "mn-gmail-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::dump_request"
+#line 108 "mn-gmail-mailbox.gob"
+ g_return_if_fail (self != NULL);
+#line 108 "mn-gmail-mailbox.gob"
+ g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
+#line 108 "mn-gmail-mailbox.gob"
+ g_return_if_fail (message != NULL);
+#line 344 "mn-gmail-mailbox.c"
+{
+#line 110 "mn-gmail-mailbox.gob"
+
+ const SoupUri *suri;
+ char *uri;
+
+ suri = soup_context_get_uri(message->context);
+ uri = soup_uri_to_string(suri, TRUE);
+ mn_mailbox_notice(MN_MAILBOX(self), "> GET %s", uri);
+ g_free(uri);
+
+ soup_message_foreach_header(message->request_headers, self_dump_request_cb, self);
+ }}
+#line 358 "mn-gmail-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 122 "mn-gmail-mailbox.gob"
+static void
+mn_gmail_mailbox_dump_request_cb (gpointer key, gpointer value, gpointer user_data)
+#line 364 "mn-gmail-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::dump_request_cb"
+#line 122 "mn-gmail-mailbox.gob"
+ g_return_if_fail (key != NULL);
+#line 122 "mn-gmail-mailbox.gob"
+ g_return_if_fail (value != NULL);
+#line 122 "mn-gmail-mailbox.gob"
+ g_return_if_fail (user_data != NULL);
+#line 373 "mn-gmail-mailbox.c"
+{
+#line 126 "mn-gmail-mailbox.gob"
+
+ Self *self = user_data;
+ const char *header_name = key;
+ const char *header_value = value;
+
+ mn_mailbox_notice(MN_MAILBOX(self), "> %s: %s", header_name, header_value);
+ }}
+#line 383 "mn-gmail-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 134 "mn-gmail-mailbox.gob"
+static void
+mn_gmail_mailbox_dump_response (MNGmailMailbox * self, SoupMessage * message)
+#line 389 "mn-gmail-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::dump_response"
+#line 134 "mn-gmail-mailbox.gob"
+ g_return_if_fail (self != NULL);
+#line 134 "mn-gmail-mailbox.gob"
+ g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
+#line 134 "mn-gmail-mailbox.gob"
+ g_return_if_fail (message != NULL);
+#line 398 "mn-gmail-mailbox.c"
+{
+#line 136 "mn-gmail-mailbox.gob"
+
+ char *body;
+ char **lines;
+ int i;
+
+ soup_message_foreach_header(message->response_headers, self_dump_response_cb, self);
+
+ body = g_strndup(message->response.body, message->response.length);
+ lines = g_strsplit(body, "\n", 0);
+ g_free(body);
+
+ for (i = 0; lines[i]; i++)
+ mn_mailbox_notice(MN_MAILBOX(self), "< %s", lines[i]);
+ g_strfreev(lines);
+ }}
+#line 416 "mn-gmail-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 152 "mn-gmail-mailbox.gob"
+static void
+mn_gmail_mailbox_dump_response_cb (gpointer key, gpointer value, gpointer user_data)
+#line 422 "mn-gmail-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::dump_response_cb"
+#line 152 "mn-gmail-mailbox.gob"
+ g_return_if_fail (key != NULL);
+#line 152 "mn-gmail-mailbox.gob"
+ g_return_if_fail (value != NULL);
+#line 152 "mn-gmail-mailbox.gob"
+ g_return_if_fail (user_data != NULL);
+#line 431 "mn-gmail-mailbox.c"
+{
+#line 156 "mn-gmail-mailbox.gob"
+
+ Self *self = user_data;
+ const char *header_name = key;
+ const char *header_value = value;
+
+ mn_mailbox_notice(MN_MAILBOX(self), "< %s: %s", header_name, header_value);
+ }}
+#line 441 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
/**
@@ -351,23 +451,23 @@ mn_gmail_mailbox_get (MNGmailMailbox * self, const char * uri, SoupCallbackFn ca
* Gets the first token of @str included between @pre and @post.
*
* Return value: a newly allocated string containing the token or
- * NULL if not found.
+ * %NULL if not found.
**/
-#line 139 "mn-gmail-mailbox.gob"
+#line 177 "mn-gmail-mailbox.gob"
static char *
mn_gmail_mailbox_get_token (const char * str, const char * pre, const char * post, gboolean include_pre, gboolean include_post)
-#line 360 "mn-gmail-mailbox.c"
+#line 460 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::get_token"
-#line 139 "mn-gmail-mailbox.gob"
+#line 177 "mn-gmail-mailbox.gob"
g_return_val_if_fail (str != NULL, (char * )0);
-#line 139 "mn-gmail-mailbox.gob"
+#line 177 "mn-gmail-mailbox.gob"
g_return_val_if_fail (pre != NULL, (char * )0);
-#line 139 "mn-gmail-mailbox.gob"
+#line 177 "mn-gmail-mailbox.gob"
g_return_val_if_fail (post != NULL, (char * )0);
-#line 369 "mn-gmail-mailbox.c"
+#line 469 "mn-gmail-mailbox.c"
{
-#line 145 "mn-gmail-mailbox.gob"
+#line 183 "mn-gmail-mailbox.gob"
char *token = NULL;
char *pre_loc;
@@ -391,22 +491,22 @@ mn_gmail_mailbox_get_token (const char * str, const char * pre, const char * pos
return token;
}}
-#line 395 "mn-gmail-mailbox.c"
+#line 495 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 169 "mn-gmail-mailbox.gob"
+#line 207 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_login (MNGmailMailbox * self)
-#line 401 "mn-gmail-mailbox.c"
+#line 501 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::login"
-#line 169 "mn-gmail-mailbox.gob"
+#line 207 "mn-gmail-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 169 "mn-gmail-mailbox.gob"
+#line 207 "mn-gmail-mailbox.gob"
g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
-#line 408 "mn-gmail-mailbox.c"
+#line 508 "mn-gmail-mailbox.c"
{
-#line 171 "mn-gmail-mailbox.gob"
+#line 209 "mn-gmail-mailbox.gob"
char *uri;
char *escaped_username;
@@ -420,8 +520,8 @@ mn_gmail_mailbox_login (MNGmailMailbox * self)
mn_mailbox_notice(MN_MAILBOX(self), _("logging in"));
- escaped_username = gnome_vfs_escape_string(selfp->username);
- escaped_password = gnome_vfs_escape_string(selfp->password);
+ escaped_username = gnome_vfs_escape_string(MN_MAILBOX(self)->uri->username);
+ escaped_password = gnome_vfs_escape_string(MN_MAILBOX(self)->uri->password);
uri = g_strdup_printf("https://www.google.com/accounts/ServiceLoginBoxAuth?service=mail&continue=http://gmail.google.com/gmail&Email=%s&Passwd=%s", escaped_username, escaped_password);
g_free(escaped_username);
g_free(escaped_password);
@@ -429,22 +529,22 @@ mn_gmail_mailbox_login (MNGmailMailbox * self)
self_get(self, uri, self_login_cb1);
g_free(uri);
}}
-#line 433 "mn-gmail-mailbox.c"
+#line 533 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 194 "mn-gmail-mailbox.gob"
+#line 232 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_login_cb1 (SoupMessage * message, gpointer user_data)
-#line 439 "mn-gmail-mailbox.c"
+#line 539 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::login_cb1"
-#line 194 "mn-gmail-mailbox.gob"
+#line 232 "mn-gmail-mailbox.gob"
g_return_if_fail (message != NULL);
-#line 194 "mn-gmail-mailbox.gob"
+#line 232 "mn-gmail-mailbox.gob"
g_return_if_fail (user_data != NULL);
-#line 446 "mn-gmail-mailbox.c"
+#line 546 "mn-gmail-mailbox.c"
{
-#line 197 "mn-gmail-mailbox.gob"
+#line 235 "mn-gmail-mailbox.gob"
Self *self = user_data;
@@ -455,6 +555,7 @@ mn_gmail_mailbox_login_cb1 (SoupMessage * message, gpointer user_data)
char *body;
char *next_location;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -480,22 +581,22 @@ mn_gmail_mailbox_login_cb1 (SoupMessage * message, gpointer user_data)
/* if this point is reached, an error occurred */
mn_mailbox_end_check(MN_MAILBOX(self));
}}
-#line 484 "mn-gmail-mailbox.c"
+#line 585 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 233 "mn-gmail-mailbox.gob"
+#line 272 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_login_cb2 (SoupMessage * message, gpointer user_data)
-#line 490 "mn-gmail-mailbox.c"
+#line 591 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::login_cb2"
-#line 233 "mn-gmail-mailbox.gob"
+#line 272 "mn-gmail-mailbox.gob"
g_return_if_fail (message != NULL);
-#line 233 "mn-gmail-mailbox.gob"
+#line 272 "mn-gmail-mailbox.gob"
g_return_if_fail (user_data != NULL);
-#line 497 "mn-gmail-mailbox.c"
+#line 598 "mn-gmail-mailbox.c"
{
-#line 236 "mn-gmail-mailbox.gob"
+#line 275 "mn-gmail-mailbox.gob"
Self *self = user_data;
@@ -506,6 +607,7 @@ mn_gmail_mailbox_login_cb2 (SoupMessage * message, gpointer user_data)
char *body;
char *next_location;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -525,22 +627,22 @@ mn_gmail_mailbox_login_cb2 (SoupMessage * message, gpointer user_data)
/* if this point is reached, an error occurred */
mn_mailbox_end_check(MN_MAILBOX(self));
}}
-#line 529 "mn-gmail-mailbox.c"
+#line 631 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 266 "mn-gmail-mailbox.gob"
+#line 306 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_login_cb3 (SoupMessage * message, gpointer user_data)
-#line 535 "mn-gmail-mailbox.c"
+#line 637 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::login_cb3"
-#line 266 "mn-gmail-mailbox.gob"
+#line 306 "mn-gmail-mailbox.gob"
g_return_if_fail (message != NULL);
-#line 266 "mn-gmail-mailbox.gob"
+#line 306 "mn-gmail-mailbox.gob"
g_return_if_fail (user_data != NULL);
-#line 542 "mn-gmail-mailbox.c"
+#line 644 "mn-gmail-mailbox.c"
{
-#line 269 "mn-gmail-mailbox.gob"
+#line 309 "mn-gmail-mailbox.gob"
Self *self = user_data;
@@ -551,6 +653,7 @@ mn_gmail_mailbox_login_cb3 (SoupMessage * message, gpointer user_data)
char *body;
char *token;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -571,24 +674,24 @@ mn_gmail_mailbox_login_cb3 (SoupMessage * message, gpointer user_data)
/* if this point is reached, an error occurred */
mn_mailbox_end_check(MN_MAILBOX(self));
}}
-#line 575 "mn-gmail-mailbox.c"
+#line 678 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 300 "mn-gmail-mailbox.gob"
+#line 341 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_update_cookies (MNGmailMailbox * self, SoupMessage * message)
-#line 581 "mn-gmail-mailbox.c"
+#line 684 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::update_cookies"
-#line 300 "mn-gmail-mailbox.gob"
+#line 341 "mn-gmail-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 300 "mn-gmail-mailbox.gob"
+#line 341 "mn-gmail-mailbox.gob"
g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
-#line 300 "mn-gmail-mailbox.gob"
+#line 341 "mn-gmail-mailbox.gob"
g_return_if_fail (message != NULL);
-#line 590 "mn-gmail-mailbox.c"
+#line 693 "mn-gmail-mailbox.c"
{
-#line 302 "mn-gmail-mailbox.gob"
+#line 343 "mn-gmail-mailbox.gob"
const GSList *set_cookie_headers;
const GSList *l;
@@ -617,22 +720,22 @@ mn_gmail_mailbox_update_cookies (MNGmailMailbox * self, SoupMessage * message)
}
}
}}
-#line 621 "mn-gmail-mailbox.c"
+#line 724 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 331 "mn-gmail-mailbox.gob"
+#line 372 "mn-gmail-mailbox.gob"
static char *
mn_gmail_mailbox_build_cookie (MNGmailMailbox * self)
-#line 627 "mn-gmail-mailbox.c"
+#line 730 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::build_cookie"
-#line 331 "mn-gmail-mailbox.gob"
+#line 372 "mn-gmail-mailbox.gob"
g_return_val_if_fail (self != NULL, (char * )0);
-#line 331 "mn-gmail-mailbox.gob"
+#line 372 "mn-gmail-mailbox.gob"
g_return_val_if_fail (MN_IS_GMAIL_MAILBOX (self), (char * )0);
-#line 634 "mn-gmail-mailbox.c"
+#line 737 "mn-gmail-mailbox.c"
{
-#line 333 "mn-gmail-mailbox.gob"
+#line 374 "mn-gmail-mailbox.gob"
GString *cookie;
char *str;
@@ -650,17 +753,17 @@ mn_gmail_mailbox_build_cookie (MNGmailMailbox * self)
return str;
}}
-#line 654 "mn-gmail-mailbox.c"
+#line 757 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 351 "mn-gmail-mailbox.gob"
+#line 392 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_build_cookie_cb (gpointer key, gpointer value, gpointer user_data)
-#line 660 "mn-gmail-mailbox.c"
+#line 763 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::build_cookie_cb"
{
-#line 353 "mn-gmail-mailbox.gob"
+#line 394 "mn-gmail-mailbox.gob"
GString *cookie = user_data;
@@ -669,41 +772,41 @@ mn_gmail_mailbox_build_cookie_cb (gpointer key, gpointer value, gpointer user_da
g_string_append_printf(cookie, "%s=%s", (const char *) key, (const char *) value);
}}
-#line 673 "mn-gmail-mailbox.c"
+#line 776 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 362 "mn-gmail-mailbox.gob"
+#line 403 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_check_internal (MNGmailMailbox * self)
-#line 679 "mn-gmail-mailbox.c"
+#line 782 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::check_internal"
-#line 362 "mn-gmail-mailbox.gob"
+#line 403 "mn-gmail-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 362 "mn-gmail-mailbox.gob"
+#line 403 "mn-gmail-mailbox.gob"
g_return_if_fail (MN_IS_GMAIL_MAILBOX (self));
-#line 686 "mn-gmail-mailbox.c"
+#line 789 "mn-gmail-mailbox.c"
{
-#line 364 "mn-gmail-mailbox.gob"
+#line 405 "mn-gmail-mailbox.gob"
mn_mailbox_notice(MN_MAILBOX(self), _("searching for unread mail"));
self_get(self, "https://gmail.google.com/gmail?search=adv&as_subset=unread&view=tl&start=0", self_check_internal_cb);
}}
-#line 694 "mn-gmail-mailbox.c"
+#line 797 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 370 "mn-gmail-mailbox.gob"
+#line 411 "mn-gmail-mailbox.gob"
static void
mn_gmail_mailbox_check_internal_cb (SoupMessage * message, gpointer user_data)
-#line 700 "mn-gmail-mailbox.c"
+#line 803 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::check_internal_cb"
-#line 370 "mn-gmail-mailbox.gob"
+#line 411 "mn-gmail-mailbox.gob"
g_return_if_fail (message != NULL);
-#line 705 "mn-gmail-mailbox.c"
+#line 808 "mn-gmail-mailbox.c"
{
-#line 373 "mn-gmail-mailbox.gob"
+#line 414 "mn-gmail-mailbox.gob"
Self *self = user_data;
@@ -713,6 +816,8 @@ mn_gmail_mailbox_check_internal_cb (SoupMessage * message, gpointer user_data)
{
int count;
+ self_dump_response(self, message);
+
count = self_get_unread_count(message);
if (count == -1)
mn_mailbox_set_error(MN_MAILBOX(self), _("unable to parse Gmail data"));
@@ -722,20 +827,20 @@ mn_gmail_mailbox_check_internal_cb (SoupMessage * message, gpointer user_data)
mn_mailbox_end_check(MN_MAILBOX(self));
}}
-#line 726 "mn-gmail-mailbox.c"
+#line 831 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
-#line 392 "mn-gmail-mailbox.gob"
+#line 435 "mn-gmail-mailbox.gob"
static int
mn_gmail_mailbox_get_unread_count (SoupMessage * message)
-#line 732 "mn-gmail-mailbox.c"
+#line 837 "mn-gmail-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Gmail:Mailbox::get_unread_count"
-#line 392 "mn-gmail-mailbox.gob"
+#line 435 "mn-gmail-mailbox.gob"
g_return_val_if_fail (message != NULL, (int )0);
-#line 737 "mn-gmail-mailbox.c"
+#line 842 "mn-gmail-mailbox.c"
{
-#line 394 "mn-gmail-mailbox.gob"
+#line 437 "mn-gmail-mailbox.gob"
int count = -1;
char *body;
@@ -761,5 +866,5 @@ mn_gmail_mailbox_get_unread_count (SoupMessage * message)
return count;
}}
-#line 765 "mn-gmail-mailbox.c"
+#line 870 "mn-gmail-mailbox.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-gmail-mailbox.gob b/src/mn-gmail-mailbox.gob
@@ -27,7 +27,6 @@
#include <libgnomevfs/gnome-vfs-utils.h>
#include <libsoup/soup.h>
#include "mn-mailbox-private.h"
-#include "mn-uri.h"
#include "mn-util.h"
#include "mn-stock.h"
#include "mn-soup.h"
@@ -35,8 +34,6 @@
class MN:Gmail:Mailbox from MN:Mailbox
{
- private char *username destroywith g_free;
- private char *password destroywith g_free;
private GHashTable *cookies destroywith g_hash_table_destroy;
private gboolean logged_in;
@@ -50,20 +47,11 @@ class MN:Gmail:Mailbox from MN:Mailbox
constructor (GType type, guint n_construct_properties, GObjectConstructParam *construct_params)
{
GObject *object;
- MNMailbox *mailbox;
- Self *self;
object = PARENT_HANDLER(type, n_construct_properties, construct_params);
- mailbox = MN_MAILBOX(object);
- self = SELF(object);
mn_soup_use();
- if (! mn_uri_parse_gmail(mn_mailbox_get_uri(mailbox),
- &selfp->username,
- &selfp->password))
- mn_mailbox_set_init_error(mailbox, _("unable to parse Gmail URI"));
-
return object;
}
@@ -75,16 +63,9 @@ class MN:Gmail:Mailbox from MN:Mailbox
}
override (MN:Mailbox) gboolean
- impl_is (MNMailbox *dummy, const char *uri (check null))
+ impl_is (MNMailbox *dummy, MN:URI *uri (check null type))
{
- char *scheme;
- gboolean is;
-
- scheme = gnome_vfs_get_uri_scheme(uri);
- is = scheme && ! strcmp(scheme, "gmail");
- g_free(scheme);
-
- return is;
+ return MN_URI_IS_GMAIL(uri);
}
override (MN:Mailbox) void
@@ -119,10 +100,67 @@ class MN:Gmail:Mailbox from MN:Mailbox
g_free(cookie);
}
+ self_dump_request(self, message);
soup_message_queue(message, callback, self);
/* message will be freed by libsoup after invoking the callback */
}
+ private void
+ dump_request (self, SoupMessage *message (check null))
+ {
+ const SoupUri *suri;
+ char *uri;
+
+ suri = soup_context_get_uri(message->context);
+ uri = soup_uri_to_string(suri, TRUE);
+ mn_mailbox_notice(MN_MAILBOX(self), "> GET %s", uri);
+ g_free(uri);
+
+ soup_message_foreach_header(message->request_headers, self_dump_request_cb, self);
+ }
+
+ private void
+ dump_request_cb (gpointer key (check null),
+ gpointer value (check null),
+ gpointer user_data (check null))
+ {
+ Self *self = user_data;
+ const char *header_name = key;
+ const char *header_value = value;
+
+ mn_mailbox_notice(MN_MAILBOX(self), "> %s: %s", header_name, header_value);
+ }
+
+ private void
+ dump_response (self, SoupMessage *message (check null))
+ {
+ char *body;
+ char **lines;
+ int i;
+
+ soup_message_foreach_header(message->response_headers, self_dump_response_cb, self);
+
+ body = g_strndup(message->response.body, message->response.length);
+ lines = g_strsplit(body, "\n", 0);
+ g_free(body);
+
+ for (i = 0; lines[i]; i++)
+ mn_mailbox_notice(MN_MAILBOX(self), "< %s", lines[i]);
+ g_strfreev(lines);
+ }
+
+ private void
+ dump_response_cb (gpointer key (check null),
+ gpointer value (check null),
+ gpointer user_data (check null))
+ {
+ Self *self = user_data;
+ const char *header_name = key;
+ const char *header_value = value;
+
+ mn_mailbox_notice(MN_MAILBOX(self), "< %s: %s", header_name, header_value);
+ }
+
/**
* get_token:
* @str: the string to search
@@ -134,8 +172,8 @@ class MN:Gmail:Mailbox from MN:Mailbox
* Gets the first token of @str included between @pre and @post.
*
* Return value: a newly allocated string containing the token or
- * NULL if not found.
- */
+ * %NULL if not found.
+ **/
private char *
get_token (const char *str (check null),
const char *pre (check null),
@@ -181,8 +219,8 @@ class MN:Gmail:Mailbox from MN:Mailbox
mn_mailbox_notice(MN_MAILBOX(self), _("logging in"));
- escaped_username = gnome_vfs_escape_string(selfp->username);
- escaped_password = gnome_vfs_escape_string(selfp->password);
+ escaped_username = gnome_vfs_escape_string(MN_MAILBOX(self)->uri->username);
+ escaped_password = gnome_vfs_escape_string(MN_MAILBOX(self)->uri->password);
uri = g_strdup_printf("https://www.google.com/accounts/ServiceLoginBoxAuth?service=mail&continue=http://gmail.google.com/gmail&Email=%s&Passwd=%s", escaped_username, escaped_password);
g_free(escaped_username);
g_free(escaped_password);
@@ -204,6 +242,7 @@ class MN:Gmail:Mailbox from MN:Mailbox
char *body;
char *next_location;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -243,6 +282,7 @@ class MN:Gmail:Mailbox from MN:Mailbox
char *body;
char *next_location;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -276,6 +316,7 @@ class MN:Gmail:Mailbox from MN:Mailbox
char *body;
char *token;
+ self_dump_response(self, message);
self_update_cookies(self, message);
body = g_strndup(message->response.body, message->response.length);
@@ -379,6 +420,8 @@ class MN:Gmail:Mailbox from MN:Mailbox
{
int count;
+ self_dump_response(self, message);
+
count = self_get_unread_count(message);
if (count == -1)
mn_mailbox_set_error(MN_MAILBOX(self), _("unable to parse Gmail data"));
diff --git a/src/mn-imap-mailbox-private.h b/src/mn-imap-mailbox-private.h
@@ -9,23 +9,6 @@
extern "C" {
#endif /* __cplusplus */
-struct _MNIMAPMailboxPrivate {
-#line 89 "mn-imap-mailbox.gob"
- char * hostname;
-#line 90 "mn-imap-mailbox.gob"
- int port;
-#line 91 "mn-imap-mailbox.gob"
- char * username;
-#line 92 "mn-imap-mailbox.gob"
- char * password;
-#line 93 "mn-imap-mailbox.gob"
- char * authmech;
-#line 94 "mn-imap-mailbox.gob"
- char * mailbox;
-#line 95 "mn-imap-mailbox.gob"
- gboolean ssl;
-#line 28 "mn-imap-mailbox-private.h"
-};
#ifdef __cplusplus
}
diff --git a/src/mn-imap-mailbox-properties.c b/src/mn-imap-mailbox-properties.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -28,11 +28,10 @@
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
#include "mn-pi-mailbox-properties-private.h"
-#include "mn-uri.h"
#include "mn-auth-combo-box.h"
#include "mn-util.h"
-#line 36 "mn-imap-mailbox-properties.c"
+#line 35 "mn-imap-mailbox-properties.c"
/* self casting macros */
#define SELF(x) MN_IMAP_MAILBOX_PROPERTIES(x)
#define SELF_CONST(x) MN_IMAP_MAILBOX_PROPERTIES_CONST(x)
@@ -52,8 +51,8 @@ static void mn_imap_mailbox_properties_init (MNIMAPMailboxProperties * o) G_GNUC
static void mn_imap_mailbox_properties_class_init (MNIMAPMailboxPropertiesClass * class) G_GNUC_UNUSED;
static GObject * ___2_mn_imap_mailbox_properties_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_params) G_GNUC_UNUSED;
static void mn_imap_mailbox_properties_radio_toggled_h (GtkToggleButton * togglebutton, gpointer user_data) G_GNUC_UNUSED;
-static gboolean mn_imap_mailbox_properties_set_uri (MNMailboxProperties * properties, const char * uri) G_GNUC_UNUSED;
-static char * mn_imap_mailbox_properties_get_uri (MNMailboxProperties * properties) G_GNUC_UNUSED;
+static gboolean mn_imap_mailbox_properties_set_uri (MNMailboxProperties * properties, MNURI * uri) G_GNUC_UNUSED;
+static MNURI * mn_imap_mailbox_properties_get_uri (MNMailboxProperties * properties) G_GNUC_UNUSED;
enum {
PROP_0,
@@ -72,11 +71,11 @@ static MNPIMailboxPropertiesClass *parent_class = NULL;
static void
___MN_Mailbox_Properties_init (MNMailboxPropertiesIface *iface)
{
-#line 146 "mn-imap-mailbox-properties.gob"
+#line 147 "mn-imap-mailbox-properties.gob"
iface->set_uri = self_set_uri;
-#line 189 "mn-imap-mailbox-properties.gob"
+#line 178 "mn-imap-mailbox-properties.gob"
iface->get_uri = self_get_uri;
-#line 80 "mn-imap-mailbox-properties.c"
+#line 79 "mn-imap-mailbox-properties.c"
}
GType
@@ -153,7 +152,7 @@ mn_imap_mailbox_properties_init (MNIMAPMailboxProperties * o G_GNUC_UNUSED)
#line 70 "mn-imap-mailbox-properties.gob"
static void
mn_imap_mailbox_properties_class_init (MNIMAPMailboxPropertiesClass * class G_GNUC_UNUSED)
-#line 157 "mn-imap-mailbox-properties.c"
+#line 156 "mn-imap-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox:Properties::class_init"
GObjectClass *g_object_class G_GNUC_UNUSED = (GObjectClass*) class;
@@ -162,7 +161,7 @@ mn_imap_mailbox_properties_class_init (MNIMAPMailboxPropertiesClass * class G_GN
#line 79 "mn-imap-mailbox-properties.gob"
g_object_class->constructor = ___2_mn_imap_mailbox_properties_constructor;
-#line 166 "mn-imap-mailbox-properties.c"
+#line 165 "mn-imap-mailbox-properties.c"
g_object_class->finalize = ___finalize;
g_object_class->get_property = ___object_get_property;
{
@@ -176,10 +175,10 @@ mn_imap_mailbox_properties_class_init (MNIMAPMailboxPropertiesClass * class G_GN
MNPIMailboxPropertiesClass *pi_class = MN_PI_MAILBOX_PROPERTIES_CLASS(class);
pi_class->label = "IMAP";
- pi_class->default_port[0] = MN_URI_IMAP_PORT(FALSE);
- pi_class->default_port[1] = MN_URI_IMAP_PORT(TRUE);
+ pi_class->default_port[0] = mn_uri_get_default_port("imap");
+ pi_class->default_port[1] = mn_uri_get_default_port("imaps");
-#line 183 "mn-imap-mailbox-properties.c"
+#line 182 "mn-imap-mailbox-properties.c"
}
}
#undef __GOB_FUNCTION__
@@ -198,7 +197,7 @@ ___object_get_property (GObject *object,
switch (property_id) {
case PROP_COMPLETE:
{
-#line 37 "mn-imap-mailbox-properties.gob"
+#line 36 "mn-imap-mailbox-properties.gob"
MNPIMailboxProperties *pi = MN_PI_MAILBOX_PROPERTIES(self);
gboolean complete;
@@ -210,6 +209,7 @@ ___object_get_property (GObject *object,
mn_pi_mailbox_properties_get_contents(pi,
NULL,
+ NULL,
&username,
&password,
NULL,
@@ -285,6 +285,7 @@ ___2_mn_imap_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_c
selfp->other_radio = gtk_radio_button_new_with_mnemonic_from_widget(GTK_RADIO_BUTTON(selfp->inbox_radio), _("oth_er:"));
selfp->mailbox_entry = gtk_entry_new();
gtk_widget_set_sensitive(selfp->mailbox_entry, FALSE);
+ gtk_entry_set_activates_default(GTK_ENTRY(selfp->mailbox_entry), TRUE);
hbox = gtk_hbox_new(FALSE, 12);
gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
@@ -310,117 +311,109 @@ ___2_mn_imap_mailbox_properties_constructor (GType type G_GNUC_UNUSED, guint n_c
return object;
}}
-#line 314 "mn-imap-mailbox-properties.c"
+#line 315 "mn-imap-mailbox-properties.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 136 "mn-imap-mailbox-properties.gob"
+#line 137 "mn-imap-mailbox-properties.gob"
static void
mn_imap_mailbox_properties_radio_toggled_h (GtkToggleButton * togglebutton, gpointer user_data)
-#line 321 "mn-imap-mailbox-properties.c"
+#line 322 "mn-imap-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox:Properties::radio_toggled_h"
-#line 136 "mn-imap-mailbox-properties.gob"
+#line 137 "mn-imap-mailbox-properties.gob"
g_return_if_fail (togglebutton != NULL);
-#line 136 "mn-imap-mailbox-properties.gob"
+#line 137 "mn-imap-mailbox-properties.gob"
g_return_if_fail (GTK_IS_TOGGLE_BUTTON (togglebutton));
-#line 136 "mn-imap-mailbox-properties.gob"
+#line 137 "mn-imap-mailbox-properties.gob"
g_return_if_fail (user_data != NULL);
-#line 330 "mn-imap-mailbox-properties.c"
+#line 331 "mn-imap-mailbox-properties.c"
{
-#line 139 "mn-imap-mailbox-properties.gob"
+#line 140 "mn-imap-mailbox-properties.gob"
Self *self = user_data;
gtk_widget_set_sensitive(selfp->mailbox_entry, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(selfp->other_radio)));
g_object_notify(G_OBJECT(self), "complete");
}}
-#line 339 "mn-imap-mailbox-properties.c"
+#line 340 "mn-imap-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 146 "mn-imap-mailbox-properties.gob"
+#line 147 "mn-imap-mailbox-properties.gob"
static gboolean
-mn_imap_mailbox_properties_set_uri (MNMailboxProperties * properties, const char * uri)
-#line 345 "mn-imap-mailbox-properties.c"
+mn_imap_mailbox_properties_set_uri (MNMailboxProperties * properties, MNURI * uri)
+#line 346 "mn-imap-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox:Properties::set_uri"
-#line 146 "mn-imap-mailbox-properties.gob"
+#line 147 "mn-imap-mailbox-properties.gob"
g_return_val_if_fail (properties != NULL, (gboolean )0);
-#line 146 "mn-imap-mailbox-properties.gob"
+#line 147 "mn-imap-mailbox-properties.gob"
g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (properties), (gboolean )0);
-#line 146 "mn-imap-mailbox-properties.gob"
+#line 147 "mn-imap-mailbox-properties.gob"
g_return_val_if_fail (uri != NULL, (gboolean )0);
-#line 354 "mn-imap-mailbox-properties.c"
+#line 147 "mn-imap-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_URI (uri), (gboolean )0);
+#line 357 "mn-imap-mailbox-properties.c"
{
-#line 149 "mn-imap-mailbox-properties.gob"
+#line 150 "mn-imap-mailbox-properties.gob"
Self *self = SELF(properties);
- gboolean ssl;
- char *username;
- char *password;
- char *authmech;
- char *hostname;
- int port;
- char *mailbox;
- if (mn_uri_parse_imap(uri, &ssl, &username, &password, &authmech, &hostname, &port, &mailbox))
+ if (MN_URI_IS_IMAP(uri))
{
mn_pi_mailbox_properties_set_contents(MN_PI_MAILBOX_PROPERTIES(properties),
- ssl,
- username,
- password,
- authmech,
- hostname,
- port);
+ MN_URI_IS_SSL(uri),
+ MN_URI_IS_INBAND_SSL(uri),
+ uri->username,
+ uri->password,
+ uri->authmech,
+ uri->hostname,
+ uri->port);
- if (! strcmp(mailbox, "INBOX"))
+ if (! strcmp(uri->path, "INBOX"))
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(selfp->inbox_radio), TRUE);
else
{
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(selfp->other_radio), TRUE);
- gtk_entry_set_text(GTK_ENTRY(selfp->mailbox_entry), mailbox);
+ gtk_entry_set_text(GTK_ENTRY(selfp->mailbox_entry), uri->path);
}
- g_free(username);
- g_free(password);
- g_free(authmech);
- g_free(hostname);
- g_free(mailbox);
-
return TRUE;
}
else
return FALSE;
}}
-#line 396 "mn-imap-mailbox-properties.c"
+#line 387 "mn-imap-mailbox-properties.c"
#undef __GOB_FUNCTION__
-#line 189 "mn-imap-mailbox-properties.gob"
-static char *
+#line 178 "mn-imap-mailbox-properties.gob"
+static MNURI *
mn_imap_mailbox_properties_get_uri (MNMailboxProperties * properties)
-#line 402 "mn-imap-mailbox-properties.c"
+#line 393 "mn-imap-mailbox-properties.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox:Properties::get_uri"
-#line 189 "mn-imap-mailbox-properties.gob"
- g_return_val_if_fail (properties != NULL, (char * )0);
-#line 189 "mn-imap-mailbox-properties.gob"
- g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (properties), (char * )0);
-#line 409 "mn-imap-mailbox-properties.c"
+#line 178 "mn-imap-mailbox-properties.gob"
+ g_return_val_if_fail (properties != NULL, (MNURI * )0);
+#line 178 "mn-imap-mailbox-properties.gob"
+ g_return_val_if_fail (MN_IS_MAILBOX_PROPERTIES (properties), (MNURI * )0);
+#line 400 "mn-imap-mailbox-properties.c"
{
-#line 191 "mn-imap-mailbox-properties.gob"
+#line 180 "mn-imap-mailbox-properties.gob"
Self *self = SELF(properties);
gboolean ssl;
+ gboolean inband_ssl;
const char *username;
const char *password;
char *authmech;
const char *hostname;
int port;
const char *mailbox = NULL;
- char *uri;
+ MNURI *uri;
mn_pi_mailbox_properties_get_contents(MN_PI_MAILBOX_PROPERTIES(properties),
&ssl,
+ &inband_ssl,
&username,
&password,
&authmech,
@@ -431,10 +424,10 @@ mn_imap_mailbox_properties_get_uri (MNMailboxProperties * properties)
? "INBOX"
: gtk_entry_get_text(GTK_ENTRY(selfp->mailbox_entry));
- uri = mn_uri_build_imap(ssl, username, password, authmech, hostname, port, mailbox);
+ uri = mn_uri_new_imap(ssl, inband_ssl, username, password, authmech, hostname, port, mailbox);
g_free(authmech);
return uri;
}}
-#line 440 "mn-imap-mailbox-properties.c"
+#line 433 "mn-imap-mailbox-properties.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-imap-mailbox-properties.gob b/src/mn-imap-mailbox-properties.gob
@@ -25,7 +25,6 @@
#include "mn-mailbox-properties.h"
#include "mn-mailbox-properties-util.h"
#include "mn-pi-mailbox-properties-private.h"
-#include "mn-uri.h"
#include "mn-auth-combo-box.h"
#include "mn-util.h"
%}
@@ -45,6 +44,7 @@ class MN:IMAP:Mailbox:Properties from MN:PI:Mailbox:Properties (interface MN:Mai
mn_pi_mailbox_properties_get_contents(pi,
NULL,
+ NULL,
&username,
&password,
NULL,
@@ -72,8 +72,8 @@ class MN:IMAP:Mailbox:Properties from MN:PI:Mailbox:Properties (interface MN:Mai
MNPIMailboxPropertiesClass *pi_class = MN_PI_MAILBOX_PROPERTIES_CLASS(class);
pi_class->label = "IMAP";
- pi_class->default_port[0] = MN_URI_IMAP_PORT(FALSE);
- pi_class->default_port[1] = MN_URI_IMAP_PORT(TRUE);
+ pi_class->default_port[0] = mn_uri_get_default_port("imap");
+ pi_class->default_port[1] = mn_uri_get_default_port("imaps");
}
override (G:Object) GObject *
@@ -107,6 +107,7 @@ class MN:IMAP:Mailbox:Properties from MN:PI:Mailbox:Properties (interface MN:Mai
selfp->other_radio = gtk_radio_button_new_with_mnemonic_from_widget(GTK_RADIO_BUTTON(selfp->inbox_radio), _("oth_er:"));
selfp->mailbox_entry = gtk_entry_new();
gtk_widget_set_sensitive(selfp->mailbox_entry, FALSE);
+ gtk_entry_set_activates_default(GTK_ENTRY(selfp->mailbox_entry), TRUE);
hbox = gtk_hbox_new(FALSE, 12);
gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
@@ -145,62 +146,52 @@ class MN:IMAP:Mailbox:Properties from MN:PI:Mailbox:Properties (interface MN:Mai
interface MN:Mailbox:Properties private gboolean
set_uri (MN:Mailbox:Properties *properties (check null type),
- const char *uri (check null))
+ MN:URI *uri (check null type))
{
Self *self = SELF(properties);
- gboolean ssl;
- char *username;
- char *password;
- char *authmech;
- char *hostname;
- int port;
- char *mailbox;
- if (mn_uri_parse_imap(uri, &ssl, &username, &password, &authmech, &hostname, &port, &mailbox))
+ if (MN_URI_IS_IMAP(uri))
{
mn_pi_mailbox_properties_set_contents(MN_PI_MAILBOX_PROPERTIES(properties),
- ssl,
- username,
- password,
- authmech,
- hostname,
- port);
+ MN_URI_IS_SSL(uri),
+ MN_URI_IS_INBAND_SSL(uri),
+ uri->username,
+ uri->password,
+ uri->authmech,
+ uri->hostname,
+ uri->port);
- if (! strcmp(mailbox, "INBOX"))
+ if (! strcmp(uri->path, "INBOX"))
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(selfp->inbox_radio), TRUE);
else
{
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(selfp->other_radio), TRUE);
- gtk_entry_set_text(GTK_ENTRY(selfp->mailbox_entry), mailbox);
+ gtk_entry_set_text(GTK_ENTRY(selfp->mailbox_entry), uri->path);
}
- g_free(username);
- g_free(password);
- g_free(authmech);
- g_free(hostname);
- g_free(mailbox);
-
return TRUE;
}
else
return FALSE;
}
- interface MN:Mailbox:Properties private char *
+ interface MN:Mailbox:Properties private MNURI *
get_uri (MN:Mailbox:Properties *properties (check null type))
{
Self *self = SELF(properties);
gboolean ssl;
+ gboolean inband_ssl;
const char *username;
const char *password;
char *authmech;
const char *hostname;
int port;
const char *mailbox = NULL;
- char *uri;
+ MNURI *uri;
mn_pi_mailbox_properties_get_contents(MN_PI_MAILBOX_PROPERTIES(properties),
&ssl,
+ &inband_ssl,
&username,
&password,
&authmech,
@@ -211,7 +202,7 @@ class MN:IMAP:Mailbox:Properties from MN:PI:Mailbox:Properties (interface MN:Mai
? "INBOX"
: gtk_entry_get_text(GTK_ENTRY(selfp->mailbox_entry));
- uri = mn_uri_build_imap(ssl, username, password, authmech, hostname, port, mailbox);
+ uri = mn_uri_new_imap(ssl, inband_ssl, username, password, authmech, hostname, port, mailbox);
g_free(authmech);
return uri;
diff --git a/src/mn-imap-mailbox.c b/src/mn-imap-mailbox.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -29,9 +29,9 @@
#include <stdarg.h>
#include <glib/gi18n-lib.h>
#include <libgnomevfs/gnome-vfs-utils.h>
+#include <eel/eel.h>
#include "mn-mailbox-private.h"
#include "mn-util.h"
-#include "mn-uri.h"
#include "mn-client-session.h"
#define HAS_CURRENT_TAG(response, priv) (! strcmp((response)->tag, (priv)->tag))
@@ -45,6 +45,9 @@
{
STATE_GREETING = MN_CLIENT_SESSION_INITIAL_STATE,
STATE_CAPABILITY,
+#ifdef WITH_SSL
+ STATE_STARTTLS,
+#endif
#ifdef WITH_SASL
STATE_AUTHENTICATE,
#endif
@@ -62,18 +65,22 @@
struct _MNClientSessionPrivate
{
- MNIMAPMailbox *mailbox;
+ MNMailbox *mailbox;
+ MNIMAPMailbox *self;
MNClientSession *session;
int numeric_tag;
char *tag;
char **capabilities;
GSList *auth_mechanisms;
gboolean status_received;
+#ifdef WITH_SSL
+ gboolean starttls_completed;
+#endif
#ifdef WITH_SASL
const char *sasl_mechanism;
#endif
};
-
+
struct _MNClientSessionResponse
{
char *continuation;
@@ -83,7 +90,7 @@
char *arguments;
};
-#line 87 "mn-imap-mailbox.c"
+#line 94 "mn-imap-mailbox.c"
/* self casting macros */
#define SELF(x) MN_IMAP_MAILBOX(x)
#define SELF_CONST(x) MN_IMAP_MAILBOX_CONST(x)
@@ -101,10 +108,12 @@ typedef MNIMAPMailboxClass SelfClass;
static void mn_imap_mailbox_init (MNIMAPMailbox * o) G_GNUC_UNUSED;
static void mn_imap_mailbox_class_init (MNIMAPMailboxClass * class) G_GNUC_UNUSED;
static GObject * ___2_mn_imap_mailbox_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_params) G_GNUC_UNUSED;
-static gboolean ___3_mn_imap_mailbox_impl_is (MNMailbox * dummy, const char * uri) G_GNUC_UNUSED;
+static gboolean ___3_mn_imap_mailbox_impl_is (MNMailbox * dummy, MNURI * uri) G_GNUC_UNUSED;
static int mn_imap_mailbox_handle_greeting_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_enter_capability_cb (MNClientSession * session, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_handle_capability_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
+static int mn_imap_mailbox_enter_starttls_cb (MNClientSession * session, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
+static int mn_imap_mailbox_handle_starttls_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_enter_authenticate_cb (MNClientSession * session, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_handle_authenticate_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_enter_login_cb (MNClientSession * session, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
@@ -113,7 +122,7 @@ static int mn_imap_mailbox_enter_status_cb (MNClientSession * session, MNClientS
static int mn_imap_mailbox_handle_status_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_enter_logout_cb (MNClientSession * session, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_handle_logout_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
-static void ___f_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox) G_GNUC_UNUSED;
+static void ___11_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox) G_GNUC_UNUSED;
static void mn_imap_mailbox_notice_cb (MNClientSession * session, const char * str, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static MNClientSessionResponse * mn_imap_mailbox_response_new_cb (MNClientSession * session, const char * input, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static void mn_imap_mailbox_response_free_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv) G_GNUC_UNUSED;
@@ -122,6 +131,7 @@ static void mn_imap_mailbox_session_set_error_from_arguments (MNClientSessionPri
static int mn_imap_mailbox_session_write (MNClientSessionPrivate * priv, const char * format, ...) G_GNUC_UNUSED;
static void mn_imap_mailbox_session_parse_capabilities (MNClientSessionPrivate * priv, const char * capabilities) G_GNUC_UNUSED;
static gboolean mn_imap_mailbox_session_has_capability (MNClientSessionPrivate * priv, const char * capability) G_GNUC_UNUSED;
+static int mn_imap_mailbox_session_after_capability (MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_session_authenticate (MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static int mn_imap_mailbox_session_authenticate_fallback (MNClientSessionPrivate * priv) G_GNUC_UNUSED;
static char * mn_imap_mailbox_quote (const char * str) G_GNUC_UNUSED;
@@ -133,6 +143,8 @@ static MNMailboxClass *parent_class = NULL;
#define self_handle_greeting_cb mn_imap_mailbox_handle_greeting_cb
#define self_enter_capability_cb mn_imap_mailbox_enter_capability_cb
#define self_handle_capability_cb mn_imap_mailbox_handle_capability_cb
+#define self_enter_starttls_cb mn_imap_mailbox_enter_starttls_cb
+#define self_handle_starttls_cb mn_imap_mailbox_handle_starttls_cb
#define self_enter_authenticate_cb mn_imap_mailbox_enter_authenticate_cb
#define self_handle_authenticate_cb mn_imap_mailbox_handle_authenticate_cb
#define self_enter_login_cb mn_imap_mailbox_enter_login_cb
@@ -149,6 +161,7 @@ static MNMailboxClass *parent_class = NULL;
#define self_session_write mn_imap_mailbox_session_write
#define self_session_parse_capabilities mn_imap_mailbox_session_parse_capabilities
#define self_session_has_capability mn_imap_mailbox_session_has_capability
+#define self_session_after_capability mn_imap_mailbox_session_after_capability
#define self_session_authenticate mn_imap_mailbox_session_authenticate
#define self_session_authenticate_fallback mn_imap_mailbox_session_authenticate_fallback
#define self_quote mn_imap_mailbox_quote
@@ -194,76 +207,46 @@ GET_NEW_VARG (const char *first, ...)
return ret;
}
-
-static void
-___finalize(GObject *obj_self)
-{
-#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::finalize"
- MNIMAPMailbox *self G_GNUC_UNUSED = MN_IMAP_MAILBOX (obj_self);
- gpointer priv = self->_priv;
- if(G_OBJECT_CLASS(parent_class)->finalize) \
- (* G_OBJECT_CLASS(parent_class)->finalize)(obj_self);
-#line 89 "mn-imap-mailbox.gob"
- if(self->_priv->hostname) { ((*(void (*)(void *))g_free)) (self->_priv->hostname); self->_priv->hostname = NULL; }
-#line 209 "mn-imap-mailbox.c"
-#line 91 "mn-imap-mailbox.gob"
- if(self->_priv->username) { ((*(void (*)(void *))g_free)) (self->_priv->username); self->_priv->username = NULL; }
-#line 212 "mn-imap-mailbox.c"
-#line 92 "mn-imap-mailbox.gob"
- if(self->_priv->password) { ((*(void (*)(void *))g_free)) (self->_priv->password); self->_priv->password = NULL; }
-#line 215 "mn-imap-mailbox.c"
-#line 93 "mn-imap-mailbox.gob"
- if(self->_priv->authmech) { ((*(void (*)(void *))g_free)) (self->_priv->authmech); self->_priv->authmech = NULL; }
-#line 218 "mn-imap-mailbox.c"
-#line 94 "mn-imap-mailbox.gob"
- if(self->_priv->mailbox) { ((*(void (*)(void *))g_free)) (self->_priv->mailbox); self->_priv->mailbox = NULL; }
-#line 221 "mn-imap-mailbox.c"
- g_free (priv);
-}
-#undef __GOB_FUNCTION__
-
static void
mn_imap_mailbox_init (MNIMAPMailbox * o G_GNUC_UNUSED)
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::init"
- o->_priv = g_new0 (MNIMAPMailboxPrivate, 1);
}
#undef __GOB_FUNCTION__
-#line 97 "mn-imap-mailbox.gob"
+#line 96 "mn-imap-mailbox.gob"
static void
mn_imap_mailbox_class_init (MNIMAPMailboxClass * class G_GNUC_UNUSED)
-#line 236 "mn-imap-mailbox.c"
+#line 220 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::class_init"
- GObjectClass *g_object_class G_GNUC_UNUSED = (GObjectClass*) class;
+ GObjectClass *g_object_class = (GObjectClass *)class;
MNMailboxClass *mn_mailbox_class = (MNMailboxClass *)class;
parent_class = g_type_class_ref (MN_TYPE_MAILBOX);
-#line 102 "mn-imap-mailbox.gob"
+#line 101 "mn-imap-mailbox.gob"
g_object_class->constructor = ___2_mn_imap_mailbox_constructor;
-#line 133 "mn-imap-mailbox.gob"
+#line 118 "mn-imap-mailbox.gob"
mn_mailbox_class->impl_is = ___3_mn_imap_mailbox_impl_is;
-#line 391 "mn-imap-mailbox.gob"
- mn_mailbox_class->impl_threaded_check = ___f_mn_imap_mailbox_impl_threaded_check;
-#line 250 "mn-imap-mailbox.c"
- g_object_class->finalize = ___finalize;
+#line 416 "mn-imap-mailbox.gob"
+ mn_mailbox_class->impl_threaded_check = ___11_mn_imap_mailbox_impl_threaded_check;
+#line 234 "mn-imap-mailbox.c"
{
-#line 98 "mn-imap-mailbox.gob"
+#line 97 "mn-imap-mailbox.gob"
MN_MAILBOX_CLASS(class)->format = "IMAP";
-#line 257 "mn-imap-mailbox.c"
+#line 240 "mn-imap-mailbox.c"
}
}
#undef __GOB_FUNCTION__
-#line 102 "mn-imap-mailbox.gob"
+#line 101 "mn-imap-mailbox.gob"
static GObject *
___2_mn_imap_mailbox_constructor (GType type G_GNUC_UNUSED, guint n_construct_properties, GObjectConstructParam * construct_params)
-#line 267 "mn-imap-mailbox.c"
+#line 250 "mn-imap-mailbox.c"
#define PARENT_HANDLER(___type,___n_construct_properties,___construct_params) \
((G_OBJECT_CLASS(parent_class)->constructor)? \
(* G_OBJECT_CLASS(parent_class)->constructor)(___type,___n_construct_properties,___construct_params): \
@@ -271,83 +254,64 @@ ___2_mn_imap_mailbox_constructor (GType type G_GNUC_UNUSED, guint n_construct_pr
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::constructor"
{
-#line 104 "mn-imap-mailbox.gob"
+#line 103 "mn-imap-mailbox.gob"
GObject *object;
MNMailbox *mailbox;
- Self *self;
object = PARENT_HANDLER(type, n_construct_properties, construct_params);
mailbox = MN_MAILBOX(object);
- self = SELF(object);
-
- if (mn_uri_parse_imap(mn_mailbox_get_uri(mailbox),
- &selfp->ssl,
- &selfp->username,
- &selfp->password,
- &selfp->authmech,
- &selfp->hostname,
- &selfp->port,
- &selfp->mailbox))
- {
+
#ifndef WITH_SSL
- if (selfp->ssl)
- mn_mailbox_set_init_error(mailbox, _("SSL support has not been compiled in"));
+ if (MN_URI_IS_SSL(mailbox->uri) || MN_URI_IS_INBAND_SSL(mailbox->uri))
+ mn_mailbox_set_init_error(mailbox, _("SSL/TLS support has not been compiled in"));
#endif /* WITH_SSL */
- }
- else
- mn_mailbox_set_init_error(mailbox, _("unable to parse IMAP URI"));
return object;
}}
-#line 304 "mn-imap-mailbox.c"
+#line 273 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 133 "mn-imap-mailbox.gob"
+#line 118 "mn-imap-mailbox.gob"
static gboolean
-___3_mn_imap_mailbox_impl_is (MNMailbox * dummy G_GNUC_UNUSED, const char * uri)
-#line 311 "mn-imap-mailbox.c"
+___3_mn_imap_mailbox_impl_is (MNMailbox * dummy G_GNUC_UNUSED, MNURI * uri)
+#line 280 "mn-imap-mailbox.c"
#define PARENT_HANDLER(___dummy,___uri) \
((MN_MAILBOX_CLASS(parent_class)->impl_is)? \
(* MN_MAILBOX_CLASS(parent_class)->impl_is)(___dummy,___uri): \
((gboolean )0))
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::impl_is"
-#line 133 "mn-imap-mailbox.gob"
+#line 118 "mn-imap-mailbox.gob"
g_return_val_if_fail (uri != NULL, (gboolean )0);
-#line 320 "mn-imap-mailbox.c"
+#line 118 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (MN_IS_URI (uri), (gboolean )0);
+#line 291 "mn-imap-mailbox.c"
{
-#line 135 "mn-imap-mailbox.gob"
+#line 120 "mn-imap-mailbox.gob"
- char *scheme;
- gboolean is;
-
- scheme = gnome_vfs_get_uri_scheme(uri);
- is = scheme && (! strcmp(scheme, "imap") || ! strcmp(scheme, "imaps"));
- g_free(scheme);
-
- return is;
+ return MN_URI_IS_IMAP(uri);
}}
-#line 333 "mn-imap-mailbox.c"
+#line 297 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 146 "mn-imap-mailbox.gob"
+#line 124 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_greeting_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 340 "mn-imap-mailbox.c"
+#line 304 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_greeting_cb"
-#line 146 "mn-imap-mailbox.gob"
+#line 124 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 146 "mn-imap-mailbox.gob"
+#line 124 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 146 "mn-imap-mailbox.gob"
+#line 124 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 349 "mn-imap-mailbox.c"
+#line 313 "mn-imap-mailbox.c"
{
-#line 150 "mn-imap-mailbox.gob"
+#line 128 "mn-imap-mailbox.gob"
priv->session = session;
@@ -362,7 +326,7 @@ mn_imap_mailbox_handle_greeting_cb (MNClientSession * session, MNClientSessionRe
}
return priv->capabilities
- ? self_session_authenticate(priv)
+ ? self_session_after_capability(priv)
: STATE_CAPABILITY;
}
else if (! response->tag && IS(response, "PREAUTH"))
@@ -372,43 +336,49 @@ mn_imap_mailbox_handle_greeting_cb (MNClientSession * session, MNClientSessionRe
else
return MN_CLIENT_SESSION_RESULT_BAD_RESPONSE_FOR_CONTEXT;
}}
-#line 376 "mn-imap-mailbox.c"
+#line 340 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 175 "mn-imap-mailbox.gob"
+#line 153 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_enter_capability_cb (MNClientSession * session, MNClientSessionPrivate * priv)
-#line 382 "mn-imap-mailbox.c"
+#line 346 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_capability_cb"
-#line 175 "mn-imap-mailbox.gob"
+#line 153 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 175 "mn-imap-mailbox.gob"
+#line 153 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 389 "mn-imap-mailbox.c"
+#line 353 "mn-imap-mailbox.c"
{
-#line 178 "mn-imap-mailbox.gob"
+#line 156 "mn-imap-mailbox.gob"
+ g_strfreev(priv->capabilities);
+ priv->capabilities = NULL;
+
+ eel_g_slist_free_deep(priv->auth_mechanisms);
+ priv->auth_mechanisms = NULL;
+
return self_session_write(priv, "CAPABILITY");
}}
-#line 395 "mn-imap-mailbox.c"
+#line 365 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 182 "mn-imap-mailbox.gob"
+#line 166 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_capability_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 401 "mn-imap-mailbox.c"
+#line 371 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_capability_cb"
-#line 182 "mn-imap-mailbox.gob"
+#line 166 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 182 "mn-imap-mailbox.gob"
+#line 166 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 182 "mn-imap-mailbox.gob"
+#line 166 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 410 "mn-imap-mailbox.c"
+#line 380 "mn-imap-mailbox.c"
{
-#line 186 "mn-imap-mailbox.gob"
+#line 170 "mn-imap-mailbox.gob"
if (response->tag)
{
@@ -417,7 +387,7 @@ mn_imap_mailbox_handle_capability_cb (MNClientSession * session, MNClientSession
if (IS_OK(response))
{
return priv->capabilities
- ? self_session_authenticate(priv)
+ ? self_session_after_capability(priv)
: mn_client_session_error(session, _("server did not send capabilities"));
}
else if (IS_BAD(response))
@@ -434,28 +404,94 @@ mn_imap_mailbox_handle_capability_cb (MNClientSession * session, MNClientSession
return RESULT_DEFAULT_HANDLER;
}}
-#line 438 "mn-imap-mailbox.c"
+#line 408 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 212 "mn-imap-mailbox.gob"
+#line 196 "mn-imap-mailbox.gob"
+static int
+mn_imap_mailbox_enter_starttls_cb (MNClientSession * session, MNClientSessionPrivate * priv)
+#line 414 "mn-imap-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_starttls_cb"
+#line 196 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (session != NULL, (int )0);
+#line 196 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (priv != NULL, (int )0);
+#line 421 "mn-imap-mailbox.c"
+{
+#line 199 "mn-imap-mailbox.gob"
+
+#ifdef WITH_SSL
+ return self_session_write(priv, "STARTTLS");
+#else
+ g_return_val_if_reached(0);
+#endif /* WITH_SSL */
+ }}
+#line 431 "mn-imap-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 207 "mn-imap-mailbox.gob"
+static int
+mn_imap_mailbox_handle_starttls_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
+#line 437 "mn-imap-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_starttls_cb"
+#line 207 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (session != NULL, (int )0);
+#line 207 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (response != NULL, (int )0);
+#line 207 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (priv != NULL, (int )0);
+#line 446 "mn-imap-mailbox.c"
+{
+#line 211 "mn-imap-mailbox.gob"
+
+#ifdef WITH_SSL
+ if (response->tag)
+ {
+ if (HAS_CURRENT_TAG(response, priv))
+ {
+ if (IS_OK(response))
+ {
+ priv->starttls_completed = TRUE;
+ return mn_client_session_enable_ssl(session)
+ ? STATE_CAPABILITY
+ : RESULT_ERROR_END;
+ }
+ else if (IS_BAD(response))
+ return self_session_authenticate(priv);
+ else
+ return MN_CLIENT_SESSION_RESULT_BAD_RESPONSE_FOR_CONTEXT;
+ }
+ }
+
+ return RESULT_DEFAULT_HANDLER;
+#else
+ g_return_val_if_reached(0);
+#endif /* WITH_SSL */
+ }}
+#line 474 "mn-imap-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 237 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_enter_authenticate_cb (MNClientSession * session, MNClientSessionPrivate * priv)
-#line 444 "mn-imap-mailbox.c"
+#line 480 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_authenticate_cb"
-#line 212 "mn-imap-mailbox.gob"
+#line 237 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 212 "mn-imap-mailbox.gob"
+#line 237 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 451 "mn-imap-mailbox.c"
+#line 487 "mn-imap-mailbox.c"
{
-#line 215 "mn-imap-mailbox.gob"
+#line 240 "mn-imap-mailbox.gob"
#ifdef WITH_SASL
if (mn_client_session_sasl_authentication_start(priv->session,
"imap",
priv->auth_mechanisms,
- priv->mailbox->_priv->authmech,
+ priv->mailbox->uri->authmech,
&priv->sasl_mechanism))
return self_session_write(priv, "AUTHENTICATE %s", priv->sasl_mechanism);
else
@@ -464,24 +500,24 @@ mn_imap_mailbox_enter_authenticate_cb (MNClientSession * session, MNClientSessio
g_return_val_if_reached(0);
#endif /* WITH_SASL */
}}
-#line 468 "mn-imap-mailbox.c"
+#line 504 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 230 "mn-imap-mailbox.gob"
+#line 255 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_authenticate_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 474 "mn-imap-mailbox.c"
+#line 510 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_authenticate_cb"
-#line 230 "mn-imap-mailbox.gob"
+#line 255 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 230 "mn-imap-mailbox.gob"
+#line 255 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 230 "mn-imap-mailbox.gob"
+#line 255 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 483 "mn-imap-mailbox.c"
+#line 519 "mn-imap-mailbox.c"
{
-#line 234 "mn-imap-mailbox.gob"
+#line 259 "mn-imap-mailbox.gob"
#ifdef WITH_SASL
if (response->tag)
@@ -508,37 +544,37 @@ mn_imap_mailbox_handle_authenticate_cb (MNClientSession * session, MNClientSessi
g_return_val_if_reached(0);
#endif /* WITH_SASL */
}}
-#line 512 "mn-imap-mailbox.c"
+#line 548 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 261 "mn-imap-mailbox.gob"
+#line 286 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_enter_login_cb (MNClientSession * session, MNClientSessionPrivate * priv)
-#line 518 "mn-imap-mailbox.c"
+#line 554 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_login_cb"
-#line 261 "mn-imap-mailbox.gob"
+#line 286 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 261 "mn-imap-mailbox.gob"
+#line 286 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 525 "mn-imap-mailbox.c"
+#line 561 "mn-imap-mailbox.c"
{
-#line 264 "mn-imap-mailbox.gob"
+#line 289 "mn-imap-mailbox.gob"
if (self_session_has_capability(priv, "LOGINDISABLED"))
- {
- mn_client_session_notice(session, _("server advertised LOGINDISABLED, not using LOGIN authentication"));
- mn_client_session_error(session, _("unable to login"));
- return STATE_LOGOUT;
- }
+ {
+ mn_client_session_notice(session, _("server advertised LOGINDISABLED, not using LOGIN authentication"));
+ mn_client_session_error(session, _("unable to login"));
+ return STATE_LOGOUT;
+ }
else
{
char *quoted_username;
char *quoted_password;
int result;
- quoted_username = self_quote(priv->mailbox->_priv->username);
- quoted_password = self_quote(priv->mailbox->_priv->password);
+ quoted_username = self_quote(priv->mailbox->uri->username);
+ quoted_password = self_quote(priv->mailbox->uri->password);
result = self_session_write(priv, "LOGIN %s %s", quoted_username, quoted_password);
g_free(quoted_username);
g_free(quoted_password);
@@ -546,24 +582,24 @@ mn_imap_mailbox_enter_login_cb (MNClientSession * session, MNClientSessionPrivat
return result;
}
}}
-#line 550 "mn-imap-mailbox.c"
+#line 586 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 287 "mn-imap-mailbox.gob"
+#line 312 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_login_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 556 "mn-imap-mailbox.c"
+#line 592 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_login_cb"
-#line 287 "mn-imap-mailbox.gob"
+#line 312 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 287 "mn-imap-mailbox.gob"
+#line 312 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 287 "mn-imap-mailbox.gob"
+#line 312 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 565 "mn-imap-mailbox.c"
+#line 601 "mn-imap-mailbox.c"
{
-#line 291 "mn-imap-mailbox.gob"
+#line 316 "mn-imap-mailbox.gob"
if (response->tag)
{
@@ -580,50 +616,50 @@ mn_imap_mailbox_handle_login_cb (MNClientSession * session, MNClientSessionRespo
return RESULT_DEFAULT_HANDLER;
}}
-#line 584 "mn-imap-mailbox.c"
+#line 620 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 308 "mn-imap-mailbox.gob"
+#line 333 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_enter_status_cb (MNClientSession * session, MNClientSessionPrivate * priv)
-#line 590 "mn-imap-mailbox.c"
+#line 626 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_status_cb"
-#line 308 "mn-imap-mailbox.gob"
+#line 333 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 308 "mn-imap-mailbox.gob"
+#line 333 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 597 "mn-imap-mailbox.c"
+#line 633 "mn-imap-mailbox.c"
{
-#line 311 "mn-imap-mailbox.gob"
+#line 336 "mn-imap-mailbox.gob"
char *quoted_mailbox;
int result;
- quoted_mailbox = self_quote(priv->mailbox->_priv->mailbox);
+ quoted_mailbox = self_quote(priv->mailbox->uri->path);
result = self_session_write(priv, "STATUS %s (UNSEEN)", quoted_mailbox);
g_free(quoted_mailbox);
return result;
}}
-#line 610 "mn-imap-mailbox.c"
+#line 646 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 322 "mn-imap-mailbox.gob"
+#line 347 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_status_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 616 "mn-imap-mailbox.c"
+#line 652 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_status_cb"
-#line 322 "mn-imap-mailbox.gob"
+#line 347 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 322 "mn-imap-mailbox.gob"
+#line 347 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 322 "mn-imap-mailbox.gob"
+#line 347 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 625 "mn-imap-mailbox.c"
+#line 661 "mn-imap-mailbox.c"
{
-#line 326 "mn-imap-mailbox.gob"
+#line 351 "mn-imap-mailbox.gob"
if (response->tag)
{
@@ -651,7 +687,7 @@ mn_imap_mailbox_handle_status_cb (MNClientSession * session, MNClientSessionResp
priv->status_received = TRUE;
GDK_THREADS_ENTER();
- mn_mailbox_set_has_new(MN_MAILBOX(priv->mailbox), count != 0);
+ mn_mailbox_set_has_new(priv->mailbox, count != 0);
gdk_flush();
GDK_THREADS_LEAVE();
@@ -663,43 +699,43 @@ mn_imap_mailbox_handle_status_cb (MNClientSession * session, MNClientSessionResp
return RESULT_DEFAULT_HANDLER;
}}
-#line 667 "mn-imap-mailbox.c"
+#line 703 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 366 "mn-imap-mailbox.gob"
+#line 391 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_enter_logout_cb (MNClientSession * session, MNClientSessionPrivate * priv)
-#line 673 "mn-imap-mailbox.c"
+#line 709 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::enter_logout_cb"
-#line 366 "mn-imap-mailbox.gob"
+#line 391 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 366 "mn-imap-mailbox.gob"
+#line 391 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 680 "mn-imap-mailbox.c"
+#line 716 "mn-imap-mailbox.c"
{
-#line 369 "mn-imap-mailbox.gob"
+#line 394 "mn-imap-mailbox.gob"
return self_session_write(priv, "LOGOUT");
}}
-#line 686 "mn-imap-mailbox.c"
+#line 722 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 373 "mn-imap-mailbox.gob"
+#line 398 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_handle_logout_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 692 "mn-imap-mailbox.c"
+#line 728 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::handle_logout_cb"
-#line 373 "mn-imap-mailbox.gob"
+#line 398 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 373 "mn-imap-mailbox.gob"
+#line 398 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 373 "mn-imap-mailbox.gob"
+#line 398 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 701 "mn-imap-mailbox.c"
+#line 737 "mn-imap-mailbox.c"
{
-#line 377 "mn-imap-mailbox.gob"
+#line 402 "mn-imap-mailbox.gob"
if (response->tag && HAS_CURRENT_TAG(response, priv))
{
@@ -713,30 +749,33 @@ mn_imap_mailbox_handle_logout_cb (MNClientSession * session, MNClientSessionResp
else
return MN_CLIENT_SESSION_RESULT_CONTINUE;
}}
-#line 717 "mn-imap-mailbox.c"
+#line 753 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 391 "mn-imap-mailbox.gob"
+#line 416 "mn-imap-mailbox.gob"
static void
-___f_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox G_GNUC_UNUSED)
-#line 723 "mn-imap-mailbox.c"
+___11_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox G_GNUC_UNUSED)
+#line 759 "mn-imap-mailbox.c"
#define PARENT_HANDLER(___mailbox) \
{ if(MN_MAILBOX_CLASS(parent_class)->impl_threaded_check) \
(* MN_MAILBOX_CLASS(parent_class)->impl_threaded_check)(___mailbox); }
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::impl_threaded_check"
-#line 391 "mn-imap-mailbox.gob"
+#line 416 "mn-imap-mailbox.gob"
g_return_if_fail (mailbox != NULL);
-#line 391 "mn-imap-mailbox.gob"
+#line 416 "mn-imap-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (mailbox));
-#line 733 "mn-imap-mailbox.c"
+#line 769 "mn-imap-mailbox.c"
{
-#line 393 "mn-imap-mailbox.gob"
+#line 418 "mn-imap-mailbox.gob"
Self *self = SELF(mailbox);
MNClientSessionState states[] = {
{ STATE_GREETING, NULL, self_handle_greeting_cb },
{ STATE_CAPABILITY, self_enter_capability_cb, self_handle_capability_cb },
+#ifdef WITH_SSL
+ { STATE_STARTTLS, self_enter_starttls_cb, self_handle_starttls_cb },
+#endif
#ifdef WITH_SASL
{ STATE_AUTHENTICATE, self_enter_authenticate_cb, self_handle_authenticate_cb },
#endif
@@ -756,17 +795,18 @@ ___f_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox G_GNUC_UNUSED)
GError *err = NULL;
memset(&priv, 0, sizeof(priv));
- priv.mailbox = self;
+ priv.mailbox = mailbox;
+ priv.self = self;
if (! mn_client_session_run(states,
&callbacks,
#ifdef WITH_SSL
- selfp->ssl,
+ MN_URI_IS_SSL(mailbox->uri),
#endif
- selfp->hostname,
- selfp->port,
- selfp->username,
- selfp->password,
+ mailbox->uri->hostname,
+ mailbox->uri->port,
+ mailbox->uri->username,
+ mailbox->uri->password,
&priv,
&err))
{
@@ -784,48 +824,48 @@ ___f_mn_imap_mailbox_impl_threaded_check (MNMailbox * mailbox G_GNUC_UNUSED)
g_free(priv.tag);
g_strfreev(priv.capabilities);
- mn_pointers_free(priv.auth_mechanisms);
+ eel_g_slist_free_deep(priv.auth_mechanisms);
}}
-#line 790 "mn-imap-mailbox.c"
+#line 830 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 448 "mn-imap-mailbox.gob"
+#line 477 "mn-imap-mailbox.gob"
static void
mn_imap_mailbox_notice_cb (MNClientSession * session, const char * str, MNClientSessionPrivate * priv)
-#line 797 "mn-imap-mailbox.c"
+#line 837 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::notice_cb"
-#line 448 "mn-imap-mailbox.gob"
+#line 477 "mn-imap-mailbox.gob"
g_return_if_fail (session != NULL);
-#line 448 "mn-imap-mailbox.gob"
+#line 477 "mn-imap-mailbox.gob"
g_return_if_fail (str != NULL);
-#line 448 "mn-imap-mailbox.gob"
+#line 477 "mn-imap-mailbox.gob"
g_return_if_fail (priv != NULL);
-#line 806 "mn-imap-mailbox.c"
+#line 846 "mn-imap-mailbox.c"
{
-#line 452 "mn-imap-mailbox.gob"
+#line 481 "mn-imap-mailbox.gob"
- mn_mailbox_notice(MN_MAILBOX(priv->mailbox), "%s", str);
+ mn_mailbox_notice(priv->mailbox, "%s", str);
}}
-#line 812 "mn-imap-mailbox.c"
+#line 852 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 456 "mn-imap-mailbox.gob"
+#line 485 "mn-imap-mailbox.gob"
static MNClientSessionResponse *
mn_imap_mailbox_response_new_cb (MNClientSession * session, const char * input, MNClientSessionPrivate * priv)
-#line 818 "mn-imap-mailbox.c"
+#line 858 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::response_new_cb"
-#line 456 "mn-imap-mailbox.gob"
+#line 485 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (MNClientSessionResponse * )0);
-#line 456 "mn-imap-mailbox.gob"
+#line 485 "mn-imap-mailbox.gob"
g_return_val_if_fail (input != NULL, (MNClientSessionResponse * )0);
-#line 456 "mn-imap-mailbox.gob"
+#line 485 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (MNClientSessionResponse * )0);
-#line 827 "mn-imap-mailbox.c"
+#line 867 "mn-imap-mailbox.c"
{
-#line 460 "mn-imap-mailbox.gob"
+#line 489 "mn-imap-mailbox.gob"
MNClientSessionResponse *response = NULL;
@@ -872,24 +912,24 @@ mn_imap_mailbox_response_new_cb (MNClientSession * session, const char * input,
return response;
}}
-#line 876 "mn-imap-mailbox.c"
+#line 916 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 507 "mn-imap-mailbox.gob"
+#line 536 "mn-imap-mailbox.gob"
static void
mn_imap_mailbox_response_free_cb (MNClientSession * session, MNClientSessionResponse * response, MNClientSessionPrivate * priv)
-#line 882 "mn-imap-mailbox.c"
+#line 922 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::response_free_cb"
-#line 507 "mn-imap-mailbox.gob"
+#line 536 "mn-imap-mailbox.gob"
g_return_if_fail (session != NULL);
-#line 507 "mn-imap-mailbox.gob"
+#line 536 "mn-imap-mailbox.gob"
g_return_if_fail (response != NULL);
-#line 507 "mn-imap-mailbox.gob"
+#line 536 "mn-imap-mailbox.gob"
g_return_if_fail (priv != NULL);
-#line 891 "mn-imap-mailbox.c"
+#line 931 "mn-imap-mailbox.c"
{
-#line 511 "mn-imap-mailbox.gob"
+#line 540 "mn-imap-mailbox.gob"
g_free(response->continuation);
g_free(response->tag);
@@ -898,24 +938,24 @@ mn_imap_mailbox_response_free_cb (MNClientSession * session, MNClientSessionResp
g_free(response->arguments);
g_free(response);
}}
-#line 902 "mn-imap-mailbox.c"
+#line 942 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 520 "mn-imap-mailbox.gob"
+#line 549 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_custom_handler_cb (MNClientSession * session, MNClientSessionResponse * response, int result, MNClientSessionPrivate * priv)
-#line 908 "mn-imap-mailbox.c"
+#line 948 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::custom_handler_cb"
-#line 520 "mn-imap-mailbox.gob"
+#line 549 "mn-imap-mailbox.gob"
g_return_val_if_fail (session != NULL, (int )0);
-#line 520 "mn-imap-mailbox.gob"
+#line 549 "mn-imap-mailbox.gob"
g_return_val_if_fail (response != NULL, (int )0);
-#line 520 "mn-imap-mailbox.gob"
+#line 549 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 917 "mn-imap-mailbox.c"
+#line 957 "mn-imap-mailbox.c"
{
-#line 525 "mn-imap-mailbox.gob"
+#line 554 "mn-imap-mailbox.gob"
switch (result)
{
@@ -937,44 +977,44 @@ mn_imap_mailbox_custom_handler_cb (MNClientSession * session, MNClientSessionRes
g_return_val_if_reached(0);
}
}}
-#line 941 "mn-imap-mailbox.c"
+#line 981 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 547 "mn-imap-mailbox.gob"
+#line 576 "mn-imap-mailbox.gob"
static void
mn_imap_mailbox_session_set_error_from_arguments (MNClientSessionPrivate * priv, MNClientSessionResponse * response)
-#line 947 "mn-imap-mailbox.c"
+#line 987 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_set_error_from_arguments"
-#line 547 "mn-imap-mailbox.gob"
+#line 576 "mn-imap-mailbox.gob"
g_return_if_fail (priv != NULL);
-#line 547 "mn-imap-mailbox.gob"
+#line 576 "mn-imap-mailbox.gob"
g_return_if_fail (response != NULL);
-#line 954 "mn-imap-mailbox.c"
+#line 994 "mn-imap-mailbox.c"
{
-#line 550 "mn-imap-mailbox.gob"
+#line 579 "mn-imap-mailbox.gob"
if (response->arguments)
mn_client_session_error(priv->session, "\"%s\"", response->arguments);
else
mn_client_session_error(priv->session, _("unknown server error"));
}}
-#line 963 "mn-imap-mailbox.c"
+#line 1003 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 557 "mn-imap-mailbox.gob"
+#line 586 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_session_write (MNClientSessionPrivate * priv, const char * format, ...)
-#line 969 "mn-imap-mailbox.c"
+#line 1009 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_write"
-#line 557 "mn-imap-mailbox.gob"
+#line 586 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 557 "mn-imap-mailbox.gob"
+#line 586 "mn-imap-mailbox.gob"
g_return_val_if_fail (format != NULL, (int )0);
-#line 976 "mn-imap-mailbox.c"
+#line 1016 "mn-imap-mailbox.c"
{
-#line 561 "mn-imap-mailbox.gob"
+#line 590 "mn-imap-mailbox.gob"
va_list args;
char *command;
@@ -995,20 +1035,20 @@ mn_imap_mailbox_session_write (MNClientSessionPrivate * priv, const char * forma
return result;
}}
-#line 999 "mn-imap-mailbox.c"
+#line 1039 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 582 "mn-imap-mailbox.gob"
+#line 611 "mn-imap-mailbox.gob"
static void
mn_imap_mailbox_session_parse_capabilities (MNClientSessionPrivate * priv, const char * capabilities)
-#line 1005 "mn-imap-mailbox.c"
+#line 1045 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_parse_capabilities"
-#line 582 "mn-imap-mailbox.gob"
+#line 611 "mn-imap-mailbox.gob"
g_return_if_fail (priv != NULL);
-#line 1010 "mn-imap-mailbox.c"
+#line 1050 "mn-imap-mailbox.c"
{
-#line 585 "mn-imap-mailbox.gob"
+#line 614 "mn-imap-mailbox.gob"
if (capabilities)
{
@@ -1023,22 +1063,22 @@ mn_imap_mailbox_session_parse_capabilities (MNClientSessionPrivate * priv, const
else
priv->capabilities = g_new0(char *, 1);
}}
-#line 1027 "mn-imap-mailbox.c"
+#line 1067 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 600 "mn-imap-mailbox.gob"
+#line 629 "mn-imap-mailbox.gob"
static gboolean
mn_imap_mailbox_session_has_capability (MNClientSessionPrivate * priv, const char * capability)
-#line 1033 "mn-imap-mailbox.c"
+#line 1073 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_has_capability"
-#line 600 "mn-imap-mailbox.gob"
+#line 629 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (gboolean )0);
-#line 600 "mn-imap-mailbox.gob"
+#line 629 "mn-imap-mailbox.gob"
g_return_val_if_fail (capability != NULL, (gboolean )0);
-#line 1040 "mn-imap-mailbox.c"
+#line 1080 "mn-imap-mailbox.c"
{
-#line 603 "mn-imap-mailbox.gob"
+#line 632 "mn-imap-mailbox.gob"
int i;
@@ -1050,24 +1090,56 @@ mn_imap_mailbox_session_has_capability (MNClientSessionPrivate * priv, const cha
return FALSE;
}}
-#line 1054 "mn-imap-mailbox.c"
+#line 1094 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 615 "mn-imap-mailbox.gob"
+#line 644 "mn-imap-mailbox.gob"
+static int
+mn_imap_mailbox_session_after_capability (MNClientSessionPrivate * priv)
+#line 1100 "mn-imap-mailbox.c"
+{
+#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_after_capability"
+#line 644 "mn-imap-mailbox.gob"
+ g_return_val_if_fail (priv != NULL, (int )0);
+#line 1105 "mn-imap-mailbox.c"
+{
+#line 646 "mn-imap-mailbox.gob"
+
+#ifdef WITH_SSL
+ if (MN_URI_IS_INBAND_SSL(priv->mailbox->uri)
+ && ! MN_URI_IS_SSL(priv->mailbox->uri)
+ && ! priv->starttls_completed)
+ {
+ if (self_session_has_capability(priv, "STARTTLS"))
+ return STATE_STARTTLS;
+ else
+ {
+ mn_client_session_error(priv->session, _("server does not support in-band SSL/TLS"));
+ return STATE_LOGOUT;
+ }
+ }
+ else
+#endif /* WITH_SSL */
+ return self_session_authenticate(priv);
+ }}
+#line 1126 "mn-imap-mailbox.c"
+#undef __GOB_FUNCTION__
+
+#line 665 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_session_authenticate (MNClientSessionPrivate * priv)
-#line 1060 "mn-imap-mailbox.c"
+#line 1132 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_authenticate"
-#line 615 "mn-imap-mailbox.gob"
+#line 665 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 1065 "mn-imap-mailbox.c"
+#line 1137 "mn-imap-mailbox.c"
{
-#line 617 "mn-imap-mailbox.gob"
+#line 667 "mn-imap-mailbox.gob"
- if (priv->mailbox->_priv->authmech)
+ if (priv->mailbox->uri->authmech)
{
- if (*priv->mailbox->_priv->authmech != '+')
+ if (*priv->mailbox->uri->authmech != '+')
{
#ifdef WITH_SASL
return STATE_AUTHENTICATE;
@@ -1077,10 +1149,10 @@ mn_imap_mailbox_session_authenticate (MNClientSessionPrivate * priv)
}
else
{
- if (! strcmp(priv->mailbox->_priv->authmech, "+LOGIN"))
+ if (! strcmp(priv->mailbox->uri->authmech, "+LOGIN"))
return STATE_LOGIN;
else
- return mn_client_session_error(priv->session, _("unknown authentication mechanism \"%s\""), priv->mailbox->_priv->authmech);
+ return mn_client_session_error(priv->session, _("unknown authentication mechanism \"%s\""), priv->mailbox->uri->authmech);
}
}
else
@@ -1092,22 +1164,22 @@ mn_imap_mailbox_session_authenticate (MNClientSessionPrivate * priv)
return STATE_LOGIN;
}
}}
-#line 1096 "mn-imap-mailbox.c"
+#line 1168 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
-#line 646 "mn-imap-mailbox.gob"
+#line 696 "mn-imap-mailbox.gob"
static int
mn_imap_mailbox_session_authenticate_fallback (MNClientSessionPrivate * priv)
-#line 1102 "mn-imap-mailbox.c"
+#line 1174 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::session_authenticate_fallback"
-#line 646 "mn-imap-mailbox.gob"
+#line 696 "mn-imap-mailbox.gob"
g_return_val_if_fail (priv != NULL, (int )0);
-#line 1107 "mn-imap-mailbox.c"
+#line 1179 "mn-imap-mailbox.c"
{
-#line 648 "mn-imap-mailbox.gob"
+#line 698 "mn-imap-mailbox.gob"
- if (! priv->mailbox->_priv->authmech)
+ if (! priv->mailbox->uri->authmech)
{
mn_client_session_notice(priv->session, _("falling back to IMAP LOGIN authentication"));
return STATE_LOGIN;
@@ -1115,7 +1187,7 @@ mn_imap_mailbox_session_authenticate_fallback (MNClientSessionPrivate * priv)
return mn_client_session_error(priv->session, _("authentication failed"));
}}
-#line 1119 "mn-imap-mailbox.c"
+#line 1191 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
/**
@@ -1126,17 +1198,17 @@ mn_imap_mailbox_session_authenticate_fallback (MNClientSessionPrivate * priv)
*
* Return value: the quoted string.
**/
-#line 666 "mn-imap-mailbox.gob"
+#line 716 "mn-imap-mailbox.gob"
static char *
mn_imap_mailbox_quote (const char * str)
-#line 1133 "mn-imap-mailbox.c"
+#line 1205 "mn-imap-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:IMAP:Mailbox::quote"
-#line 666 "mn-imap-mailbox.gob"
+#line 716 "mn-imap-mailbox.gob"
g_return_val_if_fail (str != NULL, (char * )0);
-#line 1138 "mn-imap-mailbox.c"
+#line 1210 "mn-imap-mailbox.c"
{
-#line 668 "mn-imap-mailbox.gob"
+#line 718 "mn-imap-mailbox.gob"
GString *quoted;
int i;
@@ -1151,5 +1223,5 @@ mn_imap_mailbox_quote (const char * str)
return g_string_free(quoted, FALSE);
}}
-#line 1155 "mn-imap-mailbox.c"
+#line 1227 "mn-imap-mailbox.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-imap-mailbox.gob b/src/mn-imap-mailbox.gob
@@ -29,9 +29,9 @@
#include <stdarg.h>
#include <glib/gi18n-lib.h>
#include <libgnomevfs/gnome-vfs-utils.h>
+#include <eel/eel.h>
#include "mn-mailbox-private.h"
#include "mn-util.h"
-#include "mn-uri.h"
#include "mn-client-session.h"
#define HAS_CURRENT_TAG(response, priv) (! strcmp((response)->tag, (priv)->tag))
@@ -45,6 +45,9 @@
{
STATE_GREETING = MN_CLIENT_SESSION_INITIAL_STATE,
STATE_CAPABILITY,
+#ifdef WITH_SSL
+ STATE_STARTTLS,
+#endif
#ifdef WITH_SASL
STATE_AUTHENTICATE,
#endif
@@ -62,18 +65,22 @@
struct _MNClientSessionPrivate
{
- MNIMAPMailbox *mailbox;
+ MNMailbox *mailbox;
+ MNIMAPMailbox *self;
MNClientSession *session;
int numeric_tag;
char *tag;
char **capabilities;
GSList *auth_mechanisms;
gboolean status_received;
+#ifdef WITH_SSL
+ gboolean starttls_completed;
+#endif
#ifdef WITH_SASL
const char *sasl_mechanism;
#endif
};
-
+
struct _MNClientSessionResponse
{
char *continuation;
@@ -86,14 +93,6 @@
class MN:IMAP:Mailbox from MN:Mailbox
{
- private char *hostname destroywith g_free;
- private int port;
- private char *username destroywith g_free;
- private char *password destroywith g_free;
- private char *authmech destroywith g_free;
- private char *mailbox destroywith g_free;
- private gboolean ssl;
-
class_init (class)
{
MN_MAILBOX_CLASS(class)->format = "IMAP";
@@ -104,43 +103,22 @@ class MN:IMAP:Mailbox from MN:Mailbox
{
GObject *object;
MNMailbox *mailbox;
- Self *self;
object = PARENT_HANDLER(type, n_construct_properties, construct_params);
mailbox = MN_MAILBOX(object);
- self = SELF(object);
-
- if (mn_uri_parse_imap(mn_mailbox_get_uri(mailbox),
- &selfp->ssl,
- &selfp->username,
- &selfp->password,
- &selfp->authmech,
- &selfp->hostname,
- &selfp->port,
- &selfp->mailbox))
- {
+
#ifndef WITH_SSL
- if (selfp->ssl)
- mn_mailbox_set_init_error(mailbox, _("SSL support has not been compiled in"));
+ if (MN_URI_IS_SSL(mailbox->uri) || MN_URI_IS_INBAND_SSL(mailbox->uri))
+ mn_mailbox_set_init_error(mailbox, _("SSL/TLS support has not been compiled in"));
#endif /* WITH_SSL */
- }
- else
- mn_mailbox_set_init_error(mailbox, _("unable to parse IMAP URI"));
return object;
}
override (MN:Mailbox) gboolean
- impl_is (MNMailbox *dummy, const char *uri (check null))
+ impl_is (MNMailbox *dummy, MN:URI *uri (check null type))
{
- char *scheme;
- gboolean is;
-
- scheme = gnome_vfs_get_uri_scheme(uri);
- is = scheme && (! strcmp(scheme, "imap") || ! strcmp(scheme, "imaps"));
- g_free(scheme);
-
- return is;
+ return MN_URI_IS_IMAP(uri);
}
private int
@@ -161,7 +139,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
}
return priv->capabilities
- ? self_session_authenticate(priv)
+ ? self_session_after_capability(priv)
: STATE_CAPABILITY;
}
else if (! response->tag && IS(response, "PREAUTH"))
@@ -176,6 +154,12 @@ class MN:IMAP:Mailbox from MN:Mailbox
enter_capability_cb (MNClientSession *session (check null),
MNClientSessionPrivate *priv (check null))
{
+ g_strfreev(priv->capabilities);
+ priv->capabilities = NULL;
+
+ eel_g_slist_free_deep(priv->auth_mechanisms);
+ priv->auth_mechanisms = NULL;
+
return self_session_write(priv, "CAPABILITY");
}
@@ -191,7 +175,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
if (IS_OK(response))
{
return priv->capabilities
- ? self_session_authenticate(priv)
+ ? self_session_after_capability(priv)
: mn_client_session_error(session, _("server did not send capabilities"));
}
else if (IS_BAD(response))
@@ -210,6 +194,47 @@ class MN:IMAP:Mailbox from MN:Mailbox
}
private int
+ enter_starttls_cb (MNClientSession *session (check null),
+ MNClientSessionPrivate *priv (check null))
+ {
+#ifdef WITH_SSL
+ return self_session_write(priv, "STARTTLS");
+#else
+ g_return_val_if_reached(0);
+#endif /* WITH_SSL */
+ }
+
+ private int
+ handle_starttls_cb (MNClientSession *session (check null),
+ MNClientSessionResponse *response (check null),
+ MNClientSessionPrivate *priv (check null))
+ {
+#ifdef WITH_SSL
+ if (response->tag)
+ {
+ if (HAS_CURRENT_TAG(response, priv))
+ {
+ if (IS_OK(response))
+ {
+ priv->starttls_completed = TRUE;
+ return mn_client_session_enable_ssl(session)
+ ? STATE_CAPABILITY
+ : RESULT_ERROR_END;
+ }
+ else if (IS_BAD(response))
+ return self_session_authenticate(priv);
+ else
+ return MN_CLIENT_SESSION_RESULT_BAD_RESPONSE_FOR_CONTEXT;
+ }
+ }
+
+ return RESULT_DEFAULT_HANDLER;
+#else
+ g_return_val_if_reached(0);
+#endif /* WITH_SSL */
+ }
+
+ private int
enter_authenticate_cb (MNClientSession *session (check null),
MNClientSessionPrivate *priv (check null))
{
@@ -217,7 +242,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
if (mn_client_session_sasl_authentication_start(priv->session,
"imap",
priv->auth_mechanisms,
- priv->mailbox->_priv->authmech,
+ priv->mailbox->uri->authmech,
&priv->sasl_mechanism))
return self_session_write(priv, "AUTHENTICATE %s", priv->sasl_mechanism);
else
@@ -263,19 +288,19 @@ class MN:IMAP:Mailbox from MN:Mailbox
MNClientSessionPrivate *priv (check null))
{
if (self_session_has_capability(priv, "LOGINDISABLED"))
- {
- mn_client_session_notice(session, _("server advertised LOGINDISABLED, not using LOGIN authentication"));
- mn_client_session_error(session, _("unable to login"));
- return STATE_LOGOUT;
- }
+ {
+ mn_client_session_notice(session, _("server advertised LOGINDISABLED, not using LOGIN authentication"));
+ mn_client_session_error(session, _("unable to login"));
+ return STATE_LOGOUT;
+ }
else
{
char *quoted_username;
char *quoted_password;
int result;
- quoted_username = self_quote(priv->mailbox->_priv->username);
- quoted_password = self_quote(priv->mailbox->_priv->password);
+ quoted_username = self_quote(priv->mailbox->uri->username);
+ quoted_password = self_quote(priv->mailbox->uri->password);
result = self_session_write(priv, "LOGIN %s %s", quoted_username, quoted_password);
g_free(quoted_username);
g_free(quoted_password);
@@ -312,7 +337,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
char *quoted_mailbox;
int result;
- quoted_mailbox = self_quote(priv->mailbox->_priv->mailbox);
+ quoted_mailbox = self_quote(priv->mailbox->uri->path);
result = self_session_write(priv, "STATUS %s (UNSEEN)", quoted_mailbox);
g_free(quoted_mailbox);
@@ -350,7 +375,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
priv->status_received = TRUE;
GDK_THREADS_ENTER();
- mn_mailbox_set_has_new(MN_MAILBOX(priv->mailbox), count != 0);
+ mn_mailbox_set_has_new(priv->mailbox, count != 0);
gdk_flush();
GDK_THREADS_LEAVE();
@@ -395,6 +420,9 @@ class MN:IMAP:Mailbox from MN:Mailbox
MNClientSessionState states[] = {
{ STATE_GREETING, NULL, self_handle_greeting_cb },
{ STATE_CAPABILITY, self_enter_capability_cb, self_handle_capability_cb },
+#ifdef WITH_SSL
+ { STATE_STARTTLS, self_enter_starttls_cb, self_handle_starttls_cb },
+#endif
#ifdef WITH_SASL
{ STATE_AUTHENTICATE, self_enter_authenticate_cb, self_handle_authenticate_cb },
#endif
@@ -414,17 +442,18 @@ class MN:IMAP:Mailbox from MN:Mailbox
GError *err = NULL;
memset(&priv, 0, sizeof(priv));
- priv.mailbox = self;
+ priv.mailbox = mailbox;
+ priv.self = self;
if (! mn_client_session_run(states,
&callbacks,
#ifdef WITH_SSL
- selfp->ssl,
+ MN_URI_IS_SSL(mailbox->uri),
#endif
- selfp->hostname,
- selfp->port,
- selfp->username,
- selfp->password,
+ mailbox->uri->hostname,
+ mailbox->uri->port,
+ mailbox->uri->username,
+ mailbox->uri->password,
&priv,
&err))
{
@@ -442,7 +471,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
g_free(priv.tag);
g_strfreev(priv.capabilities);
- mn_pointers_free(priv.auth_mechanisms);
+ eel_g_slist_free_deep(priv.auth_mechanisms);
}
private void
@@ -450,7 +479,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
const char *str (check null),
MNClientSessionPrivate *priv (check null))
{
- mn_mailbox_notice(MN_MAILBOX(priv->mailbox), "%s", str);
+ mn_mailbox_notice(priv->mailbox, "%s", str);
}
private MNClientSessionResponse *
@@ -613,11 +642,32 @@ class MN:IMAP:Mailbox from MN:Mailbox
}
private int
+ session_after_capability (MNClientSessionPrivate *priv (check null))
+ {
+#ifdef WITH_SSL
+ if (MN_URI_IS_INBAND_SSL(priv->mailbox->uri)
+ && ! MN_URI_IS_SSL(priv->mailbox->uri)
+ && ! priv->starttls_completed)
+ {
+ if (self_session_has_capability(priv, "STARTTLS"))
+ return STATE_STARTTLS;
+ else
+ {
+ mn_client_session_error(priv->session, _("server does not support in-band SSL/TLS"));
+ return STATE_LOGOUT;
+ }
+ }
+ else
+#endif /* WITH_SSL */
+ return self_session_authenticate(priv);
+ }
+
+ private int
session_authenticate (MNClientSessionPrivate *priv (check null))
{
- if (priv->mailbox->_priv->authmech)
+ if (priv->mailbox->uri->authmech)
{
- if (*priv->mailbox->_priv->authmech != '+')
+ if (*priv->mailbox->uri->authmech != '+')
{
#ifdef WITH_SASL
return STATE_AUTHENTICATE;
@@ -627,10 +677,10 @@ class MN:IMAP:Mailbox from MN:Mailbox
}
else
{
- if (! strcmp(priv->mailbox->_priv->authmech, "+LOGIN"))
+ if (! strcmp(priv->mailbox->uri->authmech, "+LOGIN"))
return STATE_LOGIN;
else
- return mn_client_session_error(priv->session, _("unknown authentication mechanism \"%s\""), priv->mailbox->_priv->authmech);
+ return mn_client_session_error(priv->session, _("unknown authentication mechanism \"%s\""), priv->mailbox->uri->authmech);
}
}
else
@@ -646,7 +696,7 @@ class MN:IMAP:Mailbox from MN:Mailbox
private int
session_authenticate_fallback (MNClientSessionPrivate *priv (check null))
{
- if (! priv->mailbox->_priv->authmech)
+ if (! priv->mailbox->uri->authmech)
{
mn_client_session_notice(priv->session, _("falling back to IMAP LOGIN authentication"));
return STATE_LOGIN;
diff --git a/src/mn-imap-mailbox.h b/src/mn-imap-mailbox.h
@@ -25,9 +25,6 @@ extern "C" {
#define MN_IMAP_MAILBOX_GET_CLASS(obj) G_TYPE_INSTANCE_GET_CLASS((obj), mn_imap_mailbox_get_type(), MNIMAPMailboxClass)
-/* Private structure type */
-typedef struct _MNIMAPMailboxPrivate MNIMAPMailboxPrivate;
-
/*
* Main object structure
*/
@@ -37,8 +34,6 @@ typedef struct _MNIMAPMailbox MNIMAPMailbox;
#endif
struct _MNIMAPMailbox {
MNMailbox __parent__;
- /*< private >*/
- MNIMAPMailboxPrivate *_priv;
};
/*
diff --git a/src/mn-mail-icon.c b/src/mn-mail-icon.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
diff --git a/src/mn-mailbox-private.h b/src/mn-mailbox-private.h
@@ -10,7 +10,7 @@ extern "C" {
#endif /* __cplusplus */
-#line 23 "mn-mailbox.gob"
+#line 24 "mn-mailbox.gob"
#include <libgnomevfs/gnome-vfs.h>
@@ -26,27 +26,25 @@ extern "C" {
#line 28 "mn-mailbox-private.h"
struct _MNMailboxPrivate {
-#line 87 "mn-mailbox.gob"
- char * uri;
-#line 97 "mn-mailbox.gob"
+#line 132 "mn-mailbox.gob"
char * name;
-#line 101 "mn-mailbox.gob"
+#line 136 "mn-mailbox.gob"
gboolean automatic;
-#line 106 "mn-mailbox.gob"
+#line 141 "mn-mailbox.gob"
gboolean has_new;
-#line 111 "mn-mailbox.gob"
+#line 146 "mn-mailbox.gob"
char * error;
-#line 131 "mn-mailbox.gob"
+#line 166 "mn-mailbox.gob"
GnomeVFSMonitorHandle * monitor_handle;
-#line 132 "mn-mailbox.gob"
+#line 167 "mn-mailbox.gob"
char * monitor_uri;
-#line 133 "mn-mailbox.gob"
+#line 168 "mn-mailbox.gob"
MNMailboxMonitorEventType monitor_events;
-#line 135 "mn-mailbox.gob"
+#line 170 "mn-mailbox.gob"
gboolean checking;
-#line 276 "mn-mailbox.gob"
+#line 310 "mn-mailbox.gob"
char * init_error;
-#line 50 "mn-mailbox-private.h"
+#line 48 "mn-mailbox-private.h"
};
void mn_mailbox_set_error (MNMailbox * self, const char * format, ...);
void mn_mailbox_set_init_error (MNMailbox * self, const char * format, ...);
diff --git a/src/mn-mailbox-properties-dialog.c b/src/mn-mailbox-properties-dialog.c
@@ -33,8 +33,8 @@
#endif
#include "mn-conf.h"
#include "mn-util.h"
-#include "mn-uri.h"
#include "mn-stock.h"
+#include "mn-mailboxes.h"
/*** types *******************************************************************/
@@ -45,7 +45,7 @@ typedef struct
GtkWidget *properties_event_box;
MNMailboxPropertiesDialogMode mode;
- char *uri;
+ MNURI *uri;
GtkWidget *apply_button;
GtkWidget *accept_button;
GtkListStore *store;
@@ -73,7 +73,7 @@ static void mn_mailbox_properties_dialog_set_active_properties (MNMailboxPropert
static MNMailboxProperties *mn_mailbox_properties_dialog_get_active_properties (MNMailboxPropertiesDialog *dialog);
static MNMailboxProperties *mn_mailbox_properties_dialog_get_properties_by_type (MNMailboxPropertiesDialog *dialog, GType type);
-static void mn_mailbox_properties_dialog_set_uri_internal (MNMailboxPropertiesDialog *dialog, const char *uri);
+static void mn_mailbox_properties_dialog_set_uri_internal (MNMailboxPropertiesDialog *dialog, MNURI *uri);
static void mn_mailbox_properties_dialog_update_sensitivity (MNMailboxPropertiesDialog *dialog);
/*** implementation **********************************************************/
@@ -168,7 +168,8 @@ mn_mailbox_properties_dialog_private_free (Private *private)
{
g_return_if_fail(private != NULL);
- g_free(private->uri);
+ if (private->uri)
+ g_object_unref(private->uri);
g_object_unref(private->store);
g_free(private);
}
@@ -314,30 +315,27 @@ mn_mailbox_properties_dialog_get_properties_by_type (MNMailboxPropertiesDialog *
static void
mn_mailbox_properties_dialog_set_uri_internal (MNMailboxPropertiesDialog *dialog,
- const char *uri)
+ MNURI *uri)
{
Private *private;
- char *name;
char *title;
g_return_if_fail(MN_IS_MAILBOX_PROPERTIES_DIALOG(dialog));
- g_return_if_fail(uri != NULL);
+ g_return_if_fail(MN_IS_URI(uri));
private = MN_MAILBOX_PROPERTIES_DIALOG_PRIVATE(dialog);
- g_free(private->uri);
- private->uri = g_strdup(uri);
-
- name = mn_uri_format_for_display(private->uri);
- title = g_strdup_printf(_("%s Properties"), name);
- g_free(name);
+ if (private->uri)
+ g_object_unref(private->uri);
+ private->uri = g_object_ref(uri);
+ title = g_strdup_printf(_("%s Properties"), uri->human_readable);
gtk_window_set_title(GTK_WINDOW(dialog), title);
g_free(title);
}
void
mn_mailbox_properties_dialog_set_uri (MNMailboxPropertiesDialog *dialog,
- const char *uri)
+ MNURI *uri)
{
Private *private;
gboolean valid;
@@ -375,7 +373,7 @@ mn_mailbox_properties_dialog_set_uri (MNMailboxPropertiesDialog *dialog,
mn_mailbox_properties_dialog_set_active_properties(dialog, properties);
}
-char *
+MNURI *
mn_mailbox_properties_dialog_get_uri (MNMailboxPropertiesDialog *dialog)
{
Private *private;
@@ -392,34 +390,34 @@ void
mn_mailbox_properties_dialog_apply (MNMailboxPropertiesDialog *dialog)
{
Private *private;
- char *new_uri;
+ MNURI *new_uri;
g_return_if_fail(MN_IS_MAILBOX_PROPERTIES_DIALOG(dialog));
private = MN_MAILBOX_PROPERTIES_DIALOG_PRIVATE(dialog);
new_uri = mn_mailbox_properties_dialog_get_uri(dialog);
- g_return_if_fail(new_uri != NULL);
+ g_return_if_fail(MN_IS_URI(new_uri));
- if (mn_uri_cmp(new_uri, private->uri))
+ if (strcmp(new_uri->text, private->uri->text))
{
GSList *gconf_mailboxes;
GSList *elem;
gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
- elem = g_slist_find_custom(gconf_mailboxes, private->uri, (GCompareFunc) mn_uri_cmp);
+ elem = mn_mailboxes_conf_find_uri(gconf_mailboxes, private->uri);
if (elem)
{
g_free(elem->data);
- elem->data = g_strdup(new_uri);
+ elem->data = g_strdup(new_uri->text);
}
eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
mn_mailbox_properties_dialog_set_uri_internal(dialog, new_uri);
}
- g_free(new_uri);
+ g_object_unref(new_uri);
}
static void
diff --git a/src/mn-mailbox-properties-dialog.h b/src/mn-mailbox-properties-dialog.h
@@ -20,6 +20,7 @@
#define _MN_MAILBOX_PROPERTIES_DIALOG_H
#include <gtk/gtk.h>
+#include "mn-uri.h"
#define MN_MAILBOX_PROPERTIES_DIALOG_PRIVATE_KEY "mn-mailbox-properties-dialog-private"
#define MN_MAILBOX_PROPERTIES_DIALOG_PRIVATE(obj) (g_object_get_data(G_OBJECT(obj), MN_MAILBOX_PROPERTIES_DIALOG_PRIVATE_KEY))
@@ -44,8 +45,8 @@ GtkWidget *mn_mailbox_properties_dialog_new (GtkWindow *parent,
MNMailboxPropertiesDialogMode mode);
void mn_mailbox_properties_dialog_set_uri (MNMailboxPropertiesDialog *dialog,
- const char *uri);
-char *mn_mailbox_properties_dialog_get_uri (MNMailboxPropertiesDialog *dialog);
+ MNURI *uri);
+MNURI *mn_mailbox_properties_dialog_get_uri (MNMailboxPropertiesDialog *dialog);
void mn_mailbox_properties_dialog_apply (MNMailboxPropertiesDialog *dialog);
diff --git a/src/mn-mailbox-properties-util.c b/src/mn-mailbox-properties-util.c
@@ -65,6 +65,8 @@ mn_mailbox_properties_credentials_new (GtkVBox *vbox,
GtkWidget **password_label,
GtkWidget **password_entry)
{
+ const char *username;
+
g_return_if_fail(GTK_IS_VBOX(vbox));
g_return_if_fail(username_label != NULL);
g_return_if_fail(username_entry != NULL);
@@ -75,6 +77,12 @@ mn_mailbox_properties_credentials_new (GtkVBox *vbox,
_("_Username:"),
username_label,
username_entry);
+
+ /* defaults to the login name */
+ username = g_get_user_name();
+ if (username)
+ gtk_entry_set_text(GTK_ENTRY(*username_entry), username);
+
mn_mailbox_properties_field_new(vbox,
_("_Password:"),
password_label,
@@ -153,6 +161,7 @@ mn_mailbox_properties_connection_type_new (GtkVBox *vbox,
port_label = gtk_label_new(_("Port:"));
*spin = gtk_spin_button_new_with_range(0, 0xFFFF, 1);
+ gtk_entry_set_activates_default(GTK_ENTRY(*spin), TRUE);
gtk_spin_button_set_value(GTK_SPIN_BUTTON(*spin), default_port);
gtk_spin_button_set_numeric(GTK_SPIN_BUTTON(*spin), TRUE);
diff --git a/src/mn-mailbox-properties.c b/src/mn-mailbox-properties.c
@@ -104,15 +104,15 @@ mn_mailbox_properties_get_label (MNMailboxProperties *properties)
gboolean
mn_mailbox_properties_set_uri (MNMailboxProperties *properties,
- const char *uri)
+ MNURI *uri)
{
g_return_val_if_fail(MN_IS_MAILBOX_PROPERTIES(properties), FALSE);
- g_return_val_if_fail(uri != NULL, FALSE);
+ g_return_val_if_fail(MN_IS_URI(uri), FALSE);
return MN_MAILBOX_PROPERTIES_GET_IFACE(properties)->set_uri(properties, uri);
}
-char *
+MNURI *
mn_mailbox_properties_get_uri (MNMailboxProperties *properties)
{
g_return_val_if_fail(MN_IS_MAILBOX_PROPERTIES(properties), NULL);
diff --git a/src/mn-mailbox-properties.h b/src/mn-mailbox-properties.h
@@ -20,6 +20,7 @@
#define _MN_MAILBOX_PROPERTIES_H
#include <glib-object.h>
+#include "mn-uri.h"
#define MN_TYPE_MAILBOX_PROPERTIES (mn_mailbox_properties_get_type ())
#define MN_MAILBOX_PROPERTIES(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), MN_TYPE_MAILBOX_PROPERTIES, MNMailboxProperties))
@@ -33,8 +34,8 @@ typedef struct
GTypeInterface parent;
gboolean (* set_uri) (MNMailboxProperties *properties,
- const char *uri);
- char * (* get_uri) (MNMailboxProperties *properties);
+ MNURI *uri);
+ MNURI * (* get_uri) (MNMailboxProperties *properties);
} MNMailboxPropertiesIface;
GType mn_mailbox_properties_get_type (void);
@@ -42,7 +43,7 @@ GType mn_mailbox_properties_get_type (void);
GtkSizeGroup *mn_mailbox_properties_get_size_group (MNMailboxProperties *properties);
char *mn_mailbox_properties_get_label (MNMailboxProperties *properties);
gboolean mn_mailbox_properties_set_uri (MNMailboxProperties *properties,
- const char *uri);
-char *mn_mailbox_properties_get_uri (MNMailboxProperties *properties);
+ MNURI *uri);
+MNURI *mn_mailbox_properties_get_uri (MNMailboxProperties *properties);
#endif /* _MN_MAILBOX_PROPERTIES_H */
diff --git a/src/mn-mailbox-view-private.h b/src/mn-mailbox-view-private.h
@@ -10,17 +10,17 @@ extern "C" {
#endif /* __cplusplus */
struct _MNMailboxViewPrivate {
-#line 50 "mn-mailbox-view.gob"
+#line 49 "mn-mailbox-view.gob"
GtkWidget * menu;
-#line 51 "mn-mailbox-view.gob"
+#line 50 "mn-mailbox-view.gob"
GtkWidget * remove_item;
-#line 52 "mn-mailbox-view.gob"
+#line 51 "mn-mailbox-view.gob"
GtkWidget * cut_item;
-#line 53 "mn-mailbox-view.gob"
+#line 52 "mn-mailbox-view.gob"
GtkWidget * copy_item;
-#line 54 "mn-mailbox-view.gob"
+#line 53 "mn-mailbox-view.gob"
GtkWidget * paste_item;
-#line 55 "mn-mailbox-view.gob"
+#line 54 "mn-mailbox-view.gob"
GtkWidget * properties_item;
#line 26 "mn-mailbox-view-private.h"
};
diff --git a/src/mn-mailbox-view.c b/src/mn-mailbox-view.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -33,7 +33,6 @@
#include "mn-stock.h"
#include "mn-mailbox-properties-dialog.h"
#include "mn-conf.h"
-#include "mn-dialog.h"
#include "mn-uri.h"
#define GNOME_COPIED_FILES "x-special/gnome-copied-files"
@@ -49,7 +48,7 @@
static GtkClipboard *global_clipboard;
static GdkAtom gnome_copied_files_atom;
-#line 53 "mn-mailbox-view.c"
+#line 52 "mn-mailbox-view.c"
/* self casting macros */
#define SELF(x) MN_MAILBOX_VIEW(x)
#define SELF_CONST(x) MN_MAILBOX_VIEW_CONST(x)
@@ -86,7 +85,8 @@ static void mn_mailbox_view_copy_mailbox_cb (GtkTreeModel * model, GtkTreePath *
static void mn_mailbox_view_get_clipboard_cb (GtkClipboard * clipboard, GtkSelectionData * selection_data, unsigned int info, gpointer user_data_or_owner) G_GNUC_UNUSED;
static void mn_mailbox_view_clear_clipboard_cb (GtkClipboard * clipboard, gpointer user_data_or_owner) G_GNUC_UNUSED;
static void mn_mailbox_view_select_all (MNMailboxView * self) G_GNUC_UNUSED;
-static void mn_mailbox_view_properties_response_h (GtkDialog * dialog, int response, gpointer user_data) G_GNUC_UNUSED;
+static void mn_mailbox_view_properties_add_response_h (GtkDialog * dialog, int response, gpointer user_data) G_GNUC_UNUSED;
+static void mn_mailbox_view_properties_edit_response_h (GtkDialog * dialog, int response, gpointer user_data) G_GNUC_UNUSED;
static void mn_mailbox_view_popup_menu (MNMailboxView * self, unsigned int button, guint32 activate_time) G_GNUC_UNUSED;
static void mn_mailbox_view_popup_menu_receive_cb (GtkClipboard * clipboard, GtkSelectionData * selection_data, gpointer data) G_GNUC_UNUSED;
static gboolean mn_mailbox_view_popup_menu_h (GtkWidget * widget, gpointer user_data) G_GNUC_UNUSED;
@@ -150,7 +150,8 @@ static GtkTreeViewClass *parent_class = NULL;
#define self_get_clipboard_cb mn_mailbox_view_get_clipboard_cb
#define self_clear_clipboard_cb mn_mailbox_view_clear_clipboard_cb
#define self_select_all mn_mailbox_view_select_all
-#define self_properties_response_h mn_mailbox_view_properties_response_h
+#define self_properties_add_response_h mn_mailbox_view_properties_add_response_h
+#define self_properties_edit_response_h mn_mailbox_view_properties_edit_response_h
#define self_popup_menu mn_mailbox_view_popup_menu
#define self_popup_menu_receive_cb mn_mailbox_view_popup_menu_receive_cb
#define self_popup_menu_h mn_mailbox_view_popup_menu_h
@@ -206,20 +207,20 @@ ___finalize(GObject *obj_self)
#define __GOB_FUNCTION__ "MN:Mailbox:View::finalize"
MNMailboxView *self G_GNUC_UNUSED = MN_MAILBOX_VIEW (obj_self);
gpointer priv = self->_priv;
-#line 322 "mn-mailbox-view.gob"
+#line 293 "mn-mailbox-view.gob"
___b_mn_mailbox_view_finalize(obj_self);
-#line 212 "mn-mailbox-view.c"
-#line 50 "mn-mailbox-view.gob"
+#line 213 "mn-mailbox-view.c"
+#line 49 "mn-mailbox-view.gob"
if(self->_priv->menu) { ((*(void (*)(void *))gtk_widget_destroy)) (self->_priv->menu); self->_priv->menu = NULL; }
-#line 215 "mn-mailbox-view.c"
+#line 216 "mn-mailbox-view.c"
g_free (priv);
}
#undef __GOB_FUNCTION__
-#line 214 "mn-mailbox-view.gob"
+#line 185 "mn-mailbox-view.gob"
static void
mn_mailbox_view_class_init (MNMailboxViewClass * class G_GNUC_UNUSED)
-#line 223 "mn-mailbox-view.c"
+#line 224 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::class_init"
GObjectClass *g_object_class G_GNUC_UNUSED = (GObjectClass*) class;
@@ -275,23 +276,23 @@ mn_mailbox_view_class_init (MNMailboxViewClass * class G_GNUC_UNUSED)
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-#line 57 "mn-mailbox-view.gob"
+#line 56 "mn-mailbox-view.gob"
class->activate_add = ___real_mn_mailbox_view_activate_add;
-#line 102 "mn-mailbox-view.gob"
+#line 73 "mn-mailbox-view.gob"
class->activate_remove = ___real_mn_mailbox_view_activate_remove;
-#line 108 "mn-mailbox-view.gob"
+#line 79 "mn-mailbox-view.gob"
class->activate_cut = ___real_mn_mailbox_view_activate_cut;
-#line 115 "mn-mailbox-view.gob"
+#line 86 "mn-mailbox-view.gob"
class->activate_copy = ___real_mn_mailbox_view_activate_copy;
-#line 121 "mn-mailbox-view.gob"
+#line 92 "mn-mailbox-view.gob"
class->activate_paste = ___real_mn_mailbox_view_activate_paste;
-#line 179 "mn-mailbox-view.gob"
+#line 150 "mn-mailbox-view.gob"
class->activate_properties = ___real_mn_mailbox_view_activate_properties;
-#line 322 "mn-mailbox-view.gob"
+#line 293 "mn-mailbox-view.gob"
g_object_class->finalize = ___finalize;
-#line 293 "mn-mailbox-view.c"
+#line 294 "mn-mailbox-view.c"
{
-#line 215 "mn-mailbox-view.gob"
+#line 186 "mn-mailbox-view.gob"
GtkBindingSet *binding_set;
@@ -319,22 +320,22 @@ mn_mailbox_view_class_init (MNMailboxViewClass * class G_GNUC_UNUSED)
gtk_binding_entry_add_signal(binding_set, GDK_ISO_Enter, GDK_MOD1_MASK, "activate-properties", 0);
gtk_binding_entry_add_signal(binding_set, GDK_KP_Enter, GDK_MOD1_MASK, "activate-properties", 0);
-#line 323 "mn-mailbox-view.c"
+#line 324 "mn-mailbox-view.c"
}
}
#undef __GOB_FUNCTION__
-#line 243 "mn-mailbox-view.gob"
+#line 214 "mn-mailbox-view.gob"
static void
mn_mailbox_view_init (MNMailboxView * self G_GNUC_UNUSED)
-#line 330 "mn-mailbox-view.c"
+#line 331 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::init"
self->_priv = g_new0 (MNMailboxViewPrivate, 1);
-#line 50 "mn-mailbox-view.gob"
+#line 49 "mn-mailbox-view.gob"
self->_priv->menu = gtk_menu_new();
-#line 336 "mn-mailbox-view.c"
+#line 337 "mn-mailbox-view.c"
{
-#line 244 "mn-mailbox-view.gob"
+#line 215 "mn-mailbox-view.gob"
GtkMenuShell *shell;
GtkWidget *add_item;
@@ -366,7 +367,7 @@ mn_mailbox_view_init (MNMailboxView * self G_GNUC_UNUSED)
g_signal_connect_swapped(G_OBJECT(selfp->properties_item), "activate", G_CALLBACK(self_activate_properties), self);
store = gtk_list_store_new(N_COLUMNS,
- G_TYPE_STRING,
+ MN_TYPE_URI,
G_TYPE_STRING,
G_TYPE_STRING,
G_TYPE_STRING);
@@ -412,15 +413,15 @@ mn_mailbox_view_init (MNMailboxView * self G_GNUC_UNUSED)
g_signal_connect(G_OBJECT(self), "button-press-event", G_CALLBACK(self_button_press_event_h), NULL);
g_signal_connect(G_OBJECT(self), "row-activated", G_CALLBACK(self_row_activated_h), NULL);
-#line 416 "mn-mailbox-view.c"
+#line 417 "mn-mailbox-view.c"
}
}
#undef __GOB_FUNCTION__
-#line 57 "mn-mailbox-view.gob"
+#line 56 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_add (MNMailboxView * self)
-#line 424 "mn-mailbox-view.c"
+#line 425 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -428,11 +429,11 @@ mn_mailbox_view_activate_add (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 57 "mn-mailbox-view.gob"
+#line 56 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 57 "mn-mailbox-view.gob"
+#line 56 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 436 "mn-mailbox-view.c"
+#line 437 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -445,14 +446,14 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 57 "mn-mailbox-view.gob"
+#line 56 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_add (MNMailboxView * self G_GNUC_UNUSED)
-#line 452 "mn-mailbox-view.c"
+#line 453 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_add"
{
-#line 59 "mn-mailbox-view.gob"
+#line 58 "mn-mailbox-view.gob"
GtkWidget *toplevel;
GtkWidget *dialog;
@@ -460,48 +461,20 @@ ___real_mn_mailbox_view_activate_add (MNMailboxView * self G_GNUC_UNUSED)
toplevel = gtk_widget_get_toplevel(GTK_WIDGET(self));
dialog = mn_mailbox_properties_dialog_new((GtkWindow *) toplevel, MN_MAILBOX_PROPERTIES_DIALOG_MODE_ADD);
- run:
- switch (gtk_dialog_run(GTK_DIALOG(dialog)))
- {
- case GTK_RESPONSE_HELP:
- mn_display_help("mailbox-properties");
- goto run;
-
- case GTK_RESPONSE_ACCEPT:
- {
- char *uri;
-
- uri = mn_mailbox_properties_dialog_get_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog));
- g_return_if_fail(uri != NULL);
-
- if (! mn_mailboxes_find(mn_shell->mailboxes, uri))
- {
- GSList *gconf_mailboxes;
-
- gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
- gconf_mailboxes = g_slist_append(gconf_mailboxes, uri);
- eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
- }
- else
- {
- mn_error_dialog(NULL, _("Unable to add mailbox"), _("The mailbox is already in the list."));
- g_free(uri);
- goto run;
- }
- }
- break;
- }
-
- gtk_widget_destroy(dialog);
+ g_signal_connect(G_OBJECT(dialog),
+ "response",
+ G_CALLBACK(self_properties_add_response_h),
+ NULL);
+
+ gtk_widget_show(dialog);
}}
-#line 499 "mn-mailbox-view.c"
+#line 472 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 102 "mn-mailbox-view.gob"
+#line 73 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_remove (MNMailboxView * self)
-#line 505 "mn-mailbox-view.c"
+#line 478 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -509,11 +482,11 @@ mn_mailbox_view_activate_remove (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 102 "mn-mailbox-view.gob"
+#line 73 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 102 "mn-mailbox-view.gob"
+#line 73 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 517 "mn-mailbox-view.c"
+#line 490 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -526,24 +499,24 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 102 "mn-mailbox-view.gob"
+#line 73 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_remove (MNMailboxView * self G_GNUC_UNUSED)
-#line 533 "mn-mailbox-view.c"
+#line 506 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_remove"
{
-#line 104 "mn-mailbox-view.gob"
+#line 75 "mn-mailbox-view.gob"
self_remove_mailbox(self);
}}
-#line 541 "mn-mailbox-view.c"
+#line 514 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 108 "mn-mailbox-view.gob"
+#line 79 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_cut (MNMailboxView * self)
-#line 547 "mn-mailbox-view.c"
+#line 520 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -551,11 +524,11 @@ mn_mailbox_view_activate_cut (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 108 "mn-mailbox-view.gob"
+#line 79 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 108 "mn-mailbox-view.gob"
+#line 79 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 559 "mn-mailbox-view.c"
+#line 532 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -568,25 +541,25 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 108 "mn-mailbox-view.gob"
+#line 79 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_cut (MNMailboxView * self G_GNUC_UNUSED)
-#line 575 "mn-mailbox-view.c"
+#line 548 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_cut"
{
-#line 110 "mn-mailbox-view.gob"
+#line 81 "mn-mailbox-view.gob"
self_copy_mailbox(self);
self_remove_mailbox(self);
}}
-#line 584 "mn-mailbox-view.c"
+#line 557 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 115 "mn-mailbox-view.gob"
+#line 86 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_copy (MNMailboxView * self)
-#line 590 "mn-mailbox-view.c"
+#line 563 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -594,11 +567,11 @@ mn_mailbox_view_activate_copy (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 115 "mn-mailbox-view.gob"
+#line 86 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 115 "mn-mailbox-view.gob"
+#line 86 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 602 "mn-mailbox-view.c"
+#line 575 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -611,24 +584,24 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 115 "mn-mailbox-view.gob"
+#line 86 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_copy (MNMailboxView * self G_GNUC_UNUSED)
-#line 618 "mn-mailbox-view.c"
+#line 591 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_copy"
{
-#line 117 "mn-mailbox-view.gob"
+#line 88 "mn-mailbox-view.gob"
self_copy_mailbox(self);
}}
-#line 626 "mn-mailbox-view.c"
+#line 599 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 121 "mn-mailbox-view.gob"
+#line 92 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_paste (MNMailboxView * self)
-#line 632 "mn-mailbox-view.c"
+#line 605 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -636,11 +609,11 @@ mn_mailbox_view_activate_paste (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 121 "mn-mailbox-view.gob"
+#line 92 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 121 "mn-mailbox-view.gob"
+#line 92 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 644 "mn-mailbox-view.c"
+#line 617 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -653,36 +626,36 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 121 "mn-mailbox-view.gob"
+#line 92 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_paste (MNMailboxView * self G_GNUC_UNUSED)
-#line 660 "mn-mailbox-view.c"
+#line 633 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_paste"
{
-#line 123 "mn-mailbox-view.gob"
+#line 94 "mn-mailbox-view.gob"
gtk_clipboard_request_contents(global_clipboard,
gnome_copied_files_atom,
self_activate_paste_receive_cb,
NULL);
}}
-#line 671 "mn-mailbox-view.c"
+#line 644 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 130 "mn-mailbox-view.gob"
+#line 101 "mn-mailbox-view.gob"
static void
mn_mailbox_view_activate_paste_receive_cb (GtkClipboard * clipboard, GtkSelectionData * selection_data, gpointer data)
-#line 677 "mn-mailbox-view.c"
+#line 650 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_paste_receive_cb"
-#line 130 "mn-mailbox-view.gob"
+#line 101 "mn-mailbox-view.gob"
g_return_if_fail (clipboard != NULL);
-#line 130 "mn-mailbox-view.gob"
+#line 101 "mn-mailbox-view.gob"
g_return_if_fail (selection_data != NULL);
-#line 684 "mn-mailbox-view.c"
+#line 657 "mn-mailbox-view.c"
{
-#line 134 "mn-mailbox-view.gob"
+#line 105 "mn-mailbox-view.gob"
if (selection_data->type == gnome_copied_files_atom
&& selection_data->format == 8
@@ -719,21 +692,21 @@ mn_mailbox_view_activate_paste_receive_cb (GtkClipboard * clipboard, GtkSelectio
gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
gconf_mailboxes = g_slist_concat(gconf_mailboxes, new_mailboxes);
eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
}
}
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
}
}
}}
-#line 731 "mn-mailbox-view.c"
+#line 704 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 179 "mn-mailbox-view.gob"
+#line 150 "mn-mailbox-view.gob"
void
mn_mailbox_view_activate_properties (MNMailboxView * self)
-#line 737 "mn-mailbox-view.c"
+#line 710 "mn-mailbox-view.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -741,11 +714,11 @@ mn_mailbox_view_activate_properties (MNMailboxView * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 179 "mn-mailbox-view.gob"
+#line 150 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 179 "mn-mailbox-view.gob"
+#line 150 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 749 "mn-mailbox-view.c"
+#line 722 "mn-mailbox-view.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -758,109 +731,108 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 179 "mn-mailbox-view.gob"
+#line 150 "mn-mailbox-view.gob"
static void
___real_mn_mailbox_view_activate_properties (MNMailboxView * self G_GNUC_UNUSED)
-#line 765 "mn-mailbox-view.c"
+#line 738 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_properties"
{
-#line 181 "mn-mailbox-view.gob"
+#line 152 "mn-mailbox-view.gob"
GtkTreeSelection *selection;
selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(self));
gtk_tree_selection_selected_foreach(selection, self_activate_properties_cb, self);
}}
-#line 776 "mn-mailbox-view.c"
+#line 749 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
static void
mn_mailbox_view_activate_properties_cb (GtkTreeModel * model, GtkTreePath * path, GtkTreeIter * iter, gpointer data)
-#line 782 "mn-mailbox-view.c"
+#line 755 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::activate_properties_cb"
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
g_return_if_fail (model != NULL);
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_TREE_MODEL (model));
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
g_return_if_fail (path != NULL);
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
g_return_if_fail (iter != NULL);
-#line 188 "mn-mailbox-view.gob"
+#line 159 "mn-mailbox-view.gob"
g_return_if_fail (data != NULL);
-#line 795 "mn-mailbox-view.c"
+#line 768 "mn-mailbox-view.c"
{
-#line 193 "mn-mailbox-view.gob"
+#line 164 "mn-mailbox-view.gob"
Self *self = data;
GtkWidget *toplevel;
GtkWidget *dialog;
- char *uri;
+ MNURI *uri;
toplevel = gtk_widget_get_toplevel(GTK_WIDGET(self));
dialog = mn_mailbox_properties_dialog_new((GtkWindow *) toplevel, MN_MAILBOX_PROPERTIES_DIALOG_MODE_EDIT);
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
mn_mailbox_properties_dialog_set_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog), uri);
- g_free(uri);
+ g_object_unref(uri);
g_signal_connect(G_OBJECT(dialog),
"response",
- G_CALLBACK(self_properties_response_h),
+ G_CALLBACK(self_properties_edit_response_h),
NULL);
gtk_widget_show(dialog);
}}
-#line 818 "mn-mailbox-view.c"
+#line 791 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 322 "mn-mailbox-view.gob"
+#line 293 "mn-mailbox-view.gob"
static void
___b_mn_mailbox_view_finalize (GObject * object G_GNUC_UNUSED)
-#line 826 "mn-mailbox-view.c"
+#line 799 "mn-mailbox-view.c"
#define PARENT_HANDLER(___object) \
{ if(G_OBJECT_CLASS(parent_class)->finalize) \
(* G_OBJECT_CLASS(parent_class)->finalize)(___object); }
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::finalize"
-#line 322 "mn-mailbox-view.gob"
+#line 293 "mn-mailbox-view.gob"
g_return_if_fail (object != NULL);
-#line 322 "mn-mailbox-view.gob"
+#line 293 "mn-mailbox-view.gob"
g_return_if_fail (G_IS_OBJECT (object));
-#line 836 "mn-mailbox-view.c"
+#line 809 "mn-mailbox-view.c"
{
-#line 324 "mn-mailbox-view.gob"
+#line 295 "mn-mailbox-view.gob"
g_signal_handlers_disconnect_by_func(mn_shell->mailboxes, self_update, object);
PARENT_HANDLER(object);
}}
-#line 843 "mn-mailbox-view.c"
+#line 816 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
#undef PARENT_HANDLER
-#line 329 "mn-mailbox-view.gob"
+#line 300 "mn-mailbox-view.gob"
static void
mn_mailbox_view_update (MNMailboxView * self)
-#line 850 "mn-mailbox-view.c"
+#line 823 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::update"
-#line 329 "mn-mailbox-view.gob"
+#line 300 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 329 "mn-mailbox-view.gob"
+#line 300 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 857 "mn-mailbox-view.c"
+#line 830 "mn-mailbox-view.c"
{
-#line 331 "mn-mailbox-view.gob"
+#line 302 "mn-mailbox-view.gob"
GtkTreeModel *model;
GtkTreeIter iter;
gboolean valid;
- MNMailbox *mailbox;
GSList *l;
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
@@ -870,15 +842,16 @@ mn_mailbox_view_update (MNMailboxView * self)
valid = gtk_tree_model_get_iter_first(model, &iter);
while (valid)
{
- char *uri;
+ MNURI *uri;
+ GSList *elem;
gtk_tree_model_get(model, &iter, COLUMN_URI, &uri, -1);
- mailbox = mn_mailboxes_find(mn_shell->mailboxes, uri);
- g_free(uri);
+ elem = mn_mailboxes_find_uri(mn_shell->mailboxes, uri);
+ g_object_unref(uri);
- if (mailbox)
+ if (elem)
{
- self_update_iter(self, &iter, mailbox);
+ self_update_iter(self, &iter, elem->data);
valid = gtk_tree_model_iter_next(model, &iter);
}
else
@@ -889,7 +862,7 @@ mn_mailbox_view_update (MNMailboxView * self)
MN_LIST_FOREACH(l, mn_mailboxes_get(mn_shell->mailboxes))
{
- mailbox = l->data;
+ MNMailbox *mailbox = l->data;
if (! self_has_mailbox(self, mailbox))
{
@@ -898,95 +871,88 @@ mn_mailbox_view_update (MNMailboxView * self)
}
}
}}
-#line 902 "mn-mailbox-view.c"
+#line 875 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
static void
mn_mailbox_view_update_iter (MNMailboxView * self, GtkTreeIter * iter, MNMailbox * mailbox)
-#line 908 "mn-mailbox-view.c"
+#line 881 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::update_iter"
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
g_return_if_fail (iter != NULL);
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
g_return_if_fail (mailbox != NULL);
-#line 374 "mn-mailbox-view.gob"
+#line 345 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX (mailbox));
-#line 921 "mn-mailbox-view.c"
+#line 894 "mn-mailbox-view.c"
{
-#line 378 "mn-mailbox-view.gob"
+#line 349 "mn-mailbox-view.gob"
MNMailboxClass *class;
- const char *uri;
- const char *system_uri;
const char *stock_id;
GtkTreeModel *model;
class = MN_MAILBOX_GET_CLASS(mailbox);
- uri = mn_mailbox_get_uri(mailbox);
- system_uri = mn_uri_get_system_mailbox();
- if (system_uri && ! mn_uri_cmp(uri, system_uri))
+ if (MN_URI_IS_SYSTEM_MAILBOX(mailbox->uri))
stock_id = MN_STOCK_SYSTEM_MAILBOX;
else
{
if (class->stock_id)
stock_id = class->stock_id;
else
- stock_id = mn_uri_is_local(uri) ? MN_STOCK_LOCAL : MN_STOCK_REMOTE;
+ stock_id = MN_URI_IS_LOCAL(mailbox->uri) ? MN_STOCK_LOCAL : MN_STOCK_REMOTE;
}
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
gtk_list_store_set(GTK_LIST_STORE(model), iter,
- COLUMN_URI, uri,
+ COLUMN_URI, mailbox->uri,
COLUMN_MAILBOX_ICON, stock_id,
COLUMN_MAILBOX, mn_mailbox_get_name(mailbox),
COLUMN_FORMAT, class->format,
-1);
}}
-#line 953 "mn-mailbox-view.c"
+#line 922 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 408 "mn-mailbox-view.gob"
+#line 375 "mn-mailbox-view.gob"
static gboolean
mn_mailbox_view_has_mailbox (MNMailboxView * self, MNMailbox * mailbox)
-#line 959 "mn-mailbox-view.c"
+#line 928 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::has_mailbox"
-#line 408 "mn-mailbox-view.gob"
+#line 375 "mn-mailbox-view.gob"
g_return_val_if_fail (self != NULL, (gboolean )0);
-#line 408 "mn-mailbox-view.gob"
+#line 375 "mn-mailbox-view.gob"
g_return_val_if_fail (MN_IS_MAILBOX_VIEW (self), (gboolean )0);
-#line 408 "mn-mailbox-view.gob"
+#line 375 "mn-mailbox-view.gob"
g_return_val_if_fail (mailbox != NULL, (gboolean )0);
-#line 408 "mn-mailbox-view.gob"
+#line 375 "mn-mailbox-view.gob"
g_return_val_if_fail (MN_IS_MAILBOX (mailbox), (gboolean )0);
-#line 970 "mn-mailbox-view.c"
+#line 939 "mn-mailbox-view.c"
{
-#line 410 "mn-mailbox-view.gob"
+#line 377 "mn-mailbox-view.gob"
- const char *uri;
GtkTreeModel *model;
GtkTreeIter iter;
gboolean valid;
gboolean has = FALSE;
- uri = mn_mailbox_get_uri(mailbox);
-
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
valid = gtk_tree_model_get_iter_first(model, &iter);
while (valid)
{
- char *this_uri;
+ MNURI *uri;
- gtk_tree_model_get(model, &iter, COLUMN_URI, &this_uri, -1);
- has = ! mn_uri_cmp(this_uri, uri);
- g_free(this_uri);
+ gtk_tree_model_get(model, &iter, COLUMN_URI, &uri, -1);
+ has = ! strcmp(uri->text, mailbox->uri->text);
+ g_object_unref(uri);
if (has)
break;
@@ -996,22 +962,22 @@ mn_mailbox_view_has_mailbox (MNMailboxView * self, MNMailbox * mailbox)
return has;
}}
-#line 1000 "mn-mailbox-view.c"
+#line 966 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 438 "mn-mailbox-view.gob"
+#line 402 "mn-mailbox-view.gob"
static void
mn_mailbox_view_update_sensitivity (MNMailboxView * self)
-#line 1006 "mn-mailbox-view.c"
+#line 972 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::update_sensitivity"
-#line 438 "mn-mailbox-view.gob"
+#line 402 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 438 "mn-mailbox-view.gob"
+#line 402 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 1013 "mn-mailbox-view.c"
+#line 979 "mn-mailbox-view.c"
{
-#line 440 "mn-mailbox-view.gob"
+#line 404 "mn-mailbox-view.gob"
GtkTreeSelection *selection;
gboolean has_selection;
@@ -1024,22 +990,22 @@ mn_mailbox_view_update_sensitivity (MNMailboxView * self)
gtk_widget_set_sensitive(selfp->copy_item, has_selection);
gtk_widget_set_sensitive(selfp->properties_item, has_selection);
}}
-#line 1028 "mn-mailbox-view.c"
+#line 994 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 453 "mn-mailbox-view.gob"
+#line 417 "mn-mailbox-view.gob"
static void
mn_mailbox_view_remove_mailbox (MNMailboxView * self)
-#line 1034 "mn-mailbox-view.c"
+#line 1000 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::remove_mailbox"
-#line 453 "mn-mailbox-view.gob"
+#line 417 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 453 "mn-mailbox-view.gob"
+#line 417 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 1041 "mn-mailbox-view.c"
+#line 1007 "mn-mailbox-view.c"
{
-#line 455 "mn-mailbox-view.gob"
+#line 419 "mn-mailbox-view.gob"
GtkTreeSelection *selection;
GSList *gconf_mailboxes;
@@ -1049,63 +1015,59 @@ mn_mailbox_view_remove_mailbox (MNMailboxView * self)
selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(self));
gtk_tree_selection_selected_foreach(selection, self_remove_mailbox_cb, &gconf_mailboxes);
eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
}}
-#line 1055 "mn-mailbox-view.c"
+#line 1021 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
static void
mn_mailbox_view_remove_mailbox_cb (GtkTreeModel * model, GtkTreePath * path, GtkTreeIter * iter, gpointer data)
-#line 1061 "mn-mailbox-view.c"
+#line 1027 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::remove_mailbox_cb"
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
g_return_if_fail (model != NULL);
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_TREE_MODEL (model));
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
g_return_if_fail (path != NULL);
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
g_return_if_fail (iter != NULL);
-#line 467 "mn-mailbox-view.gob"
+#line 431 "mn-mailbox-view.gob"
g_return_if_fail (data != NULL);
-#line 1074 "mn-mailbox-view.c"
+#line 1040 "mn-mailbox-view.c"
{
-#line 472 "mn-mailbox-view.gob"
+#line 436 "mn-mailbox-view.gob"
GSList **gconf_mailboxes = data;
- char *uri;
+ MNURI *uri;
GSList *elem;
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
/* remove all the mailboxes with that URI */
- while ((elem = g_slist_find_custom(*gconf_mailboxes, uri, (GCompareFunc) mn_uri_cmp)))
- {
- *gconf_mailboxes = g_slist_remove_link(*gconf_mailboxes, elem);
- g_free(elem->data);
- g_slist_free(elem);
- }
+ while ((elem = mn_mailboxes_conf_find_uri(*gconf_mailboxes, uri)))
+ *gconf_mailboxes = mn_g_slist_delete_link_deep(*gconf_mailboxes, elem);
- g_free(uri);
+ g_object_unref(uri);
}}
-#line 1094 "mn-mailbox-view.c"
+#line 1056 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 490 "mn-mailbox-view.gob"
+#line 450 "mn-mailbox-view.gob"
static void
mn_mailbox_view_copy_mailbox (MNMailboxView * self)
-#line 1100 "mn-mailbox-view.c"
+#line 1062 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::copy_mailbox"
-#line 490 "mn-mailbox-view.gob"
+#line 450 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 490 "mn-mailbox-view.gob"
+#line 450 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 1107 "mn-mailbox-view.c"
+#line 1069 "mn-mailbox-view.c"
{
-#line 492 "mn-mailbox-view.gob"
+#line 452 "mn-mailbox-view.gob"
GtkTreeSelection *selection;
GSList *uri_list = NULL;
@@ -1117,7 +1079,7 @@ mn_mailbox_view_copy_mailbox (MNMailboxView * self)
gtk_tree_selection_selected_foreach(selection, self_copy_mailbox_cb, &uri_list);
gnome_copied_files = mn_build_gnome_copied_files(MN_GNOME_COPIED_FILES_COPY, uri_list);
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
status = gtk_clipboard_set_with_data(global_clipboard,
&target,
@@ -1127,116 +1089,161 @@ mn_mailbox_view_copy_mailbox (MNMailboxView * self)
gnome_copied_files);
g_return_if_fail(status == TRUE);
}}
-#line 1131 "mn-mailbox-view.c"
+#line 1093 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
static void
mn_mailbox_view_copy_mailbox_cb (GtkTreeModel * model, GtkTreePath * path, GtkTreeIter * iter, gpointer data)
-#line 1137 "mn-mailbox-view.c"
+#line 1099 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::copy_mailbox_cb"
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
g_return_if_fail (model != NULL);
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_TREE_MODEL (model));
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
g_return_if_fail (path != NULL);
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
g_return_if_fail (iter != NULL);
-#line 514 "mn-mailbox-view.gob"
+#line 474 "mn-mailbox-view.gob"
g_return_if_fail (data != NULL);
-#line 1150 "mn-mailbox-view.c"
+#line 1112 "mn-mailbox-view.c"
{
-#line 519 "mn-mailbox-view.gob"
+#line 479 "mn-mailbox-view.gob"
GSList **uri_list = data;
- char *uri;
+ MNURI *uri;
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
- *uri_list = g_slist_append(*uri_list, uri);
- /* uri is now owned by uri_list, do not free */
+ *uri_list = g_slist_append(*uri_list, g_strdup(uri->text));
+ g_object_unref(uri);
}}
-#line 1161 "mn-mailbox-view.c"
+#line 1123 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 528 "mn-mailbox-view.gob"
+#line 488 "mn-mailbox-view.gob"
static void
mn_mailbox_view_get_clipboard_cb (GtkClipboard * clipboard, GtkSelectionData * selection_data, unsigned int info, gpointer user_data_or_owner)
-#line 1167 "mn-mailbox-view.c"
+#line 1129 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::get_clipboard_cb"
-#line 528 "mn-mailbox-view.gob"
+#line 488 "mn-mailbox-view.gob"
g_return_if_fail (clipboard != NULL);
-#line 528 "mn-mailbox-view.gob"
+#line 488 "mn-mailbox-view.gob"
g_return_if_fail (selection_data != NULL);
-#line 528 "mn-mailbox-view.gob"
+#line 488 "mn-mailbox-view.gob"
g_return_if_fail (user_data_or_owner != NULL);
-#line 1176 "mn-mailbox-view.c"
+#line 1138 "mn-mailbox-view.c"
{
-#line 533 "mn-mailbox-view.gob"
+#line 493 "mn-mailbox-view.gob"
const char *gnome_copied_files = user_data_or_owner;
gtk_selection_data_set(selection_data, gnome_copied_files_atom, 8, gnome_copied_files, strlen(gnome_copied_files));
}}
-#line 1183 "mn-mailbox-view.c"
+#line 1145 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 538 "mn-mailbox-view.gob"
+#line 498 "mn-mailbox-view.gob"
static void
mn_mailbox_view_clear_clipboard_cb (GtkClipboard * clipboard, gpointer user_data_or_owner)
-#line 1189 "mn-mailbox-view.c"
+#line 1151 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::clear_clipboard_cb"
-#line 538 "mn-mailbox-view.gob"
+#line 498 "mn-mailbox-view.gob"
g_return_if_fail (clipboard != NULL);
-#line 538 "mn-mailbox-view.gob"
+#line 498 "mn-mailbox-view.gob"
g_return_if_fail (user_data_or_owner != NULL);
-#line 1196 "mn-mailbox-view.c"
+#line 1158 "mn-mailbox-view.c"
{
-#line 541 "mn-mailbox-view.gob"
+#line 501 "mn-mailbox-view.gob"
char *gnome_copied_files = user_data_or_owner;
g_free(gnome_copied_files);
}}
-#line 1203 "mn-mailbox-view.c"
+#line 1165 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 546 "mn-mailbox-view.gob"
+#line 506 "mn-mailbox-view.gob"
static void
mn_mailbox_view_select_all (MNMailboxView * self)
-#line 1209 "mn-mailbox-view.c"
+#line 1171 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::select_all"
-#line 546 "mn-mailbox-view.gob"
+#line 506 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 546 "mn-mailbox-view.gob"
+#line 506 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 1216 "mn-mailbox-view.c"
+#line 1178 "mn-mailbox-view.c"
{
-#line 548 "mn-mailbox-view.gob"
+#line 508 "mn-mailbox-view.gob"
GtkTreeSelection *selection;
selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(self));
gtk_tree_selection_select_all(selection);
}}
-#line 1225 "mn-mailbox-view.c"
+#line 1187 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 555 "mn-mailbox-view.gob"
+#line 515 "mn-mailbox-view.gob"
static void
-mn_mailbox_view_properties_response_h (GtkDialog * dialog, int response, gpointer user_data)
-#line 1231 "mn-mailbox-view.c"
+mn_mailbox_view_properties_add_response_h (GtkDialog * dialog, int response, gpointer user_data)
+#line 1193 "mn-mailbox-view.c"
{
-#define __GOB_FUNCTION__ "MN:Mailbox:View::properties_response_h"
-#line 555 "mn-mailbox-view.gob"
+#define __GOB_FUNCTION__ "MN:Mailbox:View::properties_add_response_h"
+#line 515 "mn-mailbox-view.gob"
g_return_if_fail (dialog != NULL);
-#line 555 "mn-mailbox-view.gob"
+#line 515 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_DIALOG (dialog));
+#line 1200 "mn-mailbox-view.c"
+{
+#line 519 "mn-mailbox-view.gob"
+
+ if (response == GTK_RESPONSE_HELP)
+ mn_display_help("mailbox-properties");
+ else if (response == GTK_RESPONSE_CANCEL)
+ gtk_widget_destroy(GTK_WIDGET(dialog));
+ else if (response == GTK_RESPONSE_ACCEPT)
+ {
+ MNURI *uri;
+
+ uri = mn_mailbox_properties_dialog_get_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog));
+ g_return_if_fail(MN_IS_URI(uri));
+
+ if (! mn_mailboxes_find_uri(mn_shell->mailboxes, uri))
+ {
+ GSList *gconf_mailboxes;
+
+ gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
+ gconf_mailboxes = g_slist_append(gconf_mailboxes, g_strdup(uri->text));
+ eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
+
+ gtk_widget_destroy(GTK_WIDGET(dialog));
+ }
+ else
+ mn_error_dialog(NULL, _("Unable to add mailbox"), _("The mailbox is already in the list."));
+
+ g_object_unref(uri);
+ }
+ }}
+#line 1232 "mn-mailbox-view.c"
+#undef __GOB_FUNCTION__
+
+#line 549 "mn-mailbox-view.gob"
+static void
+mn_mailbox_view_properties_edit_response_h (GtkDialog * dialog, int response, gpointer user_data)
#line 1238 "mn-mailbox-view.c"
{
-#line 559 "mn-mailbox-view.gob"
+#define __GOB_FUNCTION__ "MN:Mailbox:View::properties_edit_response_h"
+#line 549 "mn-mailbox-view.gob"
+ g_return_if_fail (dialog != NULL);
+#line 549 "mn-mailbox-view.gob"
+ g_return_if_fail (GTK_IS_DIALOG (dialog));
+#line 1245 "mn-mailbox-view.c"
+{
+#line 553 "mn-mailbox-view.gob"
if (response == GTK_RESPONSE_HELP)
mn_display_help("mailbox-properties");
@@ -1248,22 +1255,22 @@ mn_mailbox_view_properties_response_h (GtkDialog * dialog, int response, gpointe
gtk_widget_destroy(GTK_WIDGET(dialog));
}
}}
-#line 1252 "mn-mailbox-view.c"
+#line 1259 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 571 "mn-mailbox-view.gob"
+#line 565 "mn-mailbox-view.gob"
static void
mn_mailbox_view_popup_menu (MNMailboxView * self, unsigned int button, guint32 activate_time)
-#line 1258 "mn-mailbox-view.c"
+#line 1265 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::popup_menu"
-#line 571 "mn-mailbox-view.gob"
+#line 565 "mn-mailbox-view.gob"
g_return_if_fail (self != NULL);
-#line 571 "mn-mailbox-view.gob"
+#line 565 "mn-mailbox-view.gob"
g_return_if_fail (MN_IS_MAILBOX_VIEW (self));
-#line 1265 "mn-mailbox-view.c"
+#line 1272 "mn-mailbox-view.c"
{
-#line 573 "mn-mailbox-view.gob"
+#line 567 "mn-mailbox-view.gob"
gtk_clipboard_request_contents(global_clipboard,
gnome_copied_files_atom,
@@ -1271,24 +1278,24 @@ mn_mailbox_view_popup_menu (MNMailboxView * self, unsigned int button, guint32 a
self);
gtk_menu_popup(GTK_MENU(selfp->menu), NULL, NULL, NULL, NULL, button, activate_time);
}}
-#line 1275 "mn-mailbox-view.c"
+#line 1282 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 581 "mn-mailbox-view.gob"
+#line 575 "mn-mailbox-view.gob"
static void
mn_mailbox_view_popup_menu_receive_cb (GtkClipboard * clipboard, GtkSelectionData * selection_data, gpointer data)
-#line 1281 "mn-mailbox-view.c"
+#line 1288 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::popup_menu_receive_cb"
-#line 581 "mn-mailbox-view.gob"
+#line 575 "mn-mailbox-view.gob"
g_return_if_fail (clipboard != NULL);
-#line 581 "mn-mailbox-view.gob"
+#line 575 "mn-mailbox-view.gob"
g_return_if_fail (selection_data != NULL);
-#line 581 "mn-mailbox-view.gob"
+#line 575 "mn-mailbox-view.gob"
g_return_if_fail (data != NULL);
-#line 1290 "mn-mailbox-view.c"
+#line 1297 "mn-mailbox-view.c"
{
-#line 585 "mn-mailbox-view.gob"
+#line 579 "mn-mailbox-view.gob"
Self *self = data;
gboolean can_paste = FALSE;
@@ -1310,94 +1317,95 @@ mn_mailbox_view_popup_menu_receive_cb (GtkClipboard * clipboard, GtkSelectionDat
{
if (type == MN_GNOME_COPIED_FILES_COPY && uri_list)
can_paste = TRUE;
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
}
}
gtk_widget_set_sensitive(selfp->paste_item, can_paste);
}}
-#line 1320 "mn-mailbox-view.c"
+#line 1327 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 613 "mn-mailbox-view.gob"
+#line 607 "mn-mailbox-view.gob"
static gboolean
mn_mailbox_view_popup_menu_h (GtkWidget * widget, gpointer user_data)
-#line 1326 "mn-mailbox-view.c"
+#line 1333 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::popup_menu_h"
-#line 613 "mn-mailbox-view.gob"
+#line 607 "mn-mailbox-view.gob"
g_return_val_if_fail (widget != NULL, (gboolean )0);
-#line 613 "mn-mailbox-view.gob"
+#line 607 "mn-mailbox-view.gob"
g_return_val_if_fail (GTK_IS_WIDGET (widget), (gboolean )0);
-#line 1333 "mn-mailbox-view.c"
+#line 1340 "mn-mailbox-view.c"
{
-#line 616 "mn-mailbox-view.gob"
+#line 610 "mn-mailbox-view.gob"
self_popup_menu(SELF(widget), 0, gtk_get_current_event_time());
return TRUE; /* a menu was activated */
}}
-#line 1340 "mn-mailbox-view.c"
+#line 1347 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 621 "mn-mailbox-view.gob"
+#line 615 "mn-mailbox-view.gob"
static gboolean
mn_mailbox_view_button_press_event_h (GtkWidget * widget, GdkEventButton * event, gpointer user_data)
-#line 1346 "mn-mailbox-view.c"
+#line 1353 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::button_press_event_h"
-#line 621 "mn-mailbox-view.gob"
+#line 615 "mn-mailbox-view.gob"
g_return_val_if_fail (widget != NULL, (gboolean )0);
-#line 621 "mn-mailbox-view.gob"
+#line 615 "mn-mailbox-view.gob"
g_return_val_if_fail (GTK_IS_WIDGET (widget), (gboolean )0);
-#line 621 "mn-mailbox-view.gob"
+#line 615 "mn-mailbox-view.gob"
g_return_val_if_fail (event != NULL, (gboolean )0);
-#line 1355 "mn-mailbox-view.c"
+#line 1362 "mn-mailbox-view.c"
{
-#line 625 "mn-mailbox-view.gob"
+#line 619 "mn-mailbox-view.gob"
if (event->button == 3)
self_popup_menu(SELF(widget), event->button, event->time);
return FALSE; /* propagate event */
}}
-#line 1364 "mn-mailbox-view.c"
+#line 1371 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
static void
mn_mailbox_view_row_activated_h (GtkTreeView * treeview, GtkTreePath * path, GtkTreeViewColumn * column, gpointer user_data)
-#line 1370 "mn-mailbox-view.c"
+#line 1377 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::row_activated_h"
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
g_return_if_fail (treeview != NULL);
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_TREE_VIEW (treeview));
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
g_return_if_fail (path != NULL);
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
g_return_if_fail (column != NULL);
-#line 632 "mn-mailbox-view.gob"
+#line 626 "mn-mailbox-view.gob"
g_return_if_fail (GTK_IS_TREE_VIEW_COLUMN (column));
-#line 1383 "mn-mailbox-view.c"
+#line 1390 "mn-mailbox-view.c"
{
-#line 637 "mn-mailbox-view.gob"
+#line 631 "mn-mailbox-view.gob"
self_activate_properties(SELF(treeview));
}}
-#line 1389 "mn-mailbox-view.c"
+#line 1396 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
-#line 641 "mn-mailbox-view.gob"
+#line 635 "mn-mailbox-view.gob"
GtkWidget *
mn_mailbox_view_new (void)
-#line 1395 "mn-mailbox-view.c"
+#line 1402 "mn-mailbox-view.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox:View::new"
{
-#line 643 "mn-mailbox-view.gob"
+#line 637 "mn-mailbox-view.gob"
+ g_return_val_if_fail(mn_shell != NULL, NULL);
return GTK_WIDGET(GET_NEW);
}}
-#line 1403 "mn-mailbox-view.c"
+#line 1411 "mn-mailbox-view.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-mailbox-view.gob b/src/mn-mailbox-view.gob
@@ -28,7 +28,6 @@
#include "mn-stock.h"
#include "mn-mailbox-properties-dialog.h"
#include "mn-conf.h"
-#include "mn-dialog.h"
#include "mn-uri.h"
#define GNOME_COPIED_FILES "x-special/gnome-copied-files"
@@ -63,40 +62,12 @@ class MN:Mailbox:View from Gtk:Tree:View
toplevel = gtk_widget_get_toplevel(GTK_WIDGET(self));
dialog = mn_mailbox_properties_dialog_new((GtkWindow *) toplevel, MN_MAILBOX_PROPERTIES_DIALOG_MODE_ADD);
- run:
- switch (gtk_dialog_run(GTK_DIALOG(dialog)))
- {
- case GTK_RESPONSE_HELP:
- mn_display_help("mailbox-properties");
- goto run;
-
- case GTK_RESPONSE_ACCEPT:
- {
- char *uri;
-
- uri = mn_mailbox_properties_dialog_get_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog));
- g_return_if_fail(uri != NULL);
-
- if (! mn_mailboxes_find(mn_shell->mailboxes, uri))
- {
- GSList *gconf_mailboxes;
-
- gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
- gconf_mailboxes = g_slist_append(gconf_mailboxes, uri);
- eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
- }
- else
- {
- mn_error_dialog(NULL, _("Unable to add mailbox"), _("The mailbox is already in the list."));
- g_free(uri);
- goto run;
- }
- }
- break;
- }
-
- gtk_widget_destroy(dialog);
+ g_signal_connect(G_OBJECT(dialog),
+ "response",
+ G_CALLBACK(self_properties_add_response_h),
+ NULL);
+
+ gtk_widget_show(dialog);
}
signal (ACTION) public NONE (NONE)
@@ -167,11 +138,11 @@ class MN:Mailbox:View from Gtk:Tree:View
gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
gconf_mailboxes = g_slist_concat(gconf_mailboxes, new_mailboxes);
eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
}
}
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
}
}
}
@@ -194,18 +165,18 @@ class MN:Mailbox:View from Gtk:Tree:View
Self *self = data;
GtkWidget *toplevel;
GtkWidget *dialog;
- char *uri;
+ MNURI *uri;
toplevel = gtk_widget_get_toplevel(GTK_WIDGET(self));
dialog = mn_mailbox_properties_dialog_new((GtkWindow *) toplevel, MN_MAILBOX_PROPERTIES_DIALOG_MODE_EDIT);
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
mn_mailbox_properties_dialog_set_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog), uri);
- g_free(uri);
+ g_object_unref(uri);
g_signal_connect(G_OBJECT(dialog),
"response",
- G_CALLBACK(self_properties_response_h),
+ G_CALLBACK(self_properties_edit_response_h),
NULL);
gtk_widget_show(dialog);
@@ -272,7 +243,7 @@ class MN:Mailbox:View from Gtk:Tree:View
g_signal_connect_swapped(G_OBJECT(selfp->properties_item), "activate", G_CALLBACK(self_activate_properties), self);
store = gtk_list_store_new(N_COLUMNS,
- G_TYPE_STRING,
+ MN_TYPE_URI,
G_TYPE_STRING,
G_TYPE_STRING,
G_TYPE_STRING);
@@ -332,7 +303,6 @@ class MN:Mailbox:View from Gtk:Tree:View
GtkTreeModel *model;
GtkTreeIter iter;
gboolean valid;
- MNMailbox *mailbox;
GSList *l;
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
@@ -342,15 +312,16 @@ class MN:Mailbox:View from Gtk:Tree:View
valid = gtk_tree_model_get_iter_first(model, &iter);
while (valid)
{
- char *uri;
+ MNURI *uri;
+ GSList *elem;
gtk_tree_model_get(model, &iter, COLUMN_URI, &uri, -1);
- mailbox = mn_mailboxes_find(mn_shell->mailboxes, uri);
- g_free(uri);
+ elem = mn_mailboxes_find_uri(mn_shell->mailboxes, uri);
+ g_object_unref(uri);
- if (mailbox)
+ if (elem)
{
- self_update_iter(self, &iter, mailbox);
+ self_update_iter(self, &iter, elem->data);
valid = gtk_tree_model_iter_next(model, &iter);
}
else
@@ -361,7 +332,7 @@ class MN:Mailbox:View from Gtk:Tree:View
MN_LIST_FOREACH(l, mn_mailboxes_get(mn_shell->mailboxes))
{
- mailbox = l->data;
+ MNMailbox *mailbox = l->data;
if (! self_has_mailbox(self, mailbox))
{
@@ -377,28 +348,24 @@ class MN:Mailbox:View from Gtk:Tree:View
MN:Mailbox *mailbox (check null type))
{
MNMailboxClass *class;
- const char *uri;
- const char *system_uri;
const char *stock_id;
GtkTreeModel *model;
class = MN_MAILBOX_GET_CLASS(mailbox);
- uri = mn_mailbox_get_uri(mailbox);
- system_uri = mn_uri_get_system_mailbox();
- if (system_uri && ! mn_uri_cmp(uri, system_uri))
+ if (MN_URI_IS_SYSTEM_MAILBOX(mailbox->uri))
stock_id = MN_STOCK_SYSTEM_MAILBOX;
else
{
if (class->stock_id)
stock_id = class->stock_id;
else
- stock_id = mn_uri_is_local(uri) ? MN_STOCK_LOCAL : MN_STOCK_REMOTE;
+ stock_id = MN_URI_IS_LOCAL(mailbox->uri) ? MN_STOCK_LOCAL : MN_STOCK_REMOTE;
}
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
gtk_list_store_set(GTK_LIST_STORE(model), iter,
- COLUMN_URI, uri,
+ COLUMN_URI, mailbox->uri,
COLUMN_MAILBOX_ICON, stock_id,
COLUMN_MAILBOX, mn_mailbox_get_name(mailbox),
COLUMN_FORMAT, class->format,
@@ -408,23 +375,20 @@ class MN:Mailbox:View from Gtk:Tree:View
private gboolean
has_mailbox (self, MN:Mailbox *mailbox (check null type))
{
- const char *uri;
GtkTreeModel *model;
GtkTreeIter iter;
gboolean valid;
gboolean has = FALSE;
- uri = mn_mailbox_get_uri(mailbox);
-
model = gtk_tree_view_get_model(GTK_TREE_VIEW(self));
valid = gtk_tree_model_get_iter_first(model, &iter);
while (valid)
{
- char *this_uri;
+ MNURI *uri;
- gtk_tree_model_get(model, &iter, COLUMN_URI, &this_uri, -1);
- has = ! mn_uri_cmp(this_uri, uri);
- g_free(this_uri);
+ gtk_tree_model_get(model, &iter, COLUMN_URI, &uri, -1);
+ has = ! strcmp(uri->text, mailbox->uri->text);
+ g_object_unref(uri);
if (has)
break;
@@ -461,7 +425,7 @@ class MN:Mailbox:View from Gtk:Tree:View
selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(self));
gtk_tree_selection_selected_foreach(selection, self_remove_mailbox_cb, &gconf_mailboxes);
eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
}
private void
@@ -471,20 +435,16 @@ class MN:Mailbox:View from Gtk:Tree:View
gpointer data (check null))
{
GSList **gconf_mailboxes = data;
- char *uri;
+ MNURI *uri;
GSList *elem;
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
/* remove all the mailboxes with that URI */
- while ((elem = g_slist_find_custom(*gconf_mailboxes, uri, (GCompareFunc) mn_uri_cmp)))
- {
- *gconf_mailboxes = g_slist_remove_link(*gconf_mailboxes, elem);
- g_free(elem->data);
- g_slist_free(elem);
- }
+ while ((elem = mn_mailboxes_conf_find_uri(*gconf_mailboxes, uri)))
+ *gconf_mailboxes = mn_g_slist_delete_link_deep(*gconf_mailboxes, elem);
- g_free(uri);
+ g_object_unref(uri);
}
private void
@@ -500,7 +460,7 @@ class MN:Mailbox:View from Gtk:Tree:View
gtk_tree_selection_selected_foreach(selection, self_copy_mailbox_cb, &uri_list);
gnome_copied_files = mn_build_gnome_copied_files(MN_GNOME_COPIED_FILES_COPY, uri_list);
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
status = gtk_clipboard_set_with_data(global_clipboard,
&target,
@@ -518,11 +478,11 @@ class MN:Mailbox:View from Gtk:Tree:View
gpointer data (check null))
{
GSList **uri_list = data;
- char *uri;
+ MNURI *uri;
gtk_tree_model_get(model, iter, COLUMN_URI, &uri, -1);
- *uri_list = g_slist_append(*uri_list, uri);
- /* uri is now owned by uri_list, do not free */
+ *uri_list = g_slist_append(*uri_list, g_strdup(uri->text));
+ g_object_unref(uri);
}
private void
@@ -553,9 +513,43 @@ class MN:Mailbox:View from Gtk:Tree:View
}
private void
- properties_response_h (Gtk:Dialog *dialog (check null type),
- int response,
- gpointer user_data)
+ properties_add_response_h (Gtk:Dialog *dialog (check null type),
+ int response,
+ gpointer user_data)
+ {
+ if (response == GTK_RESPONSE_HELP)
+ mn_display_help("mailbox-properties");
+ else if (response == GTK_RESPONSE_CANCEL)
+ gtk_widget_destroy(GTK_WIDGET(dialog));
+ else if (response == GTK_RESPONSE_ACCEPT)
+ {
+ MNURI *uri;
+
+ uri = mn_mailbox_properties_dialog_get_uri(MN_MAILBOX_PROPERTIES_DIALOG(dialog));
+ g_return_if_fail(MN_IS_URI(uri));
+
+ if (! mn_mailboxes_find_uri(mn_shell->mailboxes, uri))
+ {
+ GSList *gconf_mailboxes;
+
+ gconf_mailboxes = eel_gconf_get_string_list(MN_CONF_MAILBOXES);
+ gconf_mailboxes = g_slist_append(gconf_mailboxes, g_strdup(uri->text));
+ eel_gconf_set_string_list(MN_CONF_MAILBOXES, gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
+
+ gtk_widget_destroy(GTK_WIDGET(dialog));
+ }
+ else
+ mn_error_dialog(NULL, _("Unable to add mailbox"), _("The mailbox is already in the list."));
+
+ g_object_unref(uri);
+ }
+ }
+
+ private void
+ properties_edit_response_h (Gtk:Dialog *dialog (check null type),
+ int response,
+ gpointer user_data)
{
if (response == GTK_RESPONSE_HELP)
mn_display_help("mailbox-properties");
@@ -603,7 +597,7 @@ class MN:Mailbox:View from Gtk:Tree:View
{
if (type == MN_GNOME_COPIED_FILES_COPY && uri_list)
can_paste = TRUE;
- mn_pointers_free(uri_list);
+ eel_g_slist_free_deep(uri_list);
}
}
@@ -641,6 +635,7 @@ class MN:Mailbox:View from Gtk:Tree:View
public GtkWidget *
new (void)
{
+ g_return_val_if_fail(mn_shell != NULL, NULL);
return GTK_WIDGET(GET_NEW);
}
}
diff --git a/src/mn-mailbox.c b/src/mn-mailbox.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -23,7 +23,7 @@
#define ___GOB_UNLIKELY(expr) (expr)
#endif /* G_LIKELY */
-#line 42 "mn-mailbox.gob"
+#line 44 "mn-mailbox.gob"
#include "config.h"
#include <glib/gi18n-lib.h>
@@ -52,18 +52,16 @@
#include "mn-util.h"
#include "mn-unsupported-mailbox.h"
#include "mn-conf.h"
-#include "mn-dialog.h"
-#include "mn-uri.h"
typedef struct
{
- char *uri;
+ MNURI *uri;
void (*callback) (MNMailbox *self,
gpointer user_data);
gpointer user_data;
} NewInfo;
-#line 67 "mn-mailbox.c"
+#line 65 "mn-mailbox.c"
/* self casting macros */
#define SELF(x) MN_MAILBOX(x)
#define SELF_CONST(x) MN_MAILBOX_CONST(x)
@@ -84,7 +82,7 @@ static void mn_mailbox_init (MNMailbox * o) G_GNUC_UNUSED;
static void mn_mailbox_class_init (MNMailboxClass * c) G_GNUC_UNUSED;
static gpointer mn_mailbox_new_async_thread (gpointer data) G_GNUC_UNUSED;
static void mn_mailbox_monitor_cb (GnomeVFSMonitorHandle * handle, const char * monitor_uri, const char * info_uri, GnomeVFSMonitorEventType event_type, gpointer user_data) G_GNUC_UNUSED;
-static gboolean mn_mailbox_impl_is (MNMailbox * self, const char * uri) G_GNUC_UNUSED;
+static gboolean mn_mailbox_impl_is (MNMailbox * self, MNURI * uri) G_GNUC_UNUSED;
static void mn_mailbox_impl_check (MNMailbox * self) G_GNUC_UNUSED;
static void mn_mailbox_impl_threaded_check (MNMailbox * self) G_GNUC_UNUSED;
@@ -101,7 +99,6 @@ enum {
static GObjectClass *parent_class = NULL;
/* Short form macros */
-#define self_get_uri mn_mailbox_get_uri
#define self_get_name mn_mailbox_get_name
#define self_get_automatic mn_mailbox_get_automatic
#define self_set_automatic mn_mailbox_set_automatic
@@ -165,6 +162,20 @@ GET_NEW_VARG (const char *first, ...)
static void
+___dispose (GObject *obj_self)
+{
+#define __GOB_FUNCTION__ "MN:Mailbox::dispose"
+ MNMailbox *self G_GNUC_UNUSED = MN_MAILBOX (obj_self);
+ if (G_OBJECT_CLASS (parent_class)->dispose) \
+ (* G_OBJECT_CLASS (parent_class)->dispose) (obj_self);
+#line 121 "mn-mailbox.gob"
+ if(self->uri) { ((*(void (*)(void *))g_object_unref)) (self->uri); self->uri = NULL; }
+#line 174 "mn-mailbox.c"
+}
+#undef __GOB_FUNCTION__
+
+
+static void
___finalize(GObject *obj_self)
{
#define __GOB_FUNCTION__ "MN:Mailbox::finalize"
@@ -172,24 +183,21 @@ ___finalize(GObject *obj_self)
gpointer priv = self->_priv;
if(G_OBJECT_CLASS(parent_class)->finalize) \
(* G_OBJECT_CLASS(parent_class)->finalize)(obj_self);
-#line 87 "mn-mailbox.gob"
- if(self->_priv->uri) { ((*(void (*)(void *))g_free)) (self->_priv->uri); self->_priv->uri = NULL; }
-#line 178 "mn-mailbox.c"
-#line 97 "mn-mailbox.gob"
+#line 132 "mn-mailbox.gob"
if(self->_priv->name) { ((*(void (*)(void *))g_free)) (self->_priv->name); self->_priv->name = NULL; }
-#line 181 "mn-mailbox.c"
-#line 111 "mn-mailbox.gob"
+#line 189 "mn-mailbox.c"
+#line 146 "mn-mailbox.gob"
if(self->_priv->error) { ((*(void (*)(void *))g_free)) (self->_priv->error); self->_priv->error = NULL; }
-#line 184 "mn-mailbox.c"
-#line 131 "mn-mailbox.gob"
+#line 192 "mn-mailbox.c"
+#line 166 "mn-mailbox.gob"
if(self->_priv->monitor_handle) { ((*(void (*)(void *))gnome_vfs_monitor_cancel)) (self->_priv->monitor_handle); self->_priv->monitor_handle = NULL; }
-#line 187 "mn-mailbox.c"
-#line 132 "mn-mailbox.gob"
+#line 195 "mn-mailbox.c"
+#line 167 "mn-mailbox.gob"
if(self->_priv->monitor_uri) { ((*(void (*)(void *))g_free)) (self->_priv->monitor_uri); self->_priv->monitor_uri = NULL; }
-#line 190 "mn-mailbox.c"
-#line 276 "mn-mailbox.gob"
+#line 198 "mn-mailbox.c"
+#line 310 "mn-mailbox.gob"
if(self->_priv->init_error) { ((*(void (*)(void *))g_free)) (self->_priv->init_error); self->_priv->init_error = NULL; }
-#line 193 "mn-mailbox.c"
+#line 201 "mn-mailbox.c"
g_free (priv);
}
#undef __GOB_FUNCTION__
@@ -199,6 +207,9 @@ mn_mailbox_init (MNMailbox * o G_GNUC_UNUSED)
{
#define __GOB_FUNCTION__ "MN:Mailbox::init"
o->_priv = g_new0 (MNMailboxPrivate, 1);
+#line 44 "mn-mailbox.gob"
+ o->uri = NULL;
+#line 213 "mn-mailbox.c"
}
#undef __GOB_FUNCTION__
static void
@@ -212,17 +223,18 @@ mn_mailbox_class_init (MNMailboxClass * c G_GNUC_UNUSED)
c->impl_is = NULL;
c->impl_check = NULL;
c->impl_threaded_check = NULL;
+ g_object_class->dispose = ___dispose;
g_object_class->finalize = ___finalize;
g_object_class->get_property = ___object_get_property;
g_object_class->set_property = ___object_set_property;
{
GParamSpec *param_spec;
- param_spec = g_param_spec_string
+ param_spec = g_param_spec_object
("uri" /* name */,
NULL /* nick */,
_("The mailbox URI") /* blurb */,
- NULL /* default_value */,
+ MN_TYPE_URI /* object_type */,
(GParamFlags)(G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
g_object_class_install_property (g_object_class,
PROP_URI,
@@ -281,41 +293,41 @@ ___object_set_property (GObject *object,
switch (property_id) {
case PROP_URI:
{
-#line 90 "mn-mailbox.gob"
+#line 126 "mn-mailbox.gob"
- g_return_if_fail(selfp->uri == NULL);
- selfp->uri = g_value_dup_string(VAL);
- selfp->name = mn_uri_format_for_display(selfp->uri);
+ g_return_if_fail(self->uri == NULL);
+ self->uri = MN_URI(g_value_dup_object(VAL));
+ selfp->name = g_strdup(self->uri->human_readable);
-#line 291 "mn-mailbox.c"
+#line 303 "mn-mailbox.c"
}
break;
case PROP_NAME:
{
-#line 98 "mn-mailbox.gob"
+#line 133 "mn-mailbox.gob"
{ char *old = self->_priv->name; self->_priv->name = g_value_dup_string (VAL); g_free (old); }
-#line 298 "mn-mailbox.c"
+#line 310 "mn-mailbox.c"
}
break;
case PROP_AUTOMATIC:
{
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
self->_priv->automatic = g_value_get_boolean (VAL);
-#line 305 "mn-mailbox.c"
+#line 317 "mn-mailbox.c"
}
break;
case PROP_HAS_NEW:
{
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
self->_priv->has_new = g_value_get_boolean (VAL);
-#line 312 "mn-mailbox.c"
+#line 324 "mn-mailbox.c"
}
break;
case PROP_ERROR:
{
-#line 112 "mn-mailbox.gob"
+#line 147 "mn-mailbox.gob"
{ char *old = self->_priv->error; self->_priv->error = g_value_dup_string (VAL); g_free (old); }
-#line 319 "mn-mailbox.c"
+#line 331 "mn-mailbox.c"
}
break;
default:
@@ -344,30 +356,30 @@ ___object_get_property (GObject *object,
switch (property_id) {
case PROP_NAME:
{
-#line 98 "mn-mailbox.gob"
+#line 133 "mn-mailbox.gob"
g_value_set_string (VAL, self->_priv->name);
-#line 350 "mn-mailbox.c"
+#line 362 "mn-mailbox.c"
}
break;
case PROP_AUTOMATIC:
{
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
g_value_set_boolean (VAL, self->_priv->automatic);
-#line 357 "mn-mailbox.c"
+#line 369 "mn-mailbox.c"
}
break;
case PROP_HAS_NEW:
{
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
g_value_set_boolean (VAL, self->_priv->has_new);
-#line 364 "mn-mailbox.c"
+#line 376 "mn-mailbox.c"
}
break;
case PROP_ERROR:
{
-#line 112 "mn-mailbox.gob"
+#line 147 "mn-mailbox.gob"
g_value_set_string (VAL, self->_priv->error);
-#line 371 "mn-mailbox.c"
+#line 383 "mn-mailbox.c"
}
break;
default:
@@ -384,105 +396,88 @@ g_value_set_string (VAL, self->_priv->error);
-#line 95 "mn-mailbox.gob"
-const char *
-mn_mailbox_get_uri (MNMailbox * self)
-#line 391 "mn-mailbox.c"
-{
-#define __GOB_FUNCTION__ "MN:Mailbox::get_uri"
-#line 95 "mn-mailbox.gob"
- g_return_val_if_fail (self != NULL, (const char * )0);
-#line 95 "mn-mailbox.gob"
- g_return_val_if_fail (MN_IS_MAILBOX (self), (const char * )0);
-#line 398 "mn-mailbox.c"
-{
-#line 95 "mn-mailbox.gob"
- return selfp->uri; }}
-#line 402 "mn-mailbox.c"
-#undef __GOB_FUNCTION__
-
-#line 99 "mn-mailbox.gob"
+#line 134 "mn-mailbox.gob"
const char *
mn_mailbox_get_name (MNMailbox * self)
-#line 408 "mn-mailbox.c"
+#line 403 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::get_name"
-#line 99 "mn-mailbox.gob"
+#line 134 "mn-mailbox.gob"
g_return_val_if_fail (self != NULL, (const char * )0);
-#line 99 "mn-mailbox.gob"
+#line 134 "mn-mailbox.gob"
g_return_val_if_fail (MN_IS_MAILBOX (self), (const char * )0);
-#line 415 "mn-mailbox.c"
+#line 410 "mn-mailbox.c"
{
-#line 99 "mn-mailbox.gob"
+#line 134 "mn-mailbox.gob"
return selfp->name; }}
-#line 419 "mn-mailbox.c"
+#line 414 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
gboolean
mn_mailbox_get_automatic (MNMailbox * self)
-#line 425 "mn-mailbox.c"
+#line 420 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::get_automatic"
{
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
gboolean val; g_object_get (G_OBJECT (self), "automatic", &val, NULL); return val;
}}
-#line 432 "mn-mailbox.c"
+#line 427 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
void
mn_mailbox_set_automatic (MNMailbox * self, gboolean val)
-#line 438 "mn-mailbox.c"
+#line 433 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::set_automatic"
{
-#line 102 "mn-mailbox.gob"
+#line 137 "mn-mailbox.gob"
g_object_set (G_OBJECT (self), "automatic", val, NULL);
}}
-#line 445 "mn-mailbox.c"
+#line 440 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
gboolean
mn_mailbox_get_has_new (MNMailbox * self)
-#line 451 "mn-mailbox.c"
+#line 446 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::get_has_new"
{
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
gboolean val; g_object_get (G_OBJECT (self), "has_new", &val, NULL); return val;
}}
-#line 458 "mn-mailbox.c"
+#line 453 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
void
mn_mailbox_set_has_new (MNMailbox * self, gboolean val)
-#line 464 "mn-mailbox.c"
+#line 459 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::set_has_new"
{
-#line 107 "mn-mailbox.gob"
+#line 142 "mn-mailbox.gob"
g_object_set (G_OBJECT (self), "has_new", val, NULL);
}}
-#line 471 "mn-mailbox.c"
+#line 466 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 113 "mn-mailbox.gob"
+#line 148 "mn-mailbox.gob"
void
mn_mailbox_set_error (MNMailbox * self, const char * format, ...)
-#line 477 "mn-mailbox.c"
+#line 472 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::set_error"
-#line 113 "mn-mailbox.gob"
+#line 148 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 113 "mn-mailbox.gob"
+#line 148 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 484 "mn-mailbox.c"
+#line 479 "mn-mailbox.c"
{
-#line 115 "mn-mailbox.gob"
+#line 150 "mn-mailbox.gob"
va_list args;
char *error = NULL;
@@ -497,34 +492,34 @@ mn_mailbox_set_error (MNMailbox * self, const char * format, ...)
g_object_set(G_OBJECT(self), MN_MAILBOX_PROP_ERROR(error), NULL);
g_free(error);
}}
-#line 501 "mn-mailbox.c"
+#line 496 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 129 "mn-mailbox.gob"
+#line 164 "mn-mailbox.gob"
const char *
mn_mailbox_get_error (MNMailbox * self)
-#line 507 "mn-mailbox.c"
+#line 502 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::get_error"
-#line 129 "mn-mailbox.gob"
+#line 164 "mn-mailbox.gob"
g_return_val_if_fail (self != NULL, (const char * )0);
-#line 129 "mn-mailbox.gob"
+#line 164 "mn-mailbox.gob"
g_return_val_if_fail (MN_IS_MAILBOX (self), (const char * )0);
-#line 514 "mn-mailbox.c"
+#line 509 "mn-mailbox.c"
{
-#line 129 "mn-mailbox.gob"
+#line 164 "mn-mailbox.gob"
return selfp->error; }}
-#line 518 "mn-mailbox.c"
+#line 513 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 137 "mn-mailbox.gob"
+#line 172 "mn-mailbox.gob"
const GType *
mn_mailbox_get_types (void)
-#line 524 "mn-mailbox.c"
+#line 519 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::get_types"
{
-#line 139 "mn-mailbox.gob"
+#line 174 "mn-mailbox.gob"
static GType *types = NULL;
G_LOCK_DEFINE_STATIC(types);
@@ -567,7 +562,7 @@ mn_mailbox_get_types (void)
return types;
}}
-#line 571 "mn-mailbox.c"
+#line 566 "mn-mailbox.c"
#undef __GOB_FUNCTION__
/**
@@ -580,51 +575,50 @@ mn_mailbox_get_types (void)
* Creates a new #MNMailbox asynchronously. The newly created
* #MNMailbox will be passed to @callback.
**/
-#line 192 "mn-mailbox.gob"
+#line 227 "mn-mailbox.gob"
void
-mn_mailbox_new_async (const char * uri, gpointer callback, gpointer user_data)
-#line 587 "mn-mailbox.c"
+mn_mailbox_new_async (MNURI * uri, gpointer callback, gpointer user_data)
+#line 582 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::new_async"
-#line 192 "mn-mailbox.gob"
+#line 227 "mn-mailbox.gob"
g_return_if_fail (uri != NULL);
-#line 192 "mn-mailbox.gob"
+#line 227 "mn-mailbox.gob"
+ g_return_if_fail (MN_IS_URI (uri));
+#line 227 "mn-mailbox.gob"
g_return_if_fail (callback != NULL);
-#line 594 "mn-mailbox.c"
+#line 591 "mn-mailbox.c"
{
-#line 196 "mn-mailbox.gob"
+#line 231 "mn-mailbox.gob"
NewInfo *info;
info = g_new(NewInfo, 1);
- info->uri = g_strdup(uri);
+ info->uri = g_object_ref(uri);
info->callback = callback;
info->user_data = user_data;
mn_thread_create(self_new_async_thread, info);
}}
-#line 607 "mn-mailbox.c"
+#line 604 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 207 "mn-mailbox.gob"
+#line 242 "mn-mailbox.gob"
static gpointer
mn_mailbox_new_async_thread (gpointer data)
-#line 613 "mn-mailbox.c"
+#line 610 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::new_async_thread"
{
-#line 209 "mn-mailbox.gob"
+#line 244 "mn-mailbox.gob"
NewInfo *info = data;
- GnomeVFSURI *vfs_uri;
Self *mailbox = NULL;
- vfs_uri = gnome_vfs_uri_new(info->uri);
- if (vfs_uri) /* the scheme is supported by GnomeVFS, therefore we require that the URI exists */
+ if (info->uri->vfs)
{
- if (! mn_vfs_test(info->uri, G_FILE_TEST_EXISTS))
+ if (! mn_vfs_test(info->uri->vfs, G_FILE_TEST_EXISTS))
mailbox = mn_unsupported_mailbox_new(info->uri, _("does not exist"));
- gnome_vfs_uri_unref(vfs_uri);
}
if (! mailbox)
@@ -644,7 +638,7 @@ mn_mailbox_new_async_thread (gpointer data)
if (is)
{
- mailbox = g_object_new(types[i], MN_MAILBOX_PROP_URI(info->uri), NULL);
+ mailbox = g_object_new(types[i], MN_MAILBOX_PROP_URI(G_OBJECT(info->uri)), NULL);
if (mailbox->_priv->init_error)
{
MNMailbox *old_mailbox;
@@ -663,7 +657,9 @@ mn_mailbox_new_async_thread (gpointer data)
mailbox = mn_unsupported_mailbox_new(info->uri, _("unknown format"));
GDK_THREADS_ENTER();
+
info->callback(mailbox, info->user_data);
+
/*
* A note on gdk_flush(): as adviced in the GDK threads
* documentation, we only call gdk_flush() from a thread other
@@ -675,29 +671,29 @@ mn_mailbox_new_async_thread (gpointer data)
/* mailbox is now owned by the callback, do not unref it */
- g_free(info->uri);
+ g_object_unref(info->uri);
g_free(info);
return NULL;
}}
-#line 684 "mn-mailbox.c"
+#line 680 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 277 "mn-mailbox.gob"
+#line 311 "mn-mailbox.gob"
void
mn_mailbox_set_init_error (MNMailbox * self, const char * format, ...)
-#line 690 "mn-mailbox.c"
+#line 686 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::set_init_error"
-#line 277 "mn-mailbox.gob"
+#line 311 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 277 "mn-mailbox.gob"
+#line 311 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 277 "mn-mailbox.gob"
+#line 311 "mn-mailbox.gob"
g_return_if_fail (format != NULL);
-#line 699 "mn-mailbox.c"
+#line 695 "mn-mailbox.c"
{
-#line 279 "mn-mailbox.gob"
+#line 313 "mn-mailbox.gob"
va_list args;
@@ -707,35 +703,40 @@ mn_mailbox_set_init_error (MNMailbox * self, const char * format, ...)
selfp->init_error = g_strdup_vprintf(format, args);
va_end(args);
}}
-#line 711 "mn-mailbox.c"
+#line 707 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 289 "mn-mailbox.gob"
+#line 323 "mn-mailbox.gob"
void
mn_mailbox_monitor (MNMailbox * self, const char * uri, GnomeVFSMonitorType monitor_type, MNMailboxMonitorEventType events)
-#line 717 "mn-mailbox.c"
+#line 713 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::monitor"
-#line 289 "mn-mailbox.gob"
+#line 323 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 289 "mn-mailbox.gob"
+#line 323 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 289 "mn-mailbox.gob"
+#line 323 "mn-mailbox.gob"
g_return_if_fail (uri != NULL);
-#line 726 "mn-mailbox.c"
+#line 722 "mn-mailbox.c"
{
-#line 294 "mn-mailbox.gob"
+#line 328 "mn-mailbox.gob"
GnomeVFSResult result;
g_return_if_fail(MN_MAILBOX_CAN_CHECK(self));
g_return_if_fail(selfp->monitor_handle == NULL);
+ gdk_flush();
+ GDK_THREADS_LEAVE();
+
result = gnome_vfs_monitor_add(&selfp->monitor_handle,
uri,
monitor_type,
self_monitor_cb,
self);
+
+ GDK_THREADS_ENTER();
if (result == GNOME_VFS_OK)
{
@@ -796,48 +797,50 @@ mn_mailbox_monitor (MNMailbox * self, const char * uri, GnomeVFSMonitorType moni
minutes),
minutes);
- mn_error_dialog("automatic-notification",
+ mn_error_dialog("immediate-notification",
_("A monitoring error has occurred"),
- _("Mail Notification was unable to enable automatic "
+ _("Mail Notification was unable to enable immediate "
"notification for one or more mailboxes. %s"), str);
g_free(str);
}
}
}}
-#line 808 "mn-mailbox.c"
+#line 809 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 374 "mn-mailbox.gob"
+#line 413 "mn-mailbox.gob"
static void
mn_mailbox_monitor_cb (GnomeVFSMonitorHandle * handle, const char * monitor_uri, const char * info_uri, GnomeVFSMonitorEventType event_type, gpointer user_data)
-#line 814 "mn-mailbox.c"
+#line 815 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::monitor_cb"
-#line 374 "mn-mailbox.gob"
+#line 413 "mn-mailbox.gob"
g_return_if_fail (user_data != NULL);
-#line 819 "mn-mailbox.c"
+#line 820 "mn-mailbox.c"
{
-#line 380 "mn-mailbox.gob"
+#line 419 "mn-mailbox.gob"
Self *self = user_data;
+ GDK_THREADS_ENTER();
if (selfp->monitor_events & (1 << event_type))
self_check(self);
+ GDK_THREADS_LEAVE();
}}
-#line 828 "mn-mailbox.c"
+#line 831 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 387 "mn-mailbox.gob"
+#line 428 "mn-mailbox.gob"
static gboolean
-mn_mailbox_impl_is (MNMailbox * self, const char * uri)
-#line 834 "mn-mailbox.c"
+mn_mailbox_impl_is (MNMailbox * self, MNURI * uri)
+#line 837 "mn-mailbox.c"
{
MNMailboxClass *klass;
-#line 387 "mn-mailbox.gob"
+#line 428 "mn-mailbox.gob"
g_return_val_if_fail (self != NULL, (gboolean )0);
-#line 387 "mn-mailbox.gob"
+#line 428 "mn-mailbox.gob"
g_return_val_if_fail (MN_IS_MAILBOX (self), (gboolean )0);
-#line 841 "mn-mailbox.c"
+#line 844 "mn-mailbox.c"
klass = MN_MAILBOX_GET_CLASS(self);
if(klass->impl_is)
@@ -846,53 +849,53 @@ mn_mailbox_impl_is (MNMailbox * self, const char * uri)
return (gboolean )(0);
}
-#line 389 "mn-mailbox.gob"
+#line 430 "mn-mailbox.gob"
static void
mn_mailbox_impl_check (MNMailbox * self)
-#line 853 "mn-mailbox.c"
+#line 856 "mn-mailbox.c"
{
MNMailboxClass *klass;
-#line 389 "mn-mailbox.gob"
+#line 430 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 389 "mn-mailbox.gob"
+#line 430 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 860 "mn-mailbox.c"
+#line 863 "mn-mailbox.c"
klass = MN_MAILBOX_GET_CLASS(self);
if(klass->impl_check)
(*klass->impl_check)(self);
}
-#line 391 "mn-mailbox.gob"
+#line 432 "mn-mailbox.gob"
static void
mn_mailbox_impl_threaded_check (MNMailbox * self)
-#line 870 "mn-mailbox.c"
+#line 873 "mn-mailbox.c"
{
MNMailboxClass *klass;
-#line 391 "mn-mailbox.gob"
+#line 432 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 391 "mn-mailbox.gob"
+#line 432 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 877 "mn-mailbox.c"
+#line 880 "mn-mailbox.c"
klass = MN_MAILBOX_GET_CLASS(self);
if(klass->impl_threaded_check)
(*klass->impl_threaded_check)(self);
}
-#line 394 "mn-mailbox.gob"
+#line 435 "mn-mailbox.gob"
void
mn_mailbox_check (MNMailbox * self)
-#line 887 "mn-mailbox.c"
+#line 890 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::check"
-#line 394 "mn-mailbox.gob"
+#line 435 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 394 "mn-mailbox.gob"
+#line 435 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 894 "mn-mailbox.c"
+#line 897 "mn-mailbox.c"
{
-#line 396 "mn-mailbox.gob"
+#line 437 "mn-mailbox.gob"
g_return_if_fail(MN_MAILBOX_CAN_CHECK(self));
@@ -908,46 +911,46 @@ mn_mailbox_check (MNMailbox * self)
SELF_GET_CLASS(self)->impl_check(self);
}
}}
-#line 912 "mn-mailbox.c"
+#line 915 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 412 "mn-mailbox.gob"
+#line 453 "mn-mailbox.gob"
void
mn_mailbox_end_check (MNMailbox * self)
-#line 918 "mn-mailbox.c"
+#line 921 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::end_check"
-#line 412 "mn-mailbox.gob"
+#line 453 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 412 "mn-mailbox.gob"
+#line 453 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 925 "mn-mailbox.c"
+#line 928 "mn-mailbox.c"
{
-#line 414 "mn-mailbox.gob"
+#line 455 "mn-mailbox.gob"
g_return_if_fail(selfp->checking == TRUE);
selfp->checking = FALSE;
g_object_unref(self);
}}
-#line 934 "mn-mailbox.c"
+#line 937 "mn-mailbox.c"
#undef __GOB_FUNCTION__
-#line 421 "mn-mailbox.gob"
+#line 462 "mn-mailbox.gob"
void
mn_mailbox_notice (MNMailbox * self, const char * format, ...)
-#line 940 "mn-mailbox.c"
+#line 943 "mn-mailbox.c"
{
#define __GOB_FUNCTION__ "MN:Mailbox::notice"
-#line 421 "mn-mailbox.gob"
+#line 462 "mn-mailbox.gob"
g_return_if_fail (self != NULL);
-#line 421 "mn-mailbox.gob"
+#line 462 "mn-mailbox.gob"
g_return_if_fail (MN_IS_MAILBOX (self));
-#line 421 "mn-mailbox.gob"
+#line 462 "mn-mailbox.gob"
g_return_if_fail (format != NULL);
-#line 949 "mn-mailbox.c"
+#line 952 "mn-mailbox.c"
{
-#line 423 "mn-mailbox.gob"
+#line 464 "mn-mailbox.gob"
va_list args;
char *notice;
@@ -957,11 +960,11 @@ mn_mailbox_notice (MNMailbox * self, const char * format, ...)
notice = g_strdup_vprintf(format, args);
va_end(args);
- prefixed_notice = g_strdup_printf("%s: %s", selfp->uri, notice);
+ prefixed_notice = g_strdup_printf("%s: %s", self->uri->text, notice);
g_free(notice);
mn_info("%s", prefixed_notice);
g_free(prefixed_notice);
}}
-#line 967 "mn-mailbox.c"
+#line 970 "mn-mailbox.c"
#undef __GOB_FUNCTION__
diff --git a/src/mn-mailbox.gob b/src/mn-mailbox.gob
@@ -18,6 +18,7 @@
%headertop{
#include <stdarg.h>
+#include "mn-uri.h"
%}
%privateheader{
@@ -36,7 +37,8 @@
%h{
#define MN_MAILBOX_CAN_CHECK(self) \
- (MN_MAILBOX_GET_CLASS((self))->impl_check != NULL || MN_MAILBOX_GET_CLASS((self))->impl_threaded_check != NULL)
+ (MN_MAILBOX_GET_CLASS((self))->impl_check != NULL \
+ || MN_MAILBOX_GET_CLASS((self))->impl_threaded_check != NULL)
%}
%{
@@ -67,32 +69,65 @@
#include "mn-util.h"
#include "mn-unsupported-mailbox.h"
#include "mn-conf.h"
-#include "mn-dialog.h"
-#include "mn-uri.h"
typedef struct
{
- char *uri;
+ MNURI *uri;
void (*callback) (MNMailbox *self,
gpointer user_data);
gpointer user_data;
} NewInfo;
%}
+/******************************************************************************
+ *** IMPORTANT REMARKS ABOUT GDK LOCKING AND MULTI-THREADING ******************
+ ******************************************************************************
+ *
+ * MNMailbox API functions must be called with the GDK lock
+ * held. Exceptions are:
+ *
+ * mn_mailbox_get_types()
+ * mn_mailbox_notice()
+ * mn_mailbox_set_init_error()
+ *
+ * (No code can be hooked to these functions through signals or other
+ * means, therefore we are sure GDK will never be used from these
+ * functions.)
+ *
+ * Mailboxes are constructed with the GDK lock not held. Use
+ * GDK_THREADS_ENTER() and GDK_THREADS_LEAVE() where appropriate in
+ * the construction phase.
+ *
+ * Virtual methods called with the GDK lock held:
+ *
+ * mn_mailbox_impl_check()
+ *
+ * Virtual methods called with the GDK lock not held:
+ *
+ * mn_mailbox_impl_is()
+ * mn_mailbox_impl_threaded_check()
+ *
+ * Do not assume anything about the thread from which a virtual method
+ * is called. For instance, mn_mailbox_impl_check() may be called both
+ * from the thread running the GTK+ main loop and from a separate
+ * thread.
+ */
+
class MN:Mailbox from G:Object
{
classwide const char *stock_id;
classwide const char *format;
- private char *uri destroywith g_free;
- property STRING uri (blurb = _("The mailbox URI"), flags = CONSTRUCT_ONLY)
+ public MNURI *uri = NULL unrefwith g_object_unref;
+ property OBJECT uri (blurb = _("The mailbox URI"),
+ object_type = MN:URI,
+ flags = CONSTRUCT_ONLY)
set
{
- g_return_if_fail(selfp->uri == NULL);
- selfp->uri = g_value_dup_string(VAL);
- selfp->name = mn_uri_format_for_display(selfp->uri);
+ g_return_if_fail(self->uri == NULL);
+ self->uri = MN_URI(g_value_dup_object(VAL));
+ selfp->name = g_strdup(self->uri->human_readable);
};
- public const char *get_uri (self) { return selfp->uri; }
private char *name destroywith g_free;
property STRING name (blurb = _("The mailbox human-readable name"), link);
@@ -190,14 +225,14 @@ class MN:Mailbox from G:Object
* #MNMailbox will be passed to @callback.
**/
public void
- new_async (const char *uri (check null),
+ new_async (MN:URI *uri (check null type),
gpointer callback (check null),
gpointer user_data)
{
NewInfo *info;
info = g_new(NewInfo, 1);
- info->uri = g_strdup(uri);
+ info->uri = g_object_ref(uri);
info->callback = callback;
info->user_data = user_data;
@@ -208,15 +243,12 @@ class MN:Mailbox from G:Object
new_async_thread (gpointer data)
{
NewInfo *info = data;
- GnomeVFSURI *vfs_uri;
Self *mailbox = NULL;
- vfs_uri = gnome_vfs_uri_new(info->uri);
- if (vfs_uri) /* the scheme is supported by GnomeVFS, therefore we require that the URI exists */
+ if (info->uri->vfs)
{
- if (! mn_vfs_test(info->uri, G_FILE_TEST_EXISTS))
+ if (! mn_vfs_test(info->uri->vfs, G_FILE_TEST_EXISTS))
mailbox = mn_unsupported_mailbox_new(info->uri, _("does not exist"));
- gnome_vfs_uri_unref(vfs_uri);
}
if (! mailbox)
@@ -236,7 +268,7 @@ class MN:Mailbox from G:Object
if (is)
{
- mailbox = g_object_new(types[i], MN_MAILBOX_PROP_URI(info->uri), NULL);
+ mailbox = g_object_new(types[i], MN_MAILBOX_PROP_URI(G_OBJECT(info->uri)), NULL);
if (mailbox->_priv->init_error)
{
MNMailbox *old_mailbox;
@@ -255,7 +287,9 @@ class MN:Mailbox from G:Object
mailbox = mn_unsupported_mailbox_new(info->uri, _("unknown format"));
GDK_THREADS_ENTER();
+
info->callback(mailbox, info->user_data);
+
/*
* A note on gdk_flush(): as adviced in the GDK threads
* documentation, we only call gdk_flush() from a thread other
@@ -267,7 +301,7 @@ class MN:Mailbox from G:Object
/* mailbox is now owned by the callback, do not unref it */
- g_free(info->uri);
+ g_object_unref(info->uri);
g_free(info);
return NULL;
@@ -297,11 +331,16 @@ class MN:Mailbox from G:Object
g_return_if_fail(MN_MAILBOX_CAN_CHECK(self));
g_return_if_fail(selfp->monitor_handle == NULL);
+ gdk_flush();
+ GDK_THREADS_LEAVE();
+
result = gnome_vfs_monitor_add(&selfp->monitor_handle,
uri,
monitor_type,
self_monitor_cb,
self);
+
+ GDK_THREADS_ENTER();
if (result == GNOME_VFS_OK)
{
@@ -362,9 +401,9 @@ class MN:Mailbox from G:Object
minutes),
minutes);
- mn_error_dialog("automatic-notification",
+ mn_error_dialog("immediate-notification",
_("A monitoring error has occurred"),
- _("Mail Notification was unable to enable automatic "
+ _("Mail Notification was unable to enable immediate "
"notification for one or more mailboxes. %s"), str);
g_free(str);
}
@@ -380,12 +419,14 @@ class MN:Mailbox from G:Object
{
Self *self = user_data;
+ GDK_THREADS_ENTER();
if (selfp->monitor_events & (1 << event_type))
self_check(self);
+ GDK_THREADS_LEAVE();
}
virtual private gboolean
- impl_is (self, const char *uri);
+ impl_is (self, MNURI *uri);
virtual private void
impl_check (self);
virtual private void
@@ -429,7 +470,7 @@ class MN:Mailbox from G:Object
notice = g_strdup_vprintf(format, args);
va_end(args);
- prefixed_notice = g_strdup_printf("%s: %s", selfp->uri, notice);
+ prefixed_notice = g_strdup_printf("%s: %s", self->uri->text, notice);
g_free(notice);
mn_info("%s", prefixed_notice);
diff --git a/src/mn-mailbox.h b/src/mn-mailbox.h
@@ -5,6 +5,7 @@
#include <stdarg.h>
+#include "mn-uri.h"
#ifndef __MN_MAILBOX_H__
#define __MN_MAILBOX_H__
@@ -16,7 +17,8 @@ extern "C" {
#define MN_MAILBOX_CAN_CHECK(self) \
- (MN_MAILBOX_GET_CLASS((self))->impl_check != NULL || MN_MAILBOX_GET_CLASS((self))->impl_threaded_check != NULL)
+ (MN_MAILBOX_GET_CLASS((self))->impl_check != NULL \
+ || MN_MAILBOX_GET_CLASS((self))->impl_threaded_check != NULL)
/*
@@ -42,6 +44,8 @@ typedef struct _MNMailbox MNMailbox;
#endif
struct _MNMailbox {
GObject __parent__;
+ /*< public >*/
+ MNURI * uri;
/*< private >*/
MNMailboxPrivate *_priv;
};
@@ -52,7 +56,7 @@ struct _MNMailbox {
typedef struct _MNMailboxClass MNMailboxClass;
struct _MNMailboxClass {
GObjectClass __parent__;
- gboolean (* impl_is) (MNMailbox * self, const char * uri);
+ gboolean (* impl_is) (MNMailbox * self, MNURI * uri);
void (* impl_check) (MNMailbox * self);
void (* impl_threaded_check) (MNMailbox * self);
const char * stock_id;
@@ -64,7 +68,6 @@ struct _MNMailboxClass {
* Public methods
*/
GType mn_mailbox_get_type (void);
-const char * mn_mailbox_get_uri (MNMailbox * self);
const char * mn_mailbox_get_name (MNMailbox * self);
gboolean mn_mailbox_get_automatic (MNMailbox * self);
void mn_mailbox_set_automatic (MNMailbox * self,
@@ -74,7 +77,7 @@ void mn_mailbox_set_has_new (MNMailbox * self,
gboolean val);
const char * mn_mailbox_get_error (MNMailbox * self);
const GType * mn_mailbox_get_types (void);
-void mn_mailbox_new_async (const char * uri,
+void mn_mailbox_new_async (MNURI * uri,
gpointer callback,
gpointer user_data);
void mn_mailbox_check (MNMailbox * self);
@@ -83,7 +86,7 @@ void mn_mailbox_check (MNMailbox * self);
* Argument wrapping macros
*/
#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-#define MN_MAILBOX_PROP_URI(arg) "uri", __extension__ ({gchar *z = (arg); z;})
+#define MN_MAILBOX_PROP_URI(arg) "uri", __extension__ ({GObject *z = (arg); z;})
#define MN_MAILBOX_PROP_NAME(arg) "name", __extension__ ({gchar *z = (arg); z;})
#define MN_MAILBOX_GET_PROP_NAME(arg) "name", __extension__ ({gchar **z = (arg); z;})
#define MN_MAILBOX_PROP_AUTOMATIC(arg) "automatic", __extension__ ({gboolean z = (arg); z;})
@@ -93,7 +96,7 @@ void mn_mailbox_check (MNMailbox * self);
#define MN_MAILBOX_PROP_ERROR(arg) "error", __extension__ ({gchar *z = (arg); z;})
#define MN_MAILBOX_GET_PROP_ERROR(arg) "error", __extension__ ({gchar **z = (arg); z;})
#else /* __GNUC__ && !__STRICT_ANSI__ */
-#define MN_MAILBOX_PROP_URI(arg) "uri",(gchar *)(arg)
+#define MN_MAILBOX_PROP_URI(arg) "uri",(GObject *)(arg)
#define MN_MAILBOX_PROP_NAME(arg) "name",(gchar *)(arg)
#define MN_MAILBOX_GET_PROP_NAME(arg) "name",(gchar **)(arg)
#define MN_MAILBOX_PROP_AUTOMATIC(arg) "automatic",(gboolean )(arg)
diff --git a/src/mn-mailboxes-private.h b/src/mn-mailboxes-private.h
@@ -14,7 +14,11 @@ struct _MNMailboxesPrivate {
GSList * list;
#line 35 "mn-mailboxes.gob"
unsigned int timeout_id;
-#line 18 "mn-mailboxes-private.h"
+#line 37 "mn-mailboxes.gob"
+ unsigned int delay_notification_id;
+#line 39 "mn-mailboxes.gob"
+ unsigned int mailboxes_notification_id;
+#line 22 "mn-mailboxes-private.h"
};
#ifdef __cplusplus
diff --git a/src/mn-mailboxes.c b/src/mn-mailboxes.c
@@ -1,4 +1,4 @@
-/* Generated by GOB (v2.0.9) on Thu Aug 19 00:41:31 2004
+/* Generated by GOB (v2.0.9) on Thu Sep 9 01:42:01 2004
(do not edit directly) */
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
@@ -9,6 +9,8 @@
#define selfp (self->_priv)
+#include <string.h> /* memset() */
+
#include "mn-mailboxes.h"
#include "mn-mailboxes-private.h"
@@ -25,13 +27,13 @@
#include "config.h"
#include <glib/gi18n-lib.h>
+#include <eel/eel.h>
#include "mn-conf.h"
#include "mn-util.h"
-#include "mn-uri.h"
#include "mn-pending-mailbox.h"
#include "mn-unsupported-mailbox.h"
-#line 35 "mn-mailboxes.c"
+#line 37 "mn-mailboxes.c"
/* self casting macros */
#define SELF(x) MN_MAILBOXES(x)
#define SELF_CONST(x) MN_MAILBOXES_CONST(x)
@@ -58,7 +60,8 @@ static void mn_mailboxes_notify_has_new_h (GObject * object, GParamSpec * pspec,
static void mn_mailboxes_notify_error_h (GObject * object, GParamSpec * pspec, gpointer user_data) G_GNUC_UNUSED;
static void mn_mailboxes_install_timeout (MNMailboxes * self) G_GNUC_UNUSED;
static gboolean mn_mailboxes_timeout_cb (gpointer data) G_GNUC_UNUSED;
-static int mn_mailboxes_compare_func (gconstpointer a, gconstpointer b) G_GNUC_UNUSED;
+static int mn_mailboxes_find_compare_func (gconstpointer a, gconstpointer b) G_GNUC_UNUSED;
+static int mn_mailboxes_conf_find_compare_func (gconstpointer a, gconstpointer b) G_GNUC_UNUSED;
/*
* Signal connection wrapper macro shortcuts
@@ -95,7 +98,12 @@ static GObjectClass *parent_class = NULL;
#define self_check mn_mailboxes_check
#define self_get mn_mailboxes_get
#define self_find mn_mailboxes_find
-#define self_compare_func mn_mailboxes_compare_func
+#define self_find_uri mn_mailboxes_find_uri
+#define self_find_compare_func mn_mailboxes_find_compare_func
+#define self_conf_find mn_mailboxes_conf_find
+#define self_conf_find_uri mn_mailboxes_conf_find_uri
+#define self_conf_find_compare_func mn_mailboxes_conf_find_compare_func
+#define self_has_manual mn_mailboxes_has_manual
#define self_new mn_mailboxes_new
GType
mn_mailboxes_get_type (void)
@@ -148,6 +156,36 @@ ___finalize(GObject *obj_self)
gpointer priv = self->_priv;
if(G_OBJECT_CLASS(parent_class)->finalize) \
(* G_OBJECT_CLASS(parent_class)->finalize)(obj_self);
+#line 34 "mn-mailboxes.gob"
+ if(self->_priv->list) { ((*(void (*)(void *))mn_g_object_slist_free)) (self->_priv->list); self->_priv->list = NULL; }
+#line 162 "mn-mailboxes.c"
+#define timeout_id (self->_priv->timeout_id)
+#define VAR timeout_id
+ {
+#line 36 "mn-mailboxes.gob"
+ if (VAR) g_source_remove(VAR); }
+#line 168 "mn-mailboxes.c"
+ memset(&timeout_id, 0, sizeof(timeout_id));
+#undef VAR
+#undef timeout_id
+#define delay_notification_id (self->_priv->delay_notification_id)
+#define VAR delay_notification_id
+ {
+#line 38 "mn-mailboxes.gob"
+ eel_gconf_notification_remove(VAR); }
+#line 177 "mn-mailboxes.c"
+ memset(&delay_notification_id, 0, sizeof(delay_notification_id));
+#undef VAR
+#undef delay_notification_id
+#define mailboxes_notification_id (self->_priv->mailboxes_notification_id)
+#define VAR mailboxes_notification_id
+ {
+#line 40 "mn-mailboxes.gob"
+ eel_gconf_notification_remove(VAR); }
+#line 186 "mn-mailboxes.c"
+ memset(&mailboxes_notification_id, 0, sizeof(mailboxes_notification_id));
+#undef VAR
+#undef mailboxes_notification_id
g_free (priv);
}
#undef __GOB_FUNCTION__
@@ -182,32 +220,32 @@ mn_mailboxes_class_init (MNMailboxesClass * c G_GNUC_UNUSED)
g_object_class->finalize = ___finalize;
}
#undef __GOB_FUNCTION__
-#line 42 "mn-mailboxes.gob"
+#line 47 "mn-mailboxes.gob"
static void
mn_mailboxes_init (MNMailboxes * self G_GNUC_UNUSED)
-#line 189 "mn-mailboxes.c"
+#line 227 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::init"
self->_priv = g_new0 (MNMailboxesPrivate, 1);
{
-#line 43 "mn-mailboxes.gob"
+#line 48 "mn-mailboxes.gob"
self_update_from_conf(self);
self_install_timeout(self);
- eel_gconf_notification_add(MN_CONF_DELAY_NAMESPACE, self_notify_delay_cb, self);
- eel_gconf_notification_add(MN_CONF_MAILBOXES, self_notify_mailboxes_cb, self);
+ selfp->delay_notification_id = eel_gconf_notification_add(MN_CONF_DELAY_NAMESPACE, self_notify_delay_cb, self);
+ selfp->mailboxes_notification_id = eel_gconf_notification_add(MN_CONF_MAILBOXES, self_notify_mailboxes_cb, self);
-#line 202 "mn-mailboxes.c"
+#line 240 "mn-mailboxes.c"
}
}
#undef __GOB_FUNCTION__
-#line 37 "mn-mailboxes.gob"
+#line 42 "mn-mailboxes.gob"
static void
mn_mailboxes_list_changed (MNMailboxes * self)
-#line 211 "mn-mailboxes.c"
+#line 249 "mn-mailboxes.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -215,11 +253,11 @@ mn_mailboxes_list_changed (MNMailboxes * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 37 "mn-mailboxes.gob"
+#line 42 "mn-mailboxes.gob"
g_return_if_fail (self != NULL);
-#line 37 "mn-mailboxes.gob"
+#line 42 "mn-mailboxes.gob"
g_return_if_fail (MN_IS_MAILBOXES (self));
-#line 223 "mn-mailboxes.c"
+#line 261 "mn-mailboxes.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -233,10 +271,10 @@ memset (&___param_values, 0, sizeof (___param_values));
g_value_unset (&___param_values[0]);
}
-#line 39 "mn-mailboxes.gob"
+#line 44 "mn-mailboxes.gob"
static void
mn_mailboxes_status_changed (MNMailboxes * self)
-#line 240 "mn-mailboxes.c"
+#line 278 "mn-mailboxes.c"
{
GValue ___param_values[1];
GValue ___return_val;
@@ -244,11 +282,11 @@ mn_mailboxes_status_changed (MNMailboxes * self)
memset (&___return_val, 0, sizeof (___return_val));
memset (&___param_values, 0, sizeof (___param_values));
-#line 39 "mn-mailboxes.gob"
+#line 44 "mn-mailboxes.gob"
g_return_if_fail (self != NULL);
-#line 39 "mn-mailboxes.gob"
+#line 44 "mn-mailboxes.gob"
g_return_if_fail (MN_IS_MAILBOXES (self));
-#line 252 "mn-mailboxes.c"
+#line 290 "mn-mailboxes.c"
___param_values[0].g_type = 0;
g_value_init (&___param_values[0], G_TYPE_FROM_INSTANCE (self));
@@ -263,55 +301,61 @@ memset (&___param_values, 0, sizeof (___param_values));
}
-#line 51 "mn-mailboxes.gob"
+#line 56 "mn-mailboxes.gob"
static void
mn_mailboxes_notify_delay_cb (GConfClient * client, guint cnxn_id, GConfEntry * entry, gpointer user_data)
-#line 270 "mn-mailboxes.c"
+#line 308 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::notify_delay_cb"
-#line 51 "mn-mailboxes.gob"
+#line 56 "mn-mailboxes.gob"
g_return_if_fail (user_data != NULL);
-#line 275 "mn-mailboxes.c"
+#line 313 "mn-mailboxes.c"
{
-#line 56 "mn-mailboxes.gob"
+#line 61 "mn-mailboxes.gob"
Self *self = user_data;
+
+ GDK_THREADS_ENTER();
self_install_timeout(self);
+ GDK_THREADS_LEAVE();
}}
-#line 282 "mn-mailboxes.c"
+#line 323 "mn-mailboxes.c"
#undef __GOB_FUNCTION__
-#line 61 "mn-mailboxes.gob"
+#line 69 "mn-mailboxes.gob"
static void
mn_mailboxes_notify_mailboxes_cb (GConfClient * client, guint cnxn_id, GConfEntry * entry, gpointer user_data)
-#line 288 "mn-mailboxes.c"
+#line 329 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::notify_mailboxes_cb"
-#line 61 "mn-mailboxes.gob"
+#line 69 "mn-mailboxes.gob"
g_return_if_fail (user_data != NULL);
-#line 293 "mn-mailboxes.c"
+#line 334 "mn-mailboxes.c"
{
-#line 66 "mn-mailboxes.gob"
+#line 74 "mn-mailboxes.gob"
Self *self = user_data;
+
+ GDK_THREADS_ENTER();
self_update_from_conf(self);
+ GDK_THREADS_LEAVE();
}}
-#line 300 "mn-mailboxes.c"
+#line 344 "mn-mailboxes.c"
#undef __GOB_FUNCTION__
-#line 71 "mn-mailboxes.gob"
+#line 82 "mn-mailboxes.gob"
static void
mn_mailboxes_update_from_conf (MNMailboxes * self)
-#line 306 "mn-mailboxes.c"
+#line 350 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::update_from_conf"
-#line 71 "mn-mailboxes.gob"
+#line 82 "mn-mailboxes.gob"
g_return_if_fail (self != NULL);
-#line 71 "mn-mailboxes.gob"
+#line 82 "mn-mailboxes.gob"
g_return_if_fail (MN_IS_MAILBOXES (self));
-#line 313 "mn-mailboxes.c"
+#line 357 "mn-mailboxes.c"
{
-#line 73 "mn-mailboxes.gob"
+#line 84 "mn-mailboxes.gob"
GSList *gconf_mailboxes;
GSList *l;
@@ -326,10 +370,9 @@ mn_mailboxes_update_from_conf (MNMailboxes * self)
{
MNMailbox *mailbox = l->data;
- if (! g_slist_find_custom(gconf_mailboxes, mn_mailbox_get_uri(mailbox), (GCompareFunc) mn_uri_cmp))
+ if (! self_conf_find_uri(gconf_mailboxes, mailbox->uri))
{
- g_object_unref(mailbox);
- selfp->list = g_slist_delete_link(selfp->list, l);
+ selfp->list = mn_g_object_slist_delete_link(selfp->list, l);
changed = TRUE;
goto loop;
}
@@ -339,47 +382,50 @@ mn_mailboxes_update_from_conf (MNMailboxes * self)
MN_LIST_FOREACH(l, gconf_mailboxes)
{
- const char *uri = l->data;
+ const char *text_uri = l->data;
+ MNURI *uri;
- if (! self_find(self, uri))
+ uri = mn_uri_new(text_uri);
+ if (! self_find_uri(self, uri))
{
MNMailbox *mailbox;
-
+
mailbox = mn_pending_mailbox_new(uri);
selfp->list = g_slist_append(selfp->list, mailbox);
changed = TRUE;
mn_mailbox_new_async(uri, self_new_cb, self);
}
+ g_object_unref(uri);
}
- mn_pointers_free(gconf_mailboxes);
+ eel_g_slist_free_deep(gconf_mailboxes);
if (changed)
self_list_changed(self);
}}
-#line 361 "mn-mailboxes.c"
+#line 407 "mn-mailboxes.c"
#undef __GOB_FUNCTION__
-#line 119 "mn-mailboxes.gob"
+#line 132 "mn-mailboxes.gob"
static void
mn_mailboxes_new_cb (MNMailbox * mailbox, gpointer user_data)
-#line 367 "mn-mailboxes.c"
+#line 413 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::new_cb"
-#line 119 "mn-mailboxes.gob"
+#line 132 "mn-mailboxes.gob"
g_return_if_fail (mailbox != NULL);
-#line 119 "mn-mailboxes.gob"
+#line 132 "mn-mailboxes.gob"
g_return_if_fail (MN_IS_MAILBOX (mailbox));
-#line 119 "mn-mailboxes.gob"
+#line 132 "mn-mailboxes.gob"
g_return_if_fail (user_data != NULL);
-#line 376 "mn-mailboxes.c"
+#line 422 "mn-mailboxes.c"
{
-#line 122 "mn-mailboxes.gob"
+#line 135 "mn-mailboxes.gob"
Self *self = user_data;
GSList *elem;
- elem = g_slist_find_custom(selfp->list, mn_mailbox_get_uri(mailbox), self_compare_func);
+ elem = self_find_uri(self, mailbox->uri);
if (elem)
{
if (MN_IS_UNSUPPORTED_MAILBOX(mailbox))
@@ -399,26 +445,26 @@ mn_mailboxes_new_cb (MNMailbox * mailbox, gpointer user_data)
else
g_object_unref(mailbox);
}}
-#line 403 "mn-mailboxes.c"
+#line 449 "mn-mailboxes.c"
#undef __GOB_FUNCTION__
-#line 147 "mn-mailboxes.gob"
+#line 160 "mn-mailboxes.gob"
static void
mn_mailboxes_notify_has_new_h (GObject * object, GParamSpec * pspec, gpointer user_data)
-#line 409 "mn-mailboxes.c"
+#line 455 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::notify_has_new_h"
-#line 147 "mn-mailboxes.gob"
+#line 160 "mn-mailboxes.gob"
g_return_if_fail (object != NULL);
-#line 147 "mn-mailboxes.gob"
+#line 160 "mn-mailboxes.gob"
g_return_if_fail (G_IS_OBJECT (object));
-#line 147 "mn-mailboxes.gob"
+#line 160 "mn-mailboxes.gob"
g_return_if_fail (pspec != NULL);
-#line 147 "mn-mailboxes.gob"
+#line 160 "mn-mailboxes.gob"
g_return_if_fail (user_data != NULL);
-#line 420 "mn-mailboxes.c"
+#line 466 "mn-mailboxes.c"
{
-#line 151 "mn-mailboxes.gob"
+#line 164 "mn-mailboxes.gob"
Self *self = user_data;
MNMailbox *mailbox = MN_MAILBOX(object);
@@ -429,26 +475,26 @@ mn_mailboxes_notify_has_new_h (GObject * object, GParamSpec * pspec, gpointer us
self_status_changed(self);
}}
-#line 433 "mn-mailboxes.c"
+#line 479 "mn-mailboxes.c"
#undef __GOB_FUNCTION__
-#line 162 "mn-mailboxes.gob"
+#line 175 "mn-mailboxes.gob"
static void
mn_mailboxes_notify_error_h (GObject * object, GParamSpec * pspec, gpointer user_data)
-#line 439 "mn-mailboxes.c"
+#line 485 "mn-mailboxes.c"
{
#define __GOB_FUNCTION__ "MN:Mailboxes::notify_error_h"
-#line 162 "mn-mailboxes.gob"
+#line 175 "mn-mailboxes.gob"
g_return_if_fail (object != NULL);
-#line 162 "mn-mailboxes.gob"
+#line 175 "mn-mailboxes.gob"
g_return_if_fail (G_IS_OBJECT (object));
-#line 162 "mn-mailboxes.gob"
+#line 175 "