aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-05-25 21:14:51 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-05-25 21:14:51 +0800
commitf49077cfb57ade9013674487a1f371da7c038709 (patch)
tree58ebabbe624409eed22ed13578eab3ed2d4d0206
parentd3c7420fb977fe5c337f2c917839a6e982a47902 (diff)
parent9fb0290d914e63512f6e3fc719b6b0249d787656 (diff)
downloadgsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar.gz
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar.bz2
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar.lz
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar.xz
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.tar.zst
gsoc2013-evolution-f49077cfb57ade9013674487a1f371da7c038709.zip
Merge branch 'gnome-2-30' into express2
-rw-r--r--addressbook/importers/evolution-ldif-importer.c4
-rw-r--r--calendar/gui/alarm-notify/Makefile.am2
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.c5
-rw-r--r--calendar/gui/dialogs/comp-editor.c24
-rw-r--r--calendar/gui/dialogs/event-editor.c32
-rw-r--r--calendar/gui/dialogs/event-page.c3
-rw-r--r--calendar/gui/dialogs/memo-page.c3
-rw-r--r--calendar/gui/dialogs/task-page.c3
-rw-r--r--composer/e-msg-composer.c29
-rw-r--r--configure.ac6
-rw-r--r--data/Makefile.am24
-rw-r--r--data/evolution-alarm-notify.desktop.in.in4
-rw-r--r--data/evolution.keys.in.in24
-rw-r--r--doc/reference/shell/tmpl/e-extensible.sgml3
-rw-r--r--doc/reference/shell/tmpl/e-extension.sgml3
-rw-r--r--doc/reference/shell/tmpl/e-shell.sgml10
-rw-r--r--doc/reference/shell/tmpl/e-util.sgml9
-rw-r--r--doc/reference/shell/tmpl/eshell-unused.sgml8
-rw-r--r--e-util/e-win32-defaults.c136
-rw-r--r--em-format/em-format.c5
-rw-r--r--m4/as-ac-expand.m450
-rw-r--r--mail/e-mail-attachment-bar.c64
-rw-r--r--mail/e-mail-browser.c8
-rw-r--r--mail/e-mail-reader.c56
-rw-r--r--mail/em-format-html.c2
-rw-r--r--mail/em-inline-filter.c81
-rw-r--r--mail/message-list.c3
-rw-r--r--modules/addressbook/e-book-shell-backend.c1
-rw-r--r--modules/calendar/e-cal-shell-backend.c7
-rw-r--r--modules/mail/e-mail-shell-content.c53
-rw-r--r--modules/mail/e-mail-shell-settings.c4
-rw-r--r--plugins/groupwise-features/proxy-login.c3
-rw-r--r--po/POTFILES.in1
-rw-r--r--po/POTFILES.skip3
-rw-r--r--po/et.po278
-rw-r--r--shell/main.c50
-rw-r--r--widgets/misc/e-attachment-icon-view.c15
-rw-r--r--widgets/misc/e-attachment-paned.c62
-rw-r--r--widgets/misc/e-attachment-tree-view.c15
-rw-r--r--widgets/misc/e-attachment-view.c196
-rw-r--r--widgets/misc/e-attachment-view.h9
41 files changed, 750 insertions, 548 deletions
diff --git a/addressbook/importers/evolution-ldif-importer.c b/addressbook/importers/evolution-ldif-importer.c
index 41dda05a40..cfc363756d 100644
--- a/addressbook/importers/evolution-ldif-importer.c
+++ b/addressbook/importers/evolution-ldif-importer.c
@@ -565,8 +565,8 @@ ldif_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
return vbox;
}
-static const gchar *supported_extensions[2] = {
- ".ldif", NULL
+static const gchar *supported_extensions[3] = {
+ ".ldif", ".ldi", NULL
};
static gboolean
diff --git a/calendar/gui/alarm-notify/Makefile.am b/calendar/gui/alarm-notify/Makefile.am
index 9f757e3909..32190bba12 100644
--- a/calendar/gui/alarm-notify/Makefile.am
+++ b/calendar/gui/alarm-notify/Makefile.am
@@ -1,4 +1,4 @@
-bin_PROGRAMS = evolution-alarm-notify
+privlibexec_PROGRAMS = evolution-alarm-notify
if HAVE_WINDRES
EVOLUTIONALARMNOTIFYICON = evolution-alarm-notify-icon.o
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.c b/calendar/gui/dialogs/cal-prefs-dialog.c
index 21675b4a0d..e925838e58 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.c
+++ b/calendar/gui/dialogs/cal-prefs-dialog.c
@@ -600,6 +600,11 @@ calendar_prefs_dialog_construct (CalendarPrefsDialog *prefs,
locale_supports_12_hour_format =
calendar_config_locale_supports_12_hour_format ();
+ /* Force 24 hour format for locales which don't support 12 hour format */
+ if (!locale_supports_12_hour_format
+ && !e_shell_settings_get_boolean (shell_settings, "cal-use-24-hour-format"))
+ e_shell_settings_set_boolean (shell_settings, "cal-use-24-hour-format", TRUE);
+
/* Make sure our custom widget classes are registered with
* GType before we load the GtkBuilder definition file. */
E_TYPE_DATE_EDIT;
diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c
index cbdeecee2d..91d9f1e202 100644
--- a/calendar/gui/dialogs/comp-editor.c
+++ b/calendar/gui/dialogs/comp-editor.c
@@ -36,6 +36,7 @@
#include <glib/gstdio.h>
#include <gdk/gdkkeysyms.h>
#include <e-util/e-util.h>
+#include <e-util/e-binding.h>
#include <e-util/e-dialog-utils.h>
#include <e-util/e-util-private.h>
#include <e-util/gconf-bridge.h>
@@ -1078,7 +1079,7 @@ static GtkActionEntry individual_entries[] = {
G_CALLBACK (action_attach_cb) }
};
-static GtkToggleActionEntry individual_toggle_entries[] = {
+static GtkToggleActionEntry core_toggle_entries[] = {
{ "view-categories",
NULL,
@@ -1592,6 +1593,7 @@ comp_editor_init (CompEditor *editor)
GtkTargetList *target_list;
GtkTargetEntry *targets;
GtkActionGroup *action_group;
+ GtkActionGroup *action_group_2;
GtkAction *action;
GtkWidget *container;
GtkWidget *widget;
@@ -1642,6 +1644,9 @@ comp_editor_init (CompEditor *editor)
gtk_action_group_add_actions (
action_group, core_entries,
G_N_ELEMENTS (core_entries), editor);
+ gtk_action_group_add_toggle_actions (
+ action_group, core_toggle_entries,
+ G_N_ELEMENTS (core_toggle_entries), editor);
gtk_ui_manager_insert_action_group (
priv->ui_manager, action_group, 0);
g_object_unref (action_group);
@@ -1652,9 +1657,6 @@ comp_editor_init (CompEditor *editor)
gtk_action_group_add_actions (
action_group, individual_entries,
G_N_ELEMENTS (individual_entries), editor);
- gtk_action_group_add_toggle_actions (
- action_group, individual_toggle_entries,
- G_N_ELEMENTS (individual_toggle_entries), editor);
gtk_action_group_add_radio_actions (
action_group, classification_radio_entries,
G_N_ELEMENTS (classification_radio_entries),
@@ -1664,6 +1666,13 @@ comp_editor_init (CompEditor *editor)
priv->ui_manager, action_group, 0);
g_object_unref (action_group);
+ action_group = gtk_action_group_new ("editable");
+ gtk_action_group_set_translation_domain (
+ action_group, GETTEXT_PACKAGE);
+ gtk_ui_manager_insert_action_group (
+ priv->ui_manager, action_group, 0);
+ g_object_unref (action_group);
+
action_group = gtk_action_group_new ("coordinated");
gtk_action_group_set_translation_domain (
action_group, GETTEXT_PACKAGE);
@@ -1810,6 +1819,13 @@ comp_editor_init (CompEditor *editor)
gtk_window_set_type_hint (
GTK_WINDOW (editor), GDK_WINDOW_TYPE_HINT_NORMAL);
+ action_group = comp_editor_get_action_group (editor, "individual");
+ action_group_2 = e_attachment_view_get_action_group (view, "editable");
+
+ e_binding_new (
+ action_group, "sensitive",
+ action_group_2, "sensitive");
+
/* Listen for attachment store changes. */
store = e_attachment_view_get_store (view);
diff --git a/calendar/gui/dialogs/event-editor.c b/calendar/gui/dialogs/event-editor.c
index 687f26a5d5..1ae9595c02 100644
--- a/calendar/gui/dialogs/event-editor.c
+++ b/calendar/gui/dialogs/event-editor.c
@@ -203,7 +203,7 @@ action_show_time_busy_cb (GtkToggleAction *action,
event_page_set_show_time_busy (editor->priv->event_page, active);
}
-static GtkActionEntry event_entries[] = {
+static GtkActionEntry editable_entries[] = {
{ "alarms",
"appointment-soon",
@@ -211,6 +211,20 @@ static GtkActionEntry event_entries[] = {
NULL,
N_("Click here to set or unset alarms for this event"),
G_CALLBACK (action_alarms_cb) },
+};
+
+static GtkToggleActionEntry editable_toggle_entries[] = {
+
+ { "show-time-busy",
+ GTK_STOCK_DIALOG_ERROR,
+ N_("Show Time as _Busy"),
+ NULL,
+ N_("Toggles whether to show time as busy"),
+ G_CALLBACK (action_show_time_busy_cb),
+ FALSE }
+};
+
+static GtkActionEntry event_entries[] = {
{ "recurrence",
"stock_task-recurring",
@@ -236,14 +250,6 @@ static GtkToggleActionEntry event_toggle_entries[] = {
N_("Toggles whether to have All Day Event"),
G_CALLBACK (action_all_day_event_cb),
FALSE },
-
- { "show-time-busy",
- GTK_STOCK_DIALOG_ERROR,
- N_("Show Time as _Busy"),
- NULL,
- N_("Toggles whether to show time as busy"),
- G_CALLBACK (action_show_time_busy_cb),
- FALSE }
};
static GtkActionEntry meeting_entries[] = {
@@ -525,6 +531,14 @@ event_editor_init (EventEditor *ee)
action_group, event_toggle_entries,
G_N_ELEMENTS (event_toggle_entries), ee);
+ action_group = comp_editor_get_action_group (editor, "editable");
+ gtk_action_group_add_actions (
+ action_group, editable_entries,
+ G_N_ELEMENTS (editable_entries), ee);
+ gtk_action_group_add_toggle_actions (
+ action_group, editable_toggle_entries,
+ G_N_ELEMENTS (editable_toggle_entries), ee);
+
action_group = comp_editor_get_action_group (editor, "coordinated");
gtk_action_group_add_actions (
action_group, meeting_entries,
diff --git a/calendar/gui/dialogs/event-page.c b/calendar/gui/dialogs/event-page.c
index 3aa42a48b0..74d6af4c4b 100644
--- a/calendar/gui/dialogs/event-page.c
+++ b/calendar/gui/dialogs/event-page.c
@@ -809,6 +809,9 @@ sensitize_widgets (EventPage *epage)
gtk_widget_set_sensitive (priv->invite, (!read_only && sens) || delegate);
gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
+ action_group = comp_editor_get_action_group (editor, "editable");
+ gtk_action_group_set_sensitive (action_group, !read_only);
+
action_group = comp_editor_get_action_group (editor, "individual");
gtk_action_group_set_sensitive (action_group, sensitize);
diff --git a/calendar/gui/dialogs/memo-page.c b/calendar/gui/dialogs/memo-page.c
index 269caba5d6..adb10dc9fa 100644
--- a/calendar/gui/dialogs/memo-page.c
+++ b/calendar/gui/dialogs/memo-page.c
@@ -376,6 +376,9 @@ sensitize_widgets (MemoPage *mpage)
}
}
+ action_group = comp_editor_get_action_group (editor, "editable");
+ gtk_action_group_set_sensitive (action_group, !read_only);
+
action_group = comp_editor_get_action_group (editor, "individual");
gtk_action_group_set_sensitive (action_group, sensitize);
}
diff --git a/calendar/gui/dialogs/task-page.c b/calendar/gui/dialogs/task-page.c
index 623260cf46..fb6338005f 100644
--- a/calendar/gui/dialogs/task-page.c
+++ b/calendar/gui/dialogs/task-page.c
@@ -365,6 +365,9 @@ sensitize_widgets (TaskPage *tpage)
gtk_widget_set_sensitive (priv->invite, (!read_only && sens));
gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
+ action_group = comp_editor_get_action_group (editor, "editable");
+ gtk_action_group_set_sensitive (action_group, !read_only);
+
action_group = comp_editor_get_action_group (editor, "individual");
gtk_action_group_set_sensitive (action_group, sensitize);
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index dfcd5b924d..469327214a 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -1603,6 +1603,17 @@ msg_composer_finalize (GObject *object)
G_OBJECT_CLASS (parent_class)->finalize (object);
}
+static gboolean
+msg_composer_delete_event_cb (GtkWidget *widget, gpointer user_data)
+{
+ /* This is needed for the ACTION macro. */
+ EMsgComposer *composer = E_MSG_COMPOSER (widget);
+
+ gtk_action_activate (ACTION (CLOSE));
+
+ return FALSE;
+}
+
static void
msg_composer_constructed (GObject *object)
{
@@ -1640,7 +1651,10 @@ msg_composer_constructed (GObject *object)
gtk_window_set_title (GTK_WINDOW (composer), _("Compose Message"));
gtk_window_set_icon_name (GTK_WINDOW (composer), "mail-message-new");
-
+
+ g_signal_connect (object, "delete-event",
+ G_CALLBACK (msg_composer_delete_event_cb), NULL);
+
e_shell_adapt_window_size (shell, GTK_WINDOW (composer));
e_shell_watch_window (shell, GTK_WINDOW (object));
@@ -1796,18 +1810,6 @@ msg_composer_map (GtkWidget *widget)
gtkhtml_editor_run_command (GTKHTML_EDITOR (widget), "grab-focus");
}
-static gint
-msg_composer_delete_event (GtkWidget *widget,
- GdkEventAny *event)
-{
- /* This is needed for the ACTION macro. */
- EMsgComposer *composer = E_MSG_COMPOSER (widget);
-
- gtk_action_activate (ACTION (CLOSE));
-
- return TRUE;
-}
-
static gboolean
msg_composer_key_press_event (GtkWidget *widget,
GdkEventKey *event)
@@ -2089,7 +2091,6 @@ msg_composer_class_init (EMsgComposerClass *class)
widget_class = GTK_WIDGET_CLASS (class);
widget_class->map = msg_composer_map;
- widget_class->delete_event = msg_composer_delete_event;
widget_class->key_press_event = msg_composer_key_press_event;
widget_class->drag_motion = msg_composer_drag_motion;
widget_class->drag_data_received = msg_composer_drag_data_received;
diff --git a/configure.ac b/configure.ac
index 16a74973c1..5aea6ea15c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1394,6 +1394,9 @@ AC_SUBST(viewsdir)
privconduitdir="$privlibdir/conduits"
AC_SUBST(privconduitdir)
+dnl For evolution-alarm-notify.desktop
+AS_AC_EXPAND(PRIVLIBEXECDIR, "$privlibexecdir")
+
dnl ************************
dnl Plugins
dnl ************************
@@ -1658,6 +1661,9 @@ addressbook/tools/csv2vcard
addressbook/util/Makefile
art/Makefile
data/Makefile
+data/evolution.desktop.in
+data/evolution-alarm-notify.desktop.in
+data/evolution-settings.desktop.in
data/icons/Makefile
doc/Makefile
doc/reference/Makefile
diff --git a/data/Makefile.am b/data/Makefile.am
index 9dcfd7b94b..b02037b37c 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -1,27 +1,15 @@
SUBDIRS = icons
desktopdir = $(datadir)/applications
-desktop_in_in_file = evolution.desktop.in.in \
- evolution-settings.desktop.in.in
-desktop_DATA = $(desktop_in_in_file:.desktop.in.in=.desktop)
-%.desktop.in: %.desktop.in.in
- sed -e "s|\@BASE_VERSION\@|$(BASE_VERSION)|" -e "s|\@DATASERVER_EXEC_VERSION\@|$(DATASERVER_EXEC_VERSION)|" $< > $@
+desktop_in_files = evolution.desktop.in evolution-settings.desktop.in
+desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
autostartdir = $(sysconfdir)/xdg/autostart
-autostart_in_in_files = evolution-alarm-notify.desktop.in.in
autostart_in_files = evolution-alarm-notify.desktop.in
autostart_DATA = $(autostart_in_files:.desktop.in=.desktop)
@INTLTOOL_DESKTOP_RULE@
-keysdir = $(datadir)/mime-info
-keys_in_file = evolution.keys.in.in
-keys_DATA = $(keys_in_file:.keys.in.in=.keys)
-%.keys.in: %.keys.in.in
- sed -e "s|\@BASE_VERSION\@|$(BASE_VERSION)|" $< > $@
-
-@INTLTOOL_KEYS_RULE@
-
mimedir = $(datadir)/mime-info
dist_mime_DATA = evolution.mime
@@ -37,12 +25,10 @@ dist_noinst_MANS = evolution.1
CLEANFILES = \
$(autostart_DATA) \
- $(desktop_DATA) \
- $(keys_DATA)
+ $(desktop_DATA)
EXTRA_DIST = \
- $(autostart_in_in_files) \
- $(desktop_in_in_file) \
- $(keys_in_file)
+ $(autostart_in_files) \
+ $(desktop_in_files)
-include $(top_srcdir)/git.mk
diff --git a/data/evolution-alarm-notify.desktop.in.in b/data/evolution-alarm-notify.desktop.in.in
index df9f7f980d..4f382a4a36 100644
--- a/data/evolution-alarm-notify.desktop.in.in
+++ b/data/evolution-alarm-notify.desktop.in.in
@@ -3,7 +3,7 @@ Type=Application
_Name=Evolution Alarm Notify
_Comment=Calendar event notifications
Icon=appointment-soon
-Exec=evolution-alarm-notify
+Exec=@PRIVLIBEXECDIR@/evolution-alarm-notify
Terminal=false
Type=Application
Categories=
@@ -12,4 +12,4 @@ X-Moblin-Priority=Low
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=evolution
X-GNOME-Bugzilla-Component=calendar
-X-GNOME-Bugzilla-Version=@VERSION@
+X-GNOME-Bugzilla-Version=@BASE_VERSION@.x
diff --git a/data/evolution.keys.in.in b/data/evolution.keys.in.in
deleted file mode 100644
index 6baf605235..0000000000
--- a/data/evolution.keys.in.in
+++ /dev/null
@@ -1,24 +0,0 @@
-text/x-vcard
- _description=address card
- default_action_type=component
- default_component_iid=OAFIID:GNOME_Evolution_Addressbook_VCard_Control:@BASE_VERSION@
- short_list_component_iids_for_novice_user_level=OAFIID:GNOME_Evolution_Addressbook_VCard_Control:@BASE_VERSION@
- short_list_component_iids_for_intermediate_user_level=OAFIID:GNOME_Evolution_Addressbook_VCard_Control:@BASE_VERSION@
- short_list_component_iids_for_hacker_user_level=OAFIID:GNOME_Evolution_Addressbook_VCard_Control:@BASE_VERSION@
-
-text/x-calendar
- _description=calendar information
- default_action_type=component
- default_component_iid=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_novice_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_intermediate_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_hacker_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
-
-text/calendar
- _description=calendar information
- default_action_type=component
- default_component_iid=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_novice_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_intermediate_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
- short_list_component_iids_for_hacker_user_level=OAFIID:GNOME_Evolution_Calendar_iTip_Control:@BASE_VERSION@
-
diff --git a/doc/reference/shell/tmpl/e-extensible.sgml b/doc/reference/shell/tmpl/e-extensible.sgml
index 46104318d8..333d8238fc 100644
--- a/doc/reference/shell/tmpl/e-extensible.sgml
+++ b/doc/reference/shell/tmpl/e-extensible.sgml
@@ -17,6 +17,9 @@ EExtensible
<!-- ##### SECTION Stability_Level ##### -->
+<!-- ##### SECTION Image ##### -->
+
+
<!-- ##### STRUCT EExtensible ##### -->
<para>
diff --git a/doc/reference/shell/tmpl/e-extension.sgml b/doc/reference/shell/tmpl/e-extension.sgml
index 59c3aa0edd..49a3a13b70 100644
--- a/doc/reference/shell/tmpl/e-extension.sgml
+++ b/doc/reference/shell/tmpl/e-extension.sgml
@@ -17,6 +17,9 @@ EExtension
<!-- ##### SECTION Stability_Level ##### -->
+<!-- ##### SECTION Image ##### -->
+
+
<!-- ##### STRUCT EExtension ##### -->
<para>
diff --git a/doc/reference/shell/tmpl/e-shell.sgml b/doc/reference/shell/tmpl/e-shell.sgml
index 668ba80164..2287392fee 100644
--- a/doc/reference/shell/tmpl/e-shell.sgml
+++ b/doc/reference/shell/tmpl/e-shell.sgml
@@ -107,6 +107,11 @@ EShell
</para>
+<!-- ##### ARG EShell:meego-mode ##### -->
+<para>
+
+</para>
+
<!-- ##### ARG EShell:module-directory ##### -->
<para>
@@ -127,6 +132,11 @@ EShell
</para>
+<!-- ##### ARG EShell:small-screen-mode ##### -->
+<para>
+
+</para>
+
<!-- ##### FUNCTION e_shell_get_default ##### -->
<para>
diff --git a/doc/reference/shell/tmpl/e-util.sgml b/doc/reference/shell/tmpl/e-util.sgml
index 5b138cd373..e140452d0b 100644
--- a/doc/reference/shell/tmpl/e-util.sgml
+++ b/doc/reference/shell/tmpl/e-util.sgml
@@ -29,15 +29,6 @@ Miscellaneous Utilities
@Returns:
-<!-- ##### FUNCTION e_get_gnome2_user_dir ##### -->
-<para>
-
-</para>
-
-@void:
-@Returns:
-
-
<!-- ##### FUNCTION e_get_accels_filename ##### -->
<para>
diff --git a/doc/reference/shell/tmpl/eshell-unused.sgml b/doc/reference/shell/tmpl/eshell-unused.sgml
index 93f3a149fa..1cb81172df 100644
--- a/doc/reference/shell/tmpl/eshell-unused.sgml
+++ b/doc/reference/shell/tmpl/eshell-unused.sgml
@@ -4,6 +4,14 @@
</para>
+<!-- ##### FUNCTION e_get_gnome2_user_dir ##### -->
+<para>
+
+</para>
+
+@void:
+@Returns:
+
<!-- ##### FUNCTION e_shell_content_get_search_name ##### -->
<para>
diff --git a/e-util/e-win32-defaults.c b/e-util/e-win32-defaults.c
index 3d919a017d..8fb2bc3cb9 100644
--- a/e-util/e-win32-defaults.c
+++ b/e-util/e-win32-defaults.c
@@ -56,45 +56,46 @@ _e_register_mailto_structure (HKEY hKey)
static HKEY tmp_subkey = (HKEY) INVALID_HANDLE_VALUE;
if ((returnValue = RegSetValueExA (hKey, NULL, 0, REG_SZ, (const BYTE *)"URL:MailTo Protocol", strlen ("URL:MailTo Protocol") + 1)))
- return;
+ goto cleanup;
if ((returnValue = RegSetValueExA (hKey, "EditFlags", 0, REG_BINARY, editFlags, G_N_ELEMENTS (editFlags))))
- return;
+ goto cleanup;
if ((returnValue = RegSetValueExA (hKey, "URL Protocol", 0, REG_SZ, (const BYTE *)"", strlen ("") + 1)))
- return;
+ goto cleanup;
RegFlushKey (hKey);
if ((returnValue = RegCreateKeyExA (hKey, "DefaultIcon", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &tmp_subkey, &dwDisposition)))
- return;
+ goto cleanup;
evolutionBinary = _e_win32_sanitize_path (g_build_path (G_DIR_SEPARATOR_S, _e_get_bindir (), EVOBINARY, NULL));
defaultIcon = g_strconcat (evolutionBinary, ",1", NULL);
- g_free (evolutionBinary);
- if ((returnValue = RegSetValueExA (tmp_subkey, NULL, 0, REG_SZ, (const BYTE *)defaultIcon, strlen (defaultIcon) + 1))) {
- g_free (defaultIcon);
- return;
- }
- g_free (defaultIcon);
+
+ if ((returnValue = RegSetValueExA (tmp_subkey, NULL, 0, REG_SZ, (const BYTE *)defaultIcon, strlen (defaultIcon) + 1)))
+ goto cleanup;
+
RegFlushKey (tmp_subkey);
RegCloseKey (tmp_subkey);
if ((returnValue = RegCreateKeyExA (hKey, "shell\\open\\command", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &tmp_subkey, &dwDisposition)))
- return;
+ goto cleanup;
evolutionBinary = _e_win32_sanitize_path (g_build_path (G_DIR_SEPARATOR_S, _e_get_bindir (), EVOBINARY, NULL));
mailtoCommand = g_strconcat("\"", evolutionBinary, "\" --component=mail mailto:\%1", NULL);
- g_free (evolutionBinary);
- if ((returnValue = RegSetValueExA (tmp_subkey, NULL, 0, REG_SZ, (const BYTE *)mailtoCommand, strlen(mailtoCommand) + 1))) {
- g_free (mailtoCommand);
- return;
- }
- g_free (mailtoCommand);
+
+ if ((returnValue = RegSetValueExA (tmp_subkey, NULL, 0, REG_SZ, (const BYTE *)mailtoCommand, strlen(mailtoCommand) + 1)))
+ goto cleanup;
+
RegFlushKey (tmp_subkey);
RegCloseKey (tmp_subkey);
+
+cleanup:
+ g_free (defaultIcon);
+ g_free (evolutionBinary);
+ g_free (mailtoCommand);
}
static void
@@ -104,12 +105,11 @@ _e_win32_register_mailer_impl (WINBOOL system)
DWORD i, dwDisposition;
gchar *defaultIcon = NULL;
gchar *dllPath = NULL;
- gchar *dllShortPath = NULL;
- DWORD dllShortPathLength;
gchar *evolutionBinary = NULL;
gchar *openCommand = NULL;
- gchar *setDefaultCommand = NULL;
- gchar *unsetDefaultCommand = NULL;
+ gchar *reinstallCommand = NULL;
+ gchar *showIconsCommand = NULL;
+ gchar *hideIconsCommand = NULL;
static HKEY reg_key = (HKEY) INVALID_HANDLE_VALUE;
static HKEY reg_subkey = (HKEY) INVALID_HANDLE_VALUE;
@@ -117,104 +117,92 @@ _e_win32_register_mailer_impl (WINBOOL system)
if ((returnValue = RegCreateKeyExA (system ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER,
"Software\\Clients\\Mail\\" CANONICALNAME, 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &reg_key, &dwDisposition)))
- return;
+ goto cleanup;
if ((returnValue = RegSetValueExA (reg_key, NULL, 0, REG_SZ, (const BYTE *)CANONICALNAME, strlen(CANONICALNAME) + 1)))
- return;
+ goto cleanup;
dllPath = _e_win32_sanitize_path (g_build_path(G_DIR_SEPARATOR_S, _e_get_bindir (), EUTILDLL, NULL));
- if ((returnValue = RegSetValueExA (reg_key, "DLLPath", 0, REG_SZ, (const BYTE *)dllPath, strlen (dllPath) + 1))) {
- g_free (dllPath);
- return;
- }
- g_free(dllPath);
+
+ if ((returnValue = RegSetValueExA (reg_key, "DLLPath", 0, REG_SZ, (const BYTE *)dllPath, strlen (dllPath) + 1)))
+ goto cleanup;
RegFlushKey (reg_key);
if ((returnValue = RegCreateKeyExA (reg_key, "DefaultIcon", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &reg_subkey, &dwDisposition)))
- return;
+ goto cleanup;
evolutionBinary = _e_win32_sanitize_path (g_build_path (G_DIR_SEPARATOR_S, _e_get_bindir (), EVOBINARY, NULL));
defaultIcon = g_strconcat(evolutionBinary, ",0", NULL);
- g_free (evolutionBinary);
- if ((returnValue = RegSetValueExA (reg_subkey, NULL, 0, REG_SZ, (const BYTE *)defaultIcon, strlen (defaultIcon) + 1))) {
- g_free (defaultIcon);
- return;
- }
+
+ if ((returnValue = RegSetValueExA (reg_subkey, NULL, 0, REG_SZ, (const BYTE *)defaultIcon, strlen (defaultIcon) + 1)))
+ goto cleanup;
+
RegFlushKey (reg_subkey);
RegCloseKey (reg_subkey);
if ((returnValue = RegCreateKeyExA (reg_key, "shell\\open\\command", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &reg_subkey, &dwDisposition)))
- return;
+ goto cleanup;
- evolutionBinary = _e_win32_sanitize_path (g_build_path (G_DIR_SEPARATOR_S, _e_get_bindir (), EVOBINARY, NULL));
- openCommand = g_strconcat("\"", evolutionBinary, "\" -component=mail", NULL);
- g_free (evolutionBinary);
- if ((returnValue = RegSetValueExA (reg_subkey, NULL, 0, REG_SZ, (const BYTE *)openCommand, strlen (openCommand) + 1))) {
- g_free (openCommand);
- return;
- }
- g_free (openCommand);
+ openCommand = g_strconcat("\"", evolutionBinary, "\" --component=mail", NULL);
+ if ((returnValue = RegSetValueExA (reg_subkey, NULL, 0, REG_SZ, (const BYTE *)openCommand, strlen (openCommand) + 1)))
+ goto cleanup;
RegFlushKey (reg_subkey);
RegCloseKey (reg_subkey);
if ((returnValue = RegCreateKeyExA (reg_key, "InstallInfo", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &reg_subkey, &dwDisposition)))
- return;
-
- dllPath = _e_win32_sanitize_path (g_build_path(G_DIR_SEPARATOR_S, _e_get_bindir (), EUTILDLL, NULL));
- dllShortPathLength = GetShortPathNameA (dllPath, NULL, 0);
- dllShortPath = g_new0 (char, dllShortPathLength);
- GetShortPathNameA (dllPath, dllShortPath, dllShortPathLength);
- g_free (dllPath);
-
- setDefaultCommand = g_strconcat ("rundll32 ", dllShortPath, ",_e_win32_set_default_mailer", NULL);
- unsetDefaultCommand = g_strconcat ("rundll32 ", dllShortPath, ",_e_win32_set_default_mailer", NULL);
- g_free (dllShortPath);
+ goto cleanup;
- if ((returnValue = RegSetValueExA (reg_subkey, "ReinstallCommand", 0, REG_SZ, (const BYTE *)setDefaultCommand, strlen (setDefaultCommand) + 1))) {
- g_free (setDefaultCommand);
- g_free (unsetDefaultCommand);
- return;
- }
+ reinstallCommand = g_strconcat ("\"", evolutionBinary, "\" --reinstall", NULL);
+
+ if ((returnValue = RegSetValueExA (reg_subkey, "ReinstallCommand", 0, REG_EXPAND_SZ, (const BYTE *)reinstallCommand, strlen (reinstallCommand) + 1)))
+ goto cleanup;
+
+
+ showIconsCommand = g_strconcat ("\"", evolutionBinary, "\" --show-icons", NULL);
- if ((returnValue = RegSetValueExA (reg_subkey, "ShowIconsCommand", 0, REG_SZ, (const BYTE *)setDefaultCommand, strlen (setDefaultCommand) + 1))) {
- g_free (setDefaultCommand);
- g_free (unsetDefaultCommand);
- return;
- }
+ if ((returnValue = RegSetValueExA (reg_subkey, "ShowIconsCommand", 0, REG_EXPAND_SZ, (const BYTE *)showIconsCommand, strlen (showIconsCommand) + 1)))
+ goto cleanup;
- if ((returnValue = RegSetValueExA (reg_subkey, "HideIconsCommand", 0, REG_SZ, (const BYTE *)unsetDefaultCommand, strlen (unsetDefaultCommand) + 1))) {
- g_free (setDefaultCommand);
- g_free (unsetDefaultCommand);
- return;
- }
- g_free (setDefaultCommand);
- g_free (unsetDefaultCommand);
+ hideIconsCommand = g_strconcat ("\"", evolutionBinary, "\" --hide-icons", NULL);
+
+ if ((returnValue = RegSetValueExA (reg_subkey, "HideIconsCommand", 0, REG_EXPAND_SZ, (const BYTE *)hideIconsCommand, strlen (hideIconsCommand) + 1)))
+ goto cleanup;
+
i = 1;
if ((returnValue = RegSetValueExA (reg_subkey, "IconsVisible", 0, REG_DWORD, (BYTE*)&i, sizeof (i))))
- return;
+ goto cleanup;
RegFlushKey (reg_subkey);
RegCloseKey (reg_subkey);
if ((returnValue = RegCreateKeyExA (reg_key, "Protocols\\mailto", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, &reg_subkey, &dwDisposition)))
- return;
+ goto cleanup;
if ((returnValue = RegSetValueExA (reg_key, NULL, 0, REG_SZ, (const BYTE *)CANONICALNAME, strlen (CANONICALNAME) + 1)))
- return;
+ goto cleanup;
_e_register_mailto_structure (reg_subkey);
RegCloseKey (reg_subkey);
RegCloseKey (reg_key);
+
+cleanup:
+ g_free (defaultIcon);
+ g_free (dllPath);
+ g_free (evolutionBinary);
+ g_free (openCommand);
+ g_free (reinstallCommand);
+ g_free (showIconsCommand);
+ g_free (hideIconsCommand);
}
void
diff --git a/em-format/em-format.c b/em-format/em-format.c
index 19913ef5d1..a2034b4b20 100644
--- a/em-format/em-format.c
+++ b/em-format/em-format.c
@@ -2015,10 +2015,11 @@ em_format_snoop_type (CamelMimePart *part)
dw = camel_medium_get_content_object((CamelMedium *)part);
if (!camel_data_wrapper_is_offline(dw)) {
- CamelStreamMem *mem = (CamelStreamMem *)camel_stream_mem_new();
+ GByteArray *buffer = g_byte_array_new ();
+ CamelStreamMem *mem = (CamelStreamMem *)camel_stream_mem_new_with_byte_array(buffer);
if (camel_data_wrapper_decode_to_stream(dw, (CamelStream *)mem) > 0) {
- gchar *ct = g_content_type_guess (filename, mem->buffer->data, mem->buffer->len, NULL);
+ gchar *ct = g_content_type_guess (filename, buffer->data, buffer->len, NULL);
if (ct)
magic_type = g_content_type_get_mime_type (ct);
diff --git a/m4/as-ac-expand.m4 b/m4/as-ac-expand.m4
new file mode 100644
index 0000000000..8bd95a85cc
--- /dev/null
+++ b/m4/as-ac-expand.m4
@@ -0,0 +1,50 @@
+dnl as-ac-expand.m4 0.2.0 -*- autoconf -*-
+dnl autostars m4 macro for expanding directories using configure's prefix
+
+dnl (C) 2003, 2004, 2005 Thomas Vander Stichele <thomas at apestaart dot org>
+
+dnl Copying and distribution of this file, with or without modification,
+dnl are permitted in any medium without royalty provided the copyright
+dnl notice and this notice are preserved.
+
+dnl AS_AC_EXPAND(VAR, CONFIGURE_VAR)
+
+dnl example:
+dnl AS_AC_EXPAND(SYSCONFDIR, $sysconfdir)
+dnl will set SYSCONFDIR to /usr/local/etc if prefix=/usr/local
+
+AC_DEFUN([AS_AC_EXPAND],
+[
+ EXP_VAR=[$1]
+ FROM_VAR=[$2]
+
+ dnl first expand prefix and exec_prefix if necessary
+ prefix_save=$prefix
+ exec_prefix_save=$exec_prefix
+
+ dnl if no prefix given, then use /usr/local, the default prefix
+ if test "x$prefix" = "xNONE"; then
+ prefix="$ac_default_prefix"
+ fi
+ dnl if no exec_prefix given, then use prefix
+ if test "x$exec_prefix" = "xNONE"; then
+ exec_prefix=$prefix
+ fi
+
+ full_var="$FROM_VAR"
+ dnl loop until it doesn't change anymore
+ while true; do
+ new_full_var="`eval echo $full_var`"
+ if test "x$new_full_var" = "x$full_var"; then break; fi
+ full_var=$new_full_var
+ done
+
+ dnl clean up
+ full_var=$new_full_var
+ AC_SUBST([$1], "$full_var")
+
+ dnl restore prefix and exec_prefix
+ prefix=$prefix_save
+ exec_prefix=$exec_prefix_save
+])
+
diff --git a/mail/e-mail-attachment-bar.c b/mail/e-mail-attachment-bar.c
index 88198438b7..aa5abd09fb 100644
--- a/mail/e-mail-attachment-bar.c
+++ b/mail/e-mail-attachment-bar.c
@@ -64,36 +64,6 @@ enum {
static gpointer parent_class;
static void
-mail_attachment_bar_sync_icon_view (EMailAttachmentBar *bar)
-{
- EAttachmentView *source;
- EAttachmentView *target;
-
- source = E_ATTACHMENT_VIEW (bar->priv->tree_view);
- target = E_ATTACHMENT_VIEW (bar->priv->icon_view);
-
- /* Only sync if the tree view is active. This prevents the
- * two views from endlessly trying to sync with each other. */
- if (e_mail_attachment_bar_get_active_view (bar) == 1)
- e_attachment_view_sync_selection (source, target);
-}
-
-static void
-mail_attachment_bar_sync_tree_view (EMailAttachmentBar *bar)
-{
- EAttachmentView *source;
- EAttachmentView *target;
-
- source = E_ATTACHMENT_VIEW (bar->priv->icon_view);
- target = E_ATTACHMENT_VIEW (bar->priv->tree_view);
-
- /* Only sync if the icon view is active. This prevents the
- * two views from endlessly trying to sync with each other. */
- if (e_mail_attachment_bar_get_active_view (bar) == 0)
- e_attachment_view_sync_selection (source, target);
-}
-
-static void
mail_attachment_bar_update_status (EMailAttachmentBar *bar)
{
EAttachmentView *view;
@@ -516,7 +486,6 @@ static void
mail_attachment_bar_init (EMailAttachmentBar *bar)
{
EAttachmentView *view;
- GtkTreeSelection *selection;
GtkSizeGroup *size_group;
GtkWidget *container;
GtkWidget *widget;
@@ -562,7 +531,7 @@ mail_attachment_bar_init (EMailAttachmentBar *bar)
gtk_frame_set_shadow_type (GTK_FRAME (widget), GTK_SHADOW_IN);
gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0);
bar->priv->tree_frame = g_object_ref (widget);
- gtk_widget_show (widget);
+ gtk_widget_hide (widget);
container = widget;
@@ -645,17 +614,6 @@ mail_attachment_bar_init (EMailAttachmentBar *bar)
bar->priv->status_label = g_object_ref (widget);
gtk_widget_show (widget);
- selection = gtk_tree_view_get_selection (
- GTK_TREE_VIEW (bar->priv->tree_view));
-
- g_signal_connect_swapped (
- selection, "changed",
- G_CALLBACK (mail_attachment_bar_sync_icon_view), bar);
-
- g_signal_connect_swapped (
- bar->priv->icon_view, "selection-changed",
- G_CALLBACK (mail_attachment_bar_sync_tree_view), bar);
-
g_signal_connect_swapped (
bar->priv->model, "notify::num-attachments",
G_CALLBACK (mail_attachment_bar_update_status), bar);
@@ -722,9 +680,15 @@ void
e_mail_attachment_bar_set_active_view (EMailAttachmentBar *bar,
gint active_view)
{
+ EAttachmentView *source;
+ EAttachmentView *target;
+
g_return_if_fail (E_IS_MAIL_ATTACHMENT_BAR (bar));
g_return_if_fail (active_view >= 0 && active_view < NUM_VIEWS);
+ if (active_view == bar->priv->active_view)
+ return;
+
bar->priv->active_view = active_view;
if (active_view == 0) {
@@ -735,6 +699,20 @@ e_mail_attachment_bar_set_active_view (EMailAttachmentBar *bar,
gtk_widget_show (bar->priv->tree_frame);
}
+ /* Synchronize the item selection of the view we're
+ * switching TO with the view we're switching FROM. */
+ if (active_view == 0) {
+ /* from tree view to icon view */
+ source = E_ATTACHMENT_VIEW (bar->priv->tree_view);
+ target = E_ATTACHMENT_VIEW (bar->priv->icon_view);
+ } else {
+ /* from icon view to tree view */
+ source = E_ATTACHMENT_VIEW (bar->priv->icon_view);
+ target = E_ATTACHMENT_VIEW (bar->priv->tree_view);
+ }
+
+ e_attachment_view_sync_selection (source, target);
+
g_object_notify (G_OBJECT (bar), "active-view");
}
diff --git a/mail/e-mail-browser.c b/mail/e-mail-browser.c
index aaf4f789d6..cd7ecd32fd 100644
--- a/mail/e-mail-browser.c
+++ b/mail/e-mail-browser.c
@@ -280,11 +280,10 @@ close_on_idle_cb (gpointer browser)
}
static void
-mail_browser_message_list_built_cb (EMailBrowser *browser, MessageList *message_list)
+mail_browser_message_list_built_cb (EMailBrowser *browser,
+ MessageList *message_list)
{
- g_return_if_fail (browser != NULL);
g_return_if_fail (E_IS_MAIL_BROWSER (browser));
- g_return_if_fail (message_list != NULL);
g_return_if_fail (IS_MESSAGE_LIST (message_list));
if (!message_list_count (message_list))
@@ -446,7 +445,8 @@ mail_browser_dispose (GObject *object)
}
if (priv->message_list != NULL) {
- g_object_unref (priv->message_list);
+ /* This will cancel a regen operation. */
+ gtk_widget_destroy (priv->message_list);
priv->message_list = NULL;
}
diff --git a/mail/e-mail-reader.c b/mail/e-mail-reader.c
index 6b1fa7df09..10f1864497 100644
--- a/mail/e-mail-reader.c
+++ b/mail/e-mail-reader.c
@@ -52,7 +52,8 @@
#include "mail/message-list.h"
#define E_MAIL_READER_GET_PRIVATE(obj) \
- (mail_reader_get_private (G_OBJECT (obj)))
+ ((EMailReaderPrivate *) g_object_get_qdata \
+ (G_OBJECT (obj), quark_private))
typedef struct _EMailReaderPrivate EMailReaderPrivate;
@@ -92,31 +93,24 @@ static GQuark quark_private;
static guint signals[LAST_SIGNAL];
static void
-mail_reader_finalize (EMailReaderPrivate *priv)
+mail_reader_destroy (GObject *object)
{
- if (priv->message_selected_timeout_id > 0)
- g_source_remove (priv->message_selected_timeout_id);
-
- g_free (priv->mark_read_message_uid);
-
- g_slice_free (EMailReaderPrivate, priv);
+ /* This will free the private struct. */
+ g_object_set_qdata (object, quark_private, NULL);
}
-static EMailReaderPrivate *
-mail_reader_get_private (GObject *object)
+static void
+mail_reader_private_free (EMailReaderPrivate *priv)
{
- EMailReaderPrivate *priv;
+ if (priv->message_selected_timeout_id > 0)
+ g_source_remove (priv->message_selected_timeout_id);
- priv = g_object_get_qdata (object, quark_private);
+ if (priv->retrieving_message_operation_id > 0)
+ mail_msg_cancel (priv->retrieving_message_operation_id);
- if (G_UNLIKELY (priv == NULL)) {
- priv = g_slice_new0 (EMailReaderPrivate);
- g_object_set_qdata_full (
- object, quark_private, priv,
- (GDestroyNotify) mail_reader_finalize);
- }
+ g_free (priv->mark_read_message_uid);
- return priv;
+ g_slice_free (EMailReaderPrivate, priv);
}
static void
@@ -1809,6 +1803,14 @@ mail_reader_message_loaded_cb (CamelFolder *folder,
priv = E_MAIL_READER_GET_PRIVATE (reader);
+ /* If the private struct is NULL, the EMailReader was destroyed
+ * while we were loading the message and we're likely holding the
+ * last reference. Nothing to do but drop the reference. */
+ if (priv == NULL) {
+ g_object_unref (reader);
+ return;
+ }
+
html_display = e_mail_reader_get_html_display (reader);
message_list = e_mail_reader_get_message_list (reader);
@@ -2537,7 +2539,7 @@ e_mail_reader_get_type (void)
type = g_type_register_static (
G_TYPE_INTERFACE, "EMailReader", &type_info, 0);
- g_type_interface_add_prerequisite (type, G_TYPE_OBJECT);
+ g_type_interface_add_prerequisite (type, GTK_TYPE_OBJECT);
}
return type;
@@ -2590,6 +2592,7 @@ e_mail_reader_init (EMailReader *reader)
/* Add the other actions the normal way. */
+ gtk_action_group_set_translation_domain (action_group, GETTEXT_PACKAGE);
gtk_action_group_add_actions (
action_group, mail_reader_entries,
G_N_ELEMENTS (mail_reader_entries), reader);
@@ -2686,6 +2689,19 @@ e_mail_reader_init (EMailReader *reader)
g_signal_connect_swapped (
message_list, "selection-change",
G_CALLBACK (e_mail_reader_changed), reader);
+
+ /* Install a private struct for storing things like flags and
+ * timeout and asynchronous operation IDs. We delete it when
+ * the EMailReader is destroyed rather than finalized so that
+ * asynchronous callbacks holding a reference can detect that
+ * the reader has been destroyed and drop their reference. */
+ g_object_set_qdata_full (
+ G_OBJECT (reader), quark_private,
+ g_slice_new0 (EMailReaderPrivate),
+ (GDestroyNotify) mail_reader_private_free);
+ g_signal_connect (
+ reader, "destroy",
+ G_CALLBACK (mail_reader_destroy), NULL);
}
void
diff --git a/mail/em-format-html.c b/mail/em-format-html.c
index 62e190f4b2..db03a6a9d0 100644
--- a/mail/em-format-html.c
+++ b/mail/em-format-html.c
@@ -1694,7 +1694,7 @@ efh_text_plain(EMFormatHTML *efh, CamelStream *stream, CamelMimePart *part, EMFo
camel_object_unref(null);
inline_filter = em_inline_filter_new(camel_mime_part_get_encoding(part), ct);
camel_stream_filter_add(filtered_stream, (CamelMimeFilter *)inline_filter);
- camel_data_wrapper_write_to_stream(dw, (CamelStream *)filtered_stream);
+ camel_data_wrapper_decode_to_stream (dw, (CamelStream *)filtered_stream);
camel_stream_close((CamelStream *)filtered_stream);
camel_object_unref(filtered_stream);
diff --git a/mail/em-inline-filter.c b/mail/em-inline-filter.c
index 1959b0b7f8..43dee1f97e 100644
--- a/mail/em-inline-filter.c
+++ b/mail/em-inline-filter.c
@@ -30,6 +30,8 @@
#include <camel/camel-mime-part.h>
#include <camel/camel-multipart.h>
#include <camel/camel-stream-mem.h>
+#include <camel/camel-mime-filter-basic.h>
+#include <camel/camel-stream-filter.h>
#include "em-utils.h"
#include "em-format/em-format.h"
@@ -140,11 +142,26 @@ emif_add_part(EMInlineFilter *emif, const gchar *data, gint len)
if (emif->data->len <= 0) {
return;
}
- mem = camel_stream_mem_new_with_byte_array(emif->data);
+
+ mem = camel_stream_mem_new_with_byte_array (emif->data);
emif->data = g_byte_array_new();
dw = camel_data_wrapper_new();
- camel_data_wrapper_construct_from_stream(dw, mem);
+ if (encoding == emif->base_encoding && (encoding == CAMEL_TRANSFER_ENCODING_BASE64 || encoding == CAMEL_TRANSFER_ENCODING_QUOTEDPRINTABLE)) {
+ CamelMimeFilterBasic *enc_filter = camel_mime_filter_basic_new_type (encoding == CAMEL_TRANSFER_ENCODING_BASE64 ? CAMEL_MIME_FILTER_BASIC_BASE64_ENC : CAMEL_MIME_FILTER_BASIC_QP_ENC);
+ CamelStreamFilter *filter_stream;
+
+ filter_stream = camel_stream_filter_new_with_stream (mem);
+ camel_stream_filter_add (filter_stream, CAMEL_MIME_FILTER (enc_filter));
+
+ /* properly encode content */
+ camel_data_wrapper_construct_from_stream (dw, CAMEL_STREAM (filter_stream));
+
+ camel_object_unref (enc_filter);
+ camel_object_unref (filter_stream);
+ } else {
+ camel_data_wrapper_construct_from_stream (dw, mem);
+ }
camel_object_unref(mem);
if (emif_types[emif->state].plain && emif->base_type) {
@@ -199,12 +216,14 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
gchar *start;
while (inptr < inend) {
+ gint rest_len;
+
start = inptr;
while (inptr < inend && *inptr != '\n')
inptr++;
- if (inptr == inend) {
+ if (inptr == inend && start == inptr) {
if (!final) {
camel_mime_filter_backup(f, start, inend-start);
inend = start;
@@ -212,22 +231,26 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
break;
}
- *inptr++ = 0;
+ rest_len = inend - start;
+ if (inptr < inend)
+ *inptr++ = 0;
+
+ #define restore_inptr() G_STMT_START { if (inptr < inend) inptr[-1] = '\n'; } G_STMT_END
switch (emif->state) {
case EMIF_PLAIN:
- /* This could use some funky plugin shit, but this'll do for now */
- if (strncmp(start, "begin ", 6) == 0
+ /* This could use some funky plugin, but this'll do for now */
+ if (rest_len > 6 && strncmp (start, "begin ", 6) == 0
&& start[6] >= '0' && start[6] <= '7') {
gint i = 7;
gchar *name;
- while (start[i] >='0' && start[i] <='7')
+ while (i < rest_len && start[i] >='0' && start[i] <='7')
i++;
- inptr[-1] = '\n';
+ restore_inptr ();
- if (start[i++] != ' ')
+ if (i >= rest_len || start[i++] != ' ')
break;
emif_add_part(emif, data_start, start-data_start);
@@ -237,23 +260,23 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
g_free(name);
data_start = start;
emif->state = EMIF_UUENC;
- } else if (strncmp(start, "(This file must be converted with BinHex 4.0)", 45) == 0) {
- inptr[-1] = '\n';
+ } else if (rest_len >= 45 && strncmp (start, "(This file must be converted with BinHex 4.0)", 45) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, start-data_start);
data_start = start;
emif->state = EMIF_BINHEX;
- } else if (strncmp(start, "%!PS-Adobe-", 11) == 0) {
- inptr[-1] = '\n';
+ } else if (rest_len >= 11 && strncmp (start, "%!PS-Adobe-", 11) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, start-data_start);
data_start = start;
emif->state = EMIF_POSTSCRIPT;
- } else if (strncmp(start, "-----BEGIN PGP SIGNED MESSAGE-----", 34) == 0) {
- inptr[-1] = '\n';
+ } else if (rest_len >= 34 && strncmp (start, "-----BEGIN PGP SIGNED MESSAGE-----", 34) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, start-data_start);
data_start = start;
emif->state = EMIF_PGPSIGNED;
- } else if (strncmp(start, "-----BEGIN PGP MESSAGE-----", 27) == 0) {
- inptr[-1] = '\n';
+ } else if (rest_len >= 27 && strncmp (start, "-----BEGIN PGP MESSAGE-----", 27) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, start-data_start);
data_start = start;
emif->state = EMIF_PGPENCRYPTED;
@@ -261,8 +284,8 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
break;
case EMIF_UUENC:
- if (strcmp(start, "end") == 0) {
- inptr[-1] = '\n';
+ if (rest_len >= 3 && strncmp (start, "end", 3) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, inptr-data_start);
data_start = inptr;
emif->state = EMIF_PLAIN;
@@ -278,7 +301,7 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
linelen /= 4;
linelen *= 3;
if (!(len == linelen || len == linelen-1 || len == linelen-2)) {
- inptr[-1] = '\n';
+ restore_inptr ();
emif_add_part(emif, data_start, start-data_start);
data_start = start;
inptr = start;
@@ -289,31 +312,31 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
break;
case EMIF_BINHEX:
if (inptr > (start+1) && inptr[-2] == ':') {
- inptr[-1] = '\n';
+ restore_inptr ();
emif_add_part(emif, data_start, inptr-data_start);
data_start = inptr;
emif->state = EMIF_PLAIN;
}
break;
case EMIF_POSTSCRIPT:
- if (strcmp(start, "%%EOF") == 0) {
- inptr[-1] = '\n';
+ if (rest_len >= 5 && strncmp (start, "%%EOF", 5) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, inptr-data_start);
data_start = inptr;
emif->state = EMIF_PLAIN;
}
break;
case EMIF_PGPSIGNED:
- if (strcmp(start, "-----END PGP SIGNATURE-----") == 0) {
- inptr[-1] = '\n';
+ if (rest_len >= 27 && strncmp (start, "-----END PGP SIGNATURE-----", 27) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, inptr-data_start);
data_start = inptr;
emif->state = EMIF_PLAIN;
}
break;
case EMIF_PGPENCRYPTED:
- if (strcmp(start, "-----END PGP MESSAGE-----") == 0) {
- inptr[-1] = '\n';
+ if (rest_len >= 25 && strncmp (start, "-----END PGP MESSAGE-----", 25) == 0) {
+ restore_inptr ();
emif_add_part(emif, data_start, inptr-data_start);
data_start = inptr;
emif->state = EMIF_PLAIN;
@@ -321,7 +344,9 @@ emif_scan(CamelMimeFilter *f, gchar *in, gsize len, gint final)
break;
}
- inptr[-1] = '\n';
+ restore_inptr ();
+
+ #undef restore_inptr
}
if (final) {
diff --git a/mail/message-list.c b/mail/message-list.c
index ed1236524c..c7361087b8 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -4900,7 +4900,7 @@ mail_regen_list (MessageList *ml, const gchar *search, const gchar *hideexpr, Ca
#endif
m = mail_msg_new (&regen_list_info);
- m->ml = ml;
+ m->ml = g_object_ref (ml);
m->search = g_strdup (search);
m->hideexpr = g_strdup (hideexpr);
m->changes = changes;
@@ -4908,7 +4908,6 @@ mail_regen_list (MessageList *ml, const gchar *search, const gchar *hideexpr, Ca
m->hidedel = ml->hidedeleted;
m->hidejunk = ml->hidejunk;
m->thread_subject = gconf_client_get_bool (gconf, "/apps/evolution/mail/display/thread_subject", NULL);
- g_object_ref(ml);
m->folder = ml->folder;
camel_object_ref(m->folder);
m->last_row = -1;
diff --git a/modules/addressbook/e-book-shell-backend.c b/modules/addressbook/e-book-shell-backend.c
index 1166cd61c3..74dbbfcf7f 100644
--- a/modules/addressbook/e-book-shell-backend.c
+++ b/modules/addressbook/e-book-shell-backend.c
@@ -169,6 +169,7 @@ book_shell_backend_ensure_sources (EShellBackend *shell_backend)
source_group = e_source_group_new (name, base_uri);
e_source_list_add_group (priv->source_list, source_group, -1);
+ on_this_computer = source_group;
g_object_unref (source_group);
}
diff --git a/modules/calendar/e-cal-shell-backend.c b/modules/calendar/e-cal-shell-backend.c
index 5560d018cc..86750f0a32 100644
--- a/modules/calendar/e-cal-shell-backend.c
+++ b/modules/calendar/e-cal-shell-backend.c
@@ -166,6 +166,13 @@ cal_shell_backend_ensure_sources (EShellBackend *shell_backend)
* Open ... because of invalid URI" error. */
save_list = TRUE;
}
+ } else {
+ ESourceGroup *source_group;
+
+ source_group = e_source_group_new (name, base_uri);
+ e_source_list_add_group (priv->source_list, source_group, -1);
+ on_this_computer = source_group;
+ g_object_unref (source_group);
}
name = _("Personal");
diff --git a/modules/mail/e-mail-shell-content.c b/modules/mail/e-mail-shell-content.c
index 79f001afc8..aa2718dcec 100644
--- a/modules/mail/e-mail-shell-content.c
+++ b/modules/mail/e-mail-shell-content.c
@@ -70,10 +70,9 @@ struct _EMailShellContentPrivate {
/* Signal handler IDs */
guint message_list_built_id;
- guint group_by_threads : 1;
- guint preview_visible : 1;
- guint suppress_message_selection : 1;
- guint show_deleted : 1;
+ guint group_by_threads : 1;
+ guint preview_visible : 1;
+ guint show_deleted : 1;
};
enum {
@@ -121,8 +120,9 @@ mail_shell_content_message_list_built_cb (EMailShellContent *mail_shell_content,
MessageList *message_list)
{
EMailShellContentPrivate *priv = mail_shell_content->priv;
- EShellContent *shell_content;
EShellView *shell_view;
+ EShellWindow *shell_window;
+ EShellContent *shell_content;
GKeyFile *key_file;
gchar *uid;
@@ -132,6 +132,8 @@ mail_shell_content_message_list_built_cb (EMailShellContent *mail_shell_content,
shell_content = E_SHELL_CONTENT (mail_shell_content);
shell_view = e_shell_content_get_shell_view (shell_content);
+ shell_window = e_shell_view_get_shell_window (shell_view);
+
key_file = e_shell_view_get_state_key_file (shell_view);
if (message_list->cursor_uid != NULL)
@@ -140,10 +142,11 @@ mail_shell_content_message_list_built_cb (EMailShellContent *mail_shell_content,
else if (message_list->folder_uri == NULL)
uid = NULL;
- else if (mail_shell_content->priv->suppress_message_selection)
+ else if (e_shell_window_get_safe_mode (shell_window)) {
+ e_shell_window_set_safe_mode (shell_window, FALSE);
uid = NULL;
- else {
+ } else {
const gchar *folder_uri;
const gchar *key;
gchar *group_name;
@@ -566,29 +569,33 @@ mail_shell_content_set_folder (EMailReader *reader,
CamelFolder *folder,
const gchar *folder_uri)
{
+ EShell *shell;
EShellView *shell_view;
+ EShellWindow *shell_window;
EShellContent *shell_content;
+ EShellSettings *shell_settings;
EMailShellContentPrivate *priv;
EMailReaderIface *default_iface;
GtkWidget *message_list;
- CamelFolder *old_folder;
GKeyFile *key_file;
gchar *group_name;
const gchar *key;
- gboolean different_folder;
gboolean value;
GError *error = NULL;
priv = E_MAIL_SHELL_CONTENT_GET_PRIVATE (reader);
- old_folder = e_mail_reader_get_folder (reader);
+ shell_content = E_SHELL_CONTENT (reader);
+ shell_view = e_shell_content_get_shell_view (shell_content);
+ shell_window = e_shell_view_get_shell_window (shell_view);
+
+ shell = e_shell_window_get_shell (shell_window);
+ shell_settings = e_shell_get_shell_settings (shell);
+
message_list = e_mail_reader_get_message_list (reader);
message_list_freeze (MESSAGE_LIST (message_list));
- different_folder =
- (old_folder != NULL && folder != old_folder);
-
/* Chain up to interface's default set_folder() method. */
default_iface = g_type_default_interface_peek (E_TYPE_MAIL_READER);
default_iface->set_folder (reader, folder, folder_uri);
@@ -598,12 +605,6 @@ mail_shell_content_set_folder (EMailReader *reader,
mail_refresh_folder (folder, NULL, NULL);
- /* This function gets triggered several times at startup,
- * so we don't want to reset the message suppression state
- * unless we're actually switching to a different folder. */
- if (different_folder)
- priv->suppress_message_selection = FALSE;
-
/* This is a one-time-only callback. */
if (MESSAGE_LIST (message_list)->cursor_uid == NULL &&
priv->message_list_built_id == 0)
@@ -614,9 +615,6 @@ mail_shell_content_set_folder (EMailReader *reader,
/* Restore the folder's preview and threaded state. */
- shell_content = E_SHELL_CONTENT (reader);
- shell_view = e_shell_content_get_shell_view (shell_content);
-
key_file = e_shell_view_get_state_key_file (shell_view);
group_name = g_strdup_printf ("Folder %s", folder_uri);
@@ -637,6 +635,17 @@ mail_shell_content_set_folder (EMailReader *reader,
g_clear_error (&error);
}
+ /* XXX This is a little confusing and needs rethought. The
+ * EShellWindow:safe-mode property blocks automatic message
+ * selection, but the "mail-safe-list" shell setting blocks
+ * both the preview pane and automatic message selection. */
+ if (e_shell_settings_get_boolean (shell_settings, "mail-safe-list")) {
+ e_shell_settings_set_boolean (
+ shell_settings, "mail-safe-list", FALSE);
+ e_shell_window_set_safe_mode (shell_window, TRUE);
+ value = FALSE;
+ }
+
e_mail_shell_content_set_preview_visible (
E_MAIL_SHELL_CONTENT (shell_content), value);
diff --git a/modules/mail/e-mail-shell-settings.c b/modules/mail/e-mail-shell-settings.c
index 1434951b81..48fd042d58 100644
--- a/modules/mail/e-mail-shell-settings.c
+++ b/modules/mail/e-mail-shell-settings.c
@@ -166,6 +166,10 @@ e_mail_shell_settings_init (EShell *shell)
"/apps/evolution/mail/format/reply_style");
e_shell_settings_install_property_for_key (
+ "mail-safe-list",
+ "/apps/evolution/mail/display/safe_list");
+
+ e_shell_settings_install_property_for_key (
"mail-show-animated-images",
"/apps/evolution/mail/display/animated_images");
diff --git a/plugins/groupwise-features/proxy-login.c b/plugins/groupwise-features/proxy-login.c
index bf23e17d82..f85bc2b946 100644
--- a/plugins/groupwise-features/proxy-login.c
+++ b/plugins/groupwise-features/proxy-login.c
@@ -486,6 +486,7 @@ gw_proxy_login_cb (GtkAction *action, EShellView *shell_view)
GtkTreeSelection *selection;
GtkTreeModel *model = NULL;
GtkTreeIter iter;
+ GtkWidget *tbox_account_name;
gboolean is_store = FALSE;
gchar *uri = NULL;
proxyLoginPrivate *priv;
@@ -528,6 +529,8 @@ gw_proxy_login_cb (GtkAction *action, EShellView *shell_view)
);
proxy_login_setup_tree_view ();
proxy_login_update_tree ();
+ tbox_account_name = e_builder_get_widget (priv->builder, "account_name");
+ gtk_widget_grab_focus (tbox_account_name);
g_signal_connect (GTK_DIALOG (priv->main), "response", G_CALLBACK(proxy_login_cb), e_shell_view_get_shell_window (shell_view));
gtk_widget_show (GTK_WIDGET (priv->main));
diff --git a/po/POTFILES.in b/po/POTFILES.in
index d165c725ce..9b7a9f6930 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -151,7 +151,6 @@ capplet/settings/mail-settings-view.c
data/evolution-alarm-notify.desktop.in.in
data/evolution.desktop.in.in
data/evolution-settings.desktop.in.in
-data/evolution.keys.in.in
e-util/e-activity.c
e-util/e-alert.c
e-util/e-categories-config.c
diff --git a/po/POTFILES.skip b/po/POTFILES.skip
index 0ecfc5e77c..28efafd2f1 100644
--- a/po/POTFILES.skip
+++ b/po/POTFILES.skip
@@ -9,6 +9,9 @@ addressbook/tools/evolution-addressbook-import.c
calendar/gui/calendar-component.c
calendar/gui/dialogs/meeting-page.etspec
calendar/gui/e-pub-utils.c
+data/evolution-alarm-notify.desktop.in
+data/evolution-settings.desktop.in
+data/evolution.desktop.in
designs/OOA/ooa.ui
designs/read_receipts/read.ui
mail/em-folder-browser.c
diff --git a/po/et.po b/po/et.po
index 755b63ecf1..a5ae41f53b 100644
--- a/po/et.po
+++ b/po/et.po
@@ -2,12 +2,12 @@
# Estonian translation of Evolution.
#
# Copyright (C) 2001-2006 Free Software Foundation, Inc.
-# Copyright (C) 2007-2009 The GNOME Project.
+# Copyright (C) 2007-2010 The GNOME Project.
# This file is distributed under the same license as the evolution package.
#
# Ilmar Kerm <ikerm hot ee>, 2001.
# Marek Sepp <marek sepp ttu ee>, 2001, 2002.
-# Ivar Smolin <okul linux ee>, 2002, 2003, 2005-2009.
+# Ivar Smolin <okul linux ee>, 2002, 2003, 2005-2010.
# Kaarel Jõgi <kaarel gg ee>, 2002.
# Priit Laes <plaes plaes org>, 2003-2007, 2009, 2010.
# Mattias Põldaru <mahfiaz gmail com>, 2009-2010.
@@ -17,9 +17,9 @@ msgstr ""
"Project-Id-Version: Evolution 2.30\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?"
"product=evolution\n"
-"POT-Creation-Date: 2010-03-24 13:21+0000\n"
-"PO-Revision-Date: 2010-03-08 22:04+0300\n"
-"Last-Translator: Priit Laes <plaes@plaes.org>\n"
+"POT-Creation-Date: 2010-05-21 15:35+0000\n"
+"PO-Revision-Date: 2010-05-24 18:51+0300\n"
+"Last-Translator: Ivar Smolin <okul@linux.ee>\n"
"Language-Team: Estonian <gnome-et@linux.ee>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -1774,9 +1774,6 @@ msgstr "Tähtaja ületanud ülesannete värvus \"#rrggbb\" vormingus."
msgid "Calendars to run alarms for"
msgstr "Kalendrid, mille jaoks alarme käivitada"
-msgid "Check this to use system timezone in Evolution."
-msgstr "Märgi see, et kasutada Evolutionis süsteemi ajavööndit."
-
msgid ""
"Color to draw the Marcus Bains Line in the Time bar (empty for default)."
msgstr "Marcus Bainsi joone värvus ajaribal (vaikimisi tühi)."
@@ -2050,18 +2047,18 @@ msgid ""
"the memo list. \"0\" (Classic View) places the preview pane below the memo "
"list. \"1\" (Vertical View) places the preview pane next to the memo list."
msgstr ""
-"Paigutusstiil määrab, kus asetseb eelvaatluspaan märkmeloendi suhtes. \"0"
-"\" (klassikaline vaade) asetab eelvaatluspaani märkmeloendi alla. \"1"
-"\" (vertikaalne vaade) asetab eelvaatluspaani märkmeloendi kõrvale."
+"Paigutusstiil määrab, kus asetseb eelvaatluspaan märkmeloendi suhtes. "
+"\"0\" (klassikaline vaade) asetab eelvaatluspaani märkmeloendi alla. "
+"\"1\" (vertikaalne vaade) asetab eelvaatluspaani märkmeloendi kõrvale."
msgid ""
"The layout style determines where to place the preview pane in relation to "
"the task list. \"0\" (Classic View) places the preview pane below the task "
"list. \"1\" (Vertical View) places the preview pane next to the task list."
msgstr ""
-"Paigutusstiil määrab, kus asetseb eelvaatluspaan ülesandeloendi suhtes. \"0"
-"\" (klassikaline vaade) asetab eelvaatluspaani ülesandeloendi alla. \"1"
-"\" (vertikaalne vaade) asetab eelvaatluspaani ülesandeloendi kõrvale."
+"Paigutusstiil määrab, kus asetseb eelvaatluspaan ülesandeloendi suhtes. "
+"\"0\" (klassikaline vaade) asetab eelvaatluspaani ülesandeloendi alla. "
+"\"1\" (vertikaalne vaade) asetab eelvaatluspaani ülesandeloendi kõrvale."
msgid "The second timezone for a Day View"
msgstr "Päeva vaate teine ajavöönd"
@@ -2230,7 +2227,7 @@ msgid "Category"
msgstr "Kategooria"
msgid "Classification"
-msgstr "Liigitamine"
+msgstr "Liigitus"
msgid "Confidential"
msgstr "Salajane"
@@ -2899,6 +2896,12 @@ msgstr "_Alarmid"
msgid "Click here to set or unset alarms for this event"
msgstr "Klõpsa siia, et seada või eemaldada selle sündmuse alarme"
+msgid "Show Time as _Busy"
+msgstr "Näita aega _hõivatuna"
+
+msgid "Toggles whether to show time as busy"
+msgstr "Aja kui hõivatud aja kuvamise sisse- ja väljalülitamine"
+
msgid "_Recurrence"
msgstr "_Kordumine"
@@ -2917,12 +2920,6 @@ msgstr "Kogu _päeva kestev sündmus"
msgid "Toggles whether to have All Day Event"
msgstr "Kogu päeva hõlmava sündmuse sisse- ja väljalülitamine"
-msgid "Show Time as _Busy"
-msgstr "Näita aega _hõivatuna"
-
-msgid "Toggles whether to show time as busy"
-msgstr "Aja kui hõivatud aja kuvamise sisse- ja väljalülitamine"
-
msgid "_Free/Busy"
msgstr "_Vaba/hõivatud"
@@ -4278,7 +4275,7 @@ msgid "%d %b %Y"
msgstr "%d. %B %Y"
msgid "Jump button"
-msgstr ""
+msgstr "Liikumise nupp"
msgid "Click here, you can find more events."
msgstr "Täiendavate sündmuste leidmiseks klõpsa siia."
@@ -5982,10 +5979,8 @@ msgstr "Klõpsa siia, et valida kaustad kuhu postitada"
msgid "Undo the last action"
msgstr "Viimase tegevuse tagasivõtmine"
-#, fuzzy
-#| msgid "Send Latest Information"
msgid "Redo the last undone action"
-msgstr "Värskemate andmete saatmine"
+msgstr "Viimase tagasivõetud tegevuse uuesti sooritamine"
msgid "Search for text"
msgstr "Tekstiotsing"
@@ -6121,154 +6116,125 @@ msgid "_Save Draft"
msgstr "_Salvesta mustand"
msgid "Run Anjal in a window"
-msgstr ""
+msgstr "Anjali jooksutamine aknas"
-#, fuzzy
-#| msgid "Mark as _default memo list"
msgid "Make Anjal the default email client"
-msgstr "Märgitud _vaikimisi märkmeloendiks"
+msgstr "Anjali määramine vaikimisi meilikliendiks"
#. TRANSLATORS: don't translate the terms in brackets
msgid "ID of the socket to embed in"
-msgstr ""
+msgstr "Pesa ID, millesse kaasatakse"
-#, fuzzy
-#| msgid "sort"
msgid "socket"
-msgstr "sordi"
+msgstr "pesa"
-#, fuzzy
-#| msgid "Default Mail Client"
msgid "Anjal email client"
-msgstr "Vaikimisi postiklient"
+msgstr "Anjal meiliklient"
-#, fuzzy
-#| msgid "New _Task"
-msgid "New Tab"
-msgstr "Uus ü_lesanne"
-
-#, fuzzy
-#| msgid "Please choose another name."
msgid "Please enter your full name."
-msgstr "Palun vali mõni teine nimi."
+msgstr "Palun sisesta enda täisnimi."
-#, fuzzy
-#| msgid "Using email address"
msgid "Please enter your email address."
-msgstr "Meiliaadressi kasutamine"
+msgstr "Palun sisesta enda meiliaadress."
msgid "The email address you have entered is invalid."
-msgstr ""
+msgstr "Sisestatud meiliaadress ei ole korrektne."
msgid "<span size=\"large\" weight=\"bold\">Personal details:</span>"
-msgstr ""
+msgstr "<span size=\"large\" weight=\"bold\">Isiklikud üksikasjad:</span>"
-#, fuzzy
-#| msgid "_Name:"
msgid "Name:"
-msgstr "_Nimi:"
+msgstr "Nimi:"
-#, fuzzy
-#| msgid "Email _Address:"
msgid "Email address:"
-msgstr "E-posti _aadress:"
+msgstr "E-posti aadress:"
msgid "<span size=\"large\" weight=\"bold\">Receiving details:</span>"
-msgstr ""
+msgstr "<span size=\"large\" weight=\"bold\">Vastuvõtmise üksikasjad:</span>"
-#, fuzzy
-#| msgid "Server _Type:"
msgid "Server type:"
-msgstr "Serveri l_iik:"
+msgstr "Serveri liik:"
-#, fuzzy
-#| msgid "Server Message:"
msgid "Server address:"
-msgstr "Serveri teade:"
+msgstr "Serveri aadress:"
-#, fuzzy
-#| msgid "Us_ername:"
msgid "Username:"
-msgstr "_Kasutajanimi:"
+msgstr "Kasutajanimi:"
-#, fuzzy
-#| msgid "No encryption"
msgid "Use encryption:"
-msgstr "Krüptimine puudub"
+msgstr "Kasutatav krüptimine:"
-#, fuzzy
-#| msgid "Never"
msgid "never"
-msgstr "Mitte kunagi"
+msgstr "mitte kunagi"
msgid "<span size=\"large\" weight=\"bold\">Sending details:</span>"
-msgstr ""
+msgstr "<span size=\"large\" weight=\"bold\">Saatmise üksikasjad:</span>"
msgid ""
"To use the email application you'll need to setup an account. Put your email "
"address and password in below and we'll try and work out all the settings. "
"If we can't do it automatically you'll need your server details as well."
msgstr ""
+"Meilirakenduse kasutamiseks tuleb seadistada konto. Sisesta allapoole oma "
+"meiliaadress ja konto ning püüame kõik sätted määrata. Kui seda pole "
+"võimalik automaatselt teha, tuleb sisestada ka serveri andmed."
msgid ""
"Sorry, we can't work out the settings to get your mail automatically. Please "
"enter them below. We've tried to make a start with the details you just "
"entered but you may need to change them."
msgstr ""
+"Kahjuks me ei suutnud meilisätteid automaatselt tuvastada. Palun sisesta "
+"need allapoole. Püüdsime alustada sätetega, mille sa just sisestasid, aga "
+"võimalik, et neid tuleb muuta."
msgid "You can specify more options to configure the account."
-msgstr ""
+msgstr "Võid konto seadistamiseks sisestada rohkem sätteid."
msgid ""
"Now we need your settings for sending mail. We've tried to make some guesses "
"but you should check them over to make sure."
msgstr ""
+"Nüüd on vajalikud meilisaatmise sätted. Püüdsime need ära arvata, aga "
+"kindluse mõttes tuleks need üle kontrollida."
msgid "You can specify your default settings for your account."
-msgstr ""
+msgstr "Võid määrata oma konto vaikimisi sätted."
msgid ""
"Time to check things over before we try and connect to the server and fetch "
"your mail."
msgstr ""
+"Sobilik aeg kontrollida sätted üle enne, kui ühendume serveriga ja tõmbame "
+"kirjad alla."
msgid "Identity"
msgstr "Identiteet"
-#, fuzzy
-#| msgid "Receiving Email"
msgid "Next - Receiving mail"
-msgstr "E-posti vastuvõtmine"
+msgstr "Edasi - e-posti vastuvõtmine"
#, fuzzy
#| msgid "Receiving Email"
msgid "Receiving mail"
msgstr "E-posti vastuvõtmine"
-#, fuzzy
-#| msgid "Sending Email"
msgid "Next - Sending mail"
-msgstr "Kirjade saatmine"
+msgstr "Edasi - kirjade saatmine"
-#, fuzzy
-#| msgid "Identity"
msgid "Back - Identity"
-msgstr "Identiteet"
+msgstr "Tagasi - identiteet"
-#, fuzzy
-#| msgid "Receiving Options"
msgid "Next - Receiving options"
-msgstr "Vastuvõtmise valikud"
+msgstr "Edasi - vastuvõtmise valikud"
#, fuzzy
#| msgid "Receiving Options"
msgid "Receiving options"
msgstr "Vastuvõtmise valikud"
-#, fuzzy
-#| msgid "Receiving Email"
msgid "Back - Receiving mail"
-msgstr "E-posti vastuvõtmine"
+msgstr "Tagasi - e-posti vastuvõtmine"
#, fuzzy
#| msgid "Sending Email"
@@ -6276,64 +6242,40 @@ msgid "Sending mail"
msgstr "Kirjade saatmine"
msgid "Next - Review account"
-msgstr ""
+msgstr "Edasi - konto ülevaatamine"
-#, fuzzy
-#| msgid "Defaults"
msgid "Next - Defaults"
-msgstr "Vaikimisi"
+msgstr "Edasi - vaikimisi"
-#, fuzzy
-#| msgid "Receiving Options"
msgid "Back - Receiving options"
-msgstr "Vastuvõtmise valikud"
+msgstr "Tagasi - vastuvõtmise valikud"
msgid "Defaults"
msgstr "Vaikimisi"
-#, fuzzy
-#| msgid "Sending Email"
msgid "Back - Sending mail"
-msgstr "Kirjade saatmine"
+msgstr "Tagasi - kirjade saatmine"
-#, fuzzy
-#| msgid "List of accounts"
msgid "Review account"
-msgstr "Kontode nimekiri"
+msgstr "Konto ülevaatus"
msgid "Finish"
-msgstr ""
+msgstr "Lõpeta"
-#, fuzzy
-#| msgid "Ascending"
msgid "Back - Sending"
-msgstr "Kasvavas järjestuses"
+msgstr "Tagasi - saatmine"
-#, fuzzy
-#| msgid "_Close"
msgid "Close Tab"
-msgstr "Sul_ge"
+msgstr "Saki sulgemine"
-#, fuzzy
-#| msgid "Account Editor"
msgid "Account Wizard"
-msgstr "Kontoredaktor"
+msgstr "Konto nõustaja"
#, fuzzy
#| msgid "Evolution Account Assistant"
msgid "Evolution account assistant"
msgstr "Evolutioni kontoabiline"
-#, fuzzy
-#| msgid "Junk Mail Settings"
-msgid "Email Settings"
-msgstr "Rämpsposti sätted"
-
-#, fuzzy
-#| msgid "Quoted"
-msgid "Quit"
-msgstr "Tsitaadina"
-
#. create the local source group
msgid "On This Computer"
msgstr "Kohalikus arvutis"
@@ -6341,18 +6283,14 @@ msgstr "Kohalikus arvutis"
msgid "Modify"
msgstr "Muuda"
-#, fuzzy
-#| msgid "Add a Column"
msgid "Add a new account"
-msgstr "Tulba lisamine"
+msgstr "Uue konto lisamine"
msgid "<span size=\"large\" weight=\"bold\">Account management</span>"
-msgstr ""
+msgstr "<span size=\"large\" weight=\"bold\">Kontohaldus</span>"
-#, fuzzy
-#| msgid "Junk Settings"
msgid "Settings"
-msgstr "Rämpsposti sätted"
+msgstr "Sätted"
msgid "Calendar event notifications"
msgstr "Kalendrisündmuste märguanded"
@@ -6373,16 +6311,11 @@ msgstr "Grupitöövahend"
msgid "Manage your email, contacts and schedule"
msgstr "Oma e-posti, kontaktide ja kalendri haldamine"
-#, fuzzy
-#| msgid "Configuration"
msgid "Configure email accounts"
-msgstr "Seadistused"
-
-msgid "address card"
-msgstr "aadressikaart"
+msgstr "E-posti kontode seadistused"
-msgid "calendar information"
-msgstr "kalendri andmed"
+msgid "Email Settings"
+msgstr "E-posti sätted"
#. Translators: This is a cancelled activity.
#, c-format
@@ -6773,7 +6706,7 @@ msgid "R_ule name:"
msgstr "_Reegli nimi:"
msgid "Find items that meet the following conditions"
-msgstr "Järgnevatele tingimustele vastavate kirjete leidmine"
+msgstr "Kui leitakse järgnevatele tingimustele vastav kirje"
msgid "A_dd Condition"
msgstr "Lisa _tingimus"
@@ -6785,7 +6718,7 @@ msgid "If any conditions are met"
msgstr "Kui vähemalt üks tingimustest on täidetud"
msgid "_Find items:"
-msgstr "_Kirjeid otsitakse:"
+msgstr "_Kirjed sobivad:"
msgid "All related"
msgstr "Kõik seonduvad"
@@ -6812,7 +6745,7 @@ msgid "Add Rule"
msgstr "Reegli lisamine"
msgid "Edit Rule"
-msgstr "Muuda reeglit"
+msgstr "Reegli muutmine"
msgid "Bad regular expression &quot;{0}&quot;."
msgstr "Vigane regulaaravaldis &quot;{0}&quot;."
@@ -7647,13 +7580,12 @@ msgstr "Evolutioni kontoabiline"
#. Translators: First %s is an email address, second %s is the subject of the email, third %s is the date
#, c-format
msgid "Your message to %s about \"%s\" on %s has been read."
-msgstr ""
+msgstr "Sinu sõnumit vastuvõtjale %s teemal \"%s\" loeti %s."
#. Translators: %s is the subject of the email message
-#, fuzzy, c-format
-#| msgid "Mail Notification Properties"
+#, c-format
msgid "Delivery Notification for: \"%s\""
-msgstr "Sõnumiteavituse omadused"
+msgstr "Sõnumiteavitus kirjale \"%s\""
msgid "an unknown sender"
msgstr "tundmatu saatja"
@@ -7856,7 +7788,7 @@ msgstr "Määramata olek"
#. and now for the action area
msgid "Then"
-msgstr "Siis"
+msgstr "siis"
msgid "Add Ac_tion"
msgstr "Lisa _tegevus"
@@ -8169,9 +8101,9 @@ msgid "Message Filters"
msgstr "Sõnumifiltrid"
#. Drop filename for messages from a mailbox
-#, fuzzy, c-format
+#, c-format
msgid "Messages from %s"
-msgstr "Sõnumid aadressilt %s"
+msgstr "Sõnumid postkastist %s"
msgid "Search _Folders"
msgstr "_Otsingukaustad"
@@ -8880,9 +8812,9 @@ msgid ""
"message list. \"1\" (Vertical View) places the preview pane next to the "
"message list."
msgstr ""
-"Paigutusstiil määrab, kus asetseb eelvaatluspaan sõnumiloendi suhtes. \"0"
-"\" (klassikaline vaade) asetab eelvaatluspaani sõnumiloendi alla. \"1"
-"\" (vertikaalne vaade) asetab eelvaatluspaani sõnumiloendi kõrvale."
+"Paigutusstiil määrab, kus asetseb eelvaatluspaan sõnumiloendi suhtes. "
+"\"0\" (klassikaline vaade) asetab eelvaatluspaani sõnumiloendi alla. "
+"\"1\" (vertikaalne vaade) asetab eelvaatluspaani sõnumiloendi kõrvale."
msgid "The terminal font for mail display."
msgstr "Terminali kirjatüüp sõnumikuvas."
@@ -9551,13 +9483,13 @@ msgid "_Use the same fonts as other applications"
msgstr "_Kirjatüüp on sama, mis teistes rakendustes"
msgid "a"
-msgstr ""
+msgstr "a"
msgid "addresses"
msgstr "aadressid"
msgid "b"
-msgstr ""
+msgstr "b"
msgid "color"
msgstr "värvusega"
@@ -10276,7 +10208,7 @@ msgstr ""
"{0}"
msgid "The script file must exist and be executable."
-msgstr "Skriptifail peab eksisteerima ja olema käivitatav."
+msgstr "Skriptifail peab olemas olema ja samuti olema käivitatav."
msgid ""
"This folder may have been added implicitly,\n"
@@ -10618,9 +10550,9 @@ msgid ""
"contact list. \"1\" (Vertical View) places the preview pane next to the "
"contact list."
msgstr ""
-"Paigutusstiil määrab, kus asetseb eelvaatluspaan kontaktiloendi suhtes. \"0"
-"\" (klassikaline vaade) asetab eelvaatluspaani kontaktiloendi alla. \"1"
-"\" (vertikaalne vaade) asetab eelvaatluspaani kontaktiloendi kõrvale."
+"Paigutusstiil määrab, kus asetseb eelvaatluspaan kontaktiloendi suhtes. "
+"\"0\" (klassikaline vaade) asetab eelvaatluspaani kontaktiloendi alla. "
+"\"1\" (vertikaalne vaade) asetab eelvaatluspaani kontaktiloendi kõrvale."
msgid ""
"The number of characters that must be typed before Evolution will attempt to "
@@ -11322,7 +11254,7 @@ msgid "Summary contains"
msgstr "Kokkuvõte sisaldab"
msgid "Print this calendar"
-msgstr "Kalendri printimine"
+msgstr "Valitud kalendri printimine"
msgid "Preview the calendar to be printed"
msgstr "Prinditava kalendri eelvaatlemine"
@@ -12165,8 +12097,8 @@ msgstr "Evolutioni kontode ja seadistuste varundamine"
msgid "Backing Evolution data (Mails, Contacts, Calendar, Tasks, Memos)"
msgstr ""
-"Evolutioni andmete (e-post, kontaktid, kalender, ülesanded, märkmed) "
-"varundamine"
+"Evolutioni andmete varundamine (e-post, kontaktid, kalender, ülesanded, "
+"märkmed)"
msgid "Backup complete"
msgstr "Varundamine on valmis"
@@ -12178,7 +12110,7 @@ msgid "Backup current Evolution data"
msgstr "Praeguste Evolutioni andmete varundamine"
msgid "Extracting files from backup"
-msgstr "Varukoopiast failide väljavõtmine"
+msgstr "Failide lahtipakkimine varukoopiast"
msgid "Loading Evolution settings"
msgstr "Evolutioni sätete laadimine"
@@ -13015,7 +12947,7 @@ msgid "Reminder Notes"
msgstr "Meeldetuletaja märkmed"
msgid "Subscribe to my _alarms"
-msgstr "Minu _häirete tellimine"
+msgstr "Minu _alarmide tellimine"
msgid "Subscribe to my _notifications"
msgstr "Minu _märguannete tellimine"
@@ -14192,7 +14124,7 @@ msgstr ""
"nõutud."
msgid "Show s_uppressed HTML parts as attachments"
-msgstr "Mittekuvatud HTML-i näidatakse manusena"
+msgstr "Mittek_uvatud HTML-i näidatakse manusena"
msgid "HTML _Mode"
msgstr "_HTML-režiim"
@@ -14634,17 +14566,15 @@ msgstr "Akna vaikimisi olek"
msgid "Default window width"
msgstr "Akna vaikimisi laius"
-#, fuzzy
-#| msgid "Enable search folders"
msgid "Enable express mode"
-msgstr "Otsingukaustade lubamine"
+msgstr "Ekspressrežiimi lubamine"
msgid ""
"Enables the proxy settings when accessing HTTP/Secure HTTP over the Internet."
msgstr "Proksi sätete lubamine HTTP ja HTTPS protokollidele."
msgid "Flag that enables a much simplified user interface."
-msgstr ""
+msgstr "Lipp, mis määrab oluliselt lihtsustatud kasutajaliidese kasutamise."
msgid "HTTP proxy host name"
msgstr "HTTP-proksi hostinimi"
@@ -14973,10 +14903,10 @@ msgid "translator-credits"
msgstr ""
"Ilmar Kerm <ikerm hot ee>, 2001.\n"
"Marek Sepp <marek sepp ttu ee>, 2001, 2002.\n"
-"Ivar Smolin <okul linux ee>, 2002, 2003, 2005-2009.\n"
+"Ivar Smolin <okul linux ee>, 2002, 2003, 2005–2010.\n"
"Kaarel Jõgi <kaarel gg ee>, 2002.\n"
-"Priit Laes <plaes plaes org>, 2003-2007, 2009, 2010.\n"
-"Mattias Põldaru <mahfiaz gmail com>, 2009-2010."
+"Priit Laes <plaes plaes org>, 2003–2007, 2009, 2010.\n"
+"Mattias Põldaru <mahfiaz gmail com>, 2009–2010."
msgid "Evolution Website"
msgstr "Evolutioni veebisait"
@@ -15085,7 +15015,7 @@ msgid "Submit a bug report using Bug Buddy"
msgstr "Veateate saatmine Bug Buddy abil"
msgid "GNOME Pilot _Synchronization..."
-msgstr "GNOME Pilot-iga sünkroniseerimine..."
+msgstr "GNOME Pilot-iga _sünkroniseerimine..."
msgid "Set up GNOME Pilot configuration"
msgstr "GNOME Piloti sätete määramine"
@@ -15335,10 +15265,8 @@ msgstr "Antud geomeetria rakendamine peaaknale"
msgid "Start in online mode"
msgstr "Alustamine võrgurežiimis"
-#, fuzzy
-#| msgid "Start in online mode"
msgid "Start in \"express\" mode"
-msgstr "Alustamine võrgurežiimis"
+msgstr "Alustamine ekspressrežiimis"
msgid "Forcibly shut down Evolution"
msgstr "Evolutioni sundimine töö lõpetamisele"
@@ -16498,7 +16426,7 @@ msgid "_Until:"
msgstr "_Kuni:"
msgid "_When convenient"
-msgstr "_Kui sobiv"
+msgstr "_Kui sobib"
msgid "_When opened:"
msgstr "Kui _avatakse:"
@@ -16519,7 +16447,7 @@ msgid "Add Signature Script"
msgstr "Allkirjaskripti lisamine"
msgid "Edit Signature Script"
-msgstr "Allkirja muutmine"
+msgstr "Allkirjaskripti muutmine"
msgid "Add _Script"
msgstr "Lisa _skript"
diff --git a/shell/main.c b/shell/main.c
index 90d534f5d4..02bc094480 100644
--- a/shell/main.c
+++ b/shell/main.c
@@ -61,6 +61,9 @@
#include "e-util/e-profile-event.h"
#include "e-util/e-util-private.h"
#include "e-util/e-util.h"
+#ifdef G_OS_WIN32
+#include "e-util/e-win32-defaults.h"
+#endif
#include <fcntl.h>
#include <signal.h>
@@ -78,6 +81,11 @@
#endif
/* Command-line options. */
+#ifdef G_OS_WIN32
+static gboolean reinstall = FALSE;
+static gboolean show_icons = FALSE;
+static gboolean hide_icons = FALSE;
+#endif /* G_OS_WIN32 */
static gboolean express_mode = FALSE;
static gboolean start_online = FALSE;
static gboolean start_offline = FALSE;
@@ -319,6 +327,14 @@ setup_segv_redirect (void)
#endif
static GOptionEntry entries[] = {
+#ifdef G_OS_WIN32
+ { "reinstall", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &reinstall,
+ NULL, NULL },
+ { "show-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &show_icons,
+ NULL, NULL },
+ { "hide-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &hide_icons,
+ NULL, NULL },
+#endif /* G_OS_WIN32 */
{ "component", 'c', 0, G_OPTION_ARG_STRING, &requested_view,
N_("Start Evolution activating the specified component"), NULL },
{ "geometry", 'g', 0, G_OPTION_ARG_STRING, &geometry,
@@ -460,13 +476,6 @@ main (gint argc, gchar **argv)
dup2 (fileno (stderr), 2);
}
}
-
- path = g_build_path (";", _e_get_bindir (), g_getenv ("PATH"), NULL);
-
- if (!g_setenv ("PATH", path, TRUE))
- g_warning ("Could not set PATH for Evolution and its child processes");
-
- g_free (path);
#endif
/* Make ElectricFence work. */
@@ -492,6 +501,30 @@ main (gint argc, gchar **argv)
dbus_g_thread_init ();
#ifdef G_OS_WIN32
+ path = g_build_path (";", _e_get_bindir (), g_getenv ("PATH"), NULL);
+
+ if (!g_setenv ("PATH", path, TRUE))
+ g_warning ("Could not set PATH for Evolution and its child processes");
+
+ g_free (path);
+
+ _e_win32_register_mailer ();
+
+ if (reinstall) {
+ _e_win32_set_default_mailer ();
+ exit (0);
+ }
+
+ if (show_icons) {
+ _e_win32_set_default_mailer ();
+ exit (0);
+ }
+
+ if (hide_icons) {
+ _e_win32_unset_default_mailer ();
+ exit (0);
+ }
+
if (strcmp (gettext (""), "") == 0) {
/* No message catalog installed for the current locale
* language, so don't bother with the localisations
@@ -529,6 +562,9 @@ main (gint argc, gchar **argv)
key = "/apps/evolution/addressbook/display/show_preview";
gconf_client_set_bool (client, key, FALSE, NULL);
+ key = "/apps/evolution/calendar/display/show_memo_preview";
+ gconf_client_set_bool (client, key, FALSE, NULL);
+
key = "/apps/evolution/calendar/display/show_task_preview";
gconf_client_set_bool (client, key, FALSE, NULL);
}
diff --git a/widgets/misc/e-attachment-icon-view.c b/widgets/misc/e-attachment-icon-view.c
index edfecb57d8..57301213dd 100644
--- a/widgets/misc/e-attachment-icon-view.c
+++ b/widgets/misc/e-attachment-icon-view.c
@@ -130,6 +130,20 @@ attachment_icon_view_button_release_event (GtkWidget *widget,
}
static gboolean
+attachment_icon_view_motion_notify_event (GtkWidget *widget,
+ GdkEventMotion *event)
+{
+ EAttachmentView *view = E_ATTACHMENT_VIEW (widget);
+
+ if (e_attachment_view_motion_notify_event (view, event))
+ return TRUE;
+
+ /* Chain up to parent's motion_notify_event() method. */
+ return GTK_WIDGET_CLASS (parent_class)->
+ motion_notify_event (widget, event);
+}
+
+static gboolean
attachment_icon_view_key_press_event (GtkWidget *widget,
GdkEventKey *event)
{
@@ -408,6 +422,7 @@ attachment_icon_view_class_init (EAttachmentIconViewClass *class)
widget_class = GTK_WIDGET_CLASS (class);
widget_class->button_press_event = attachment_icon_view_button_press_event;
widget_class->button_release_event = attachment_icon_view_button_release_event;
+ widget_class->motion_notify_event = attachment_icon_view_motion_notify_event;
widget_class->key_press_event = attachment_icon_view_key_press_event;
widget_class->drag_begin = attachment_icon_view_drag_begin;
widget_class->drag_end = attachment_icon_view_drag_end;
diff --git a/widgets/misc/e-attachment-paned.c b/widgets/misc/e-attachment-paned.c
index 8b4c2bfb96..d47fe9c8c7 100644
--- a/widgets/misc/e-attachment-paned.c
+++ b/widgets/misc/e-attachment-paned.c
@@ -92,36 +92,6 @@ attachment_paned_notify_cb (EAttachmentPaned *paned,
}
static void
-attachment_paned_sync_icon_view (EAttachmentPaned *paned)
-{
- EAttachmentView *source;
- EAttachmentView *target;
-
- source = E_ATTACHMENT_VIEW (paned->priv->tree_view);
- target = E_ATTACHMENT_VIEW (paned->priv->icon_view);
-
- /* Only sync if the tree view is active. This prevents the
- * two views from endlessly trying to sync with each other. */
- if (e_attachment_paned_get_active_view (paned) == 1)
- e_attachment_view_sync_selection (source, target);
-}
-
-static void
-attachment_paned_sync_tree_view (EAttachmentPaned *paned)
-{
- EAttachmentView *source;
- EAttachmentView *target;
-
- source = E_ATTACHMENT_VIEW (paned->priv->icon_view);
- target = E_ATTACHMENT_VIEW (paned->priv->tree_view);
-
- /* Only sync if the icon view is active. This prevents the
- * two views from endlessly trying to sync with each other. */
- if (e_attachment_paned_get_active_view (paned) == 0)
- e_attachment_view_sync_selection (source, target);
-}
-
-static void
attachment_paned_update_status (EAttachmentPaned *paned)
{
EAttachmentView *view;
@@ -509,7 +479,6 @@ static void
attachment_paned_init (EAttachmentPaned *paned)
{
EAttachmentView *view;
- GtkTreeSelection *selection;
GtkSizeGroup *size_group;
GtkWidget *container;
GtkWidget *widget;
@@ -662,17 +631,6 @@ attachment_paned_init (EAttachmentPaned *paned)
paned->priv->status_label = g_object_ref (widget);
gtk_widget_hide (widget);
- selection = gtk_tree_view_get_selection (
- GTK_TREE_VIEW (paned->priv->tree_view));
-
- g_signal_connect_swapped (
- selection, "changed",
- G_CALLBACK (attachment_paned_sync_icon_view), paned);
-
- g_signal_connect_swapped (
- paned->priv->icon_view, "selection-changed",
- G_CALLBACK (attachment_paned_sync_tree_view), paned);
-
g_signal_connect_swapped (
paned->priv->expander, "notify::expanded",
G_CALLBACK (attachment_paned_notify_cb), paned);
@@ -750,11 +708,31 @@ void
e_attachment_paned_set_active_view (EAttachmentPaned *paned,
gint active_view)
{
+ EAttachmentView *source;
+ EAttachmentView *target;
+
g_return_if_fail (E_IS_ATTACHMENT_PANED (paned));
g_return_if_fail (active_view >= 0 && active_view < NUM_VIEWS);
+ if (active_view == paned->priv->active_view)
+ return;
+
paned->priv->active_view = active_view;
+ /* Synchronize the item selection of the view we're
+ * switching TO with the view we're switching FROM. */
+ if (active_view == 0) {
+ /* from tree view to icon view */
+ source = E_ATTACHMENT_VIEW (paned->priv->tree_view);
+ target = E_ATTACHMENT_VIEW (paned->priv->icon_view);
+ } else {
+ /* from icon view to tree view */
+ source = E_ATTACHMENT_VIEW (paned->priv->icon_view);
+ target = E_ATTACHMENT_VIEW (paned->priv->tree_view);
+ }
+
+ e_attachment_view_sync_selection (source, target);
+
g_object_notify (G_OBJECT (paned), "active-view");
}
diff --git a/widgets/misc/e-attachment-tree-view.c b/widgets/misc/e-attachment-tree-view.c
index 5729a68069..09602ca186 100644
--- a/widgets/misc/e-attachment-tree-view.c
+++ b/widgets/misc/e-attachment-tree-view.c
@@ -144,6 +144,20 @@ attachment_tree_view_button_release_event (GtkWidget *widget,
}
static gboolean
+attachment_tree_view_motion_notify_event (GtkWidget *widget,
+ GdkEventMotion *event)
+{
+ EAttachmentView *view = E_ATTACHMENT_VIEW (widget);
+
+ if (e_attachment_view_motion_notify_event (view, event))
+ return TRUE;
+
+ /* Chain up to parent's motion_notify_event() method. */
+ return GTK_WIDGET_CLASS (parent_class)->
+ motion_notify_event (widget, event);
+}
+
+static gboolean
attachment_tree_view_key_press_event (GtkWidget *widget,
GdkEventKey *event)
{
@@ -440,6 +454,7 @@ attachment_tree_view_class_init (EAttachmentTreeViewClass *class)
widget_class = GTK_WIDGET_CLASS (class);
widget_class->button_press_event = attachment_tree_view_button_press_event;
widget_class->button_release_event = attachment_tree_view_button_release_event;
+ widget_class->motion_notify_event = attachment_tree_view_motion_notify_event;
widget_class->key_press_event = attachment_tree_view_key_press_event;
widget_class->drag_begin = attachment_tree_view_drag_begin;
widget_class->drag_end = attachment_tree_view_drag_end;
diff --git a/widgets/misc/e-attachment-view.c b/widgets/misc/e-attachment-view.c
index 5a5db57e07..2ff6fb4dab 100644
--- a/widgets/misc/e-attachment-view.c
+++ b/widgets/misc/e-attachment-view.c
@@ -875,6 +875,12 @@ e_attachment_view_finalize (EAttachmentView *view)
priv = e_attachment_view_get_private (view);
g_ptr_array_free (priv->handlers, TRUE);
+
+ g_list_foreach (priv->event_list, (GFunc) gdk_event_free, NULL);
+ g_list_free (priv->event_list);
+
+ g_list_foreach (priv->selected, (GFunc) g_object_unref, NULL);
+ g_list_free (priv->selected);
}
EAttachmentViewPrivate *
@@ -1074,80 +1080,149 @@ gboolean
e_attachment_view_button_press_event (EAttachmentView *view,
GdkEventButton *event)
{
+ EAttachmentViewPrivate *priv;
GtkTreePath *path;
gboolean editable;
- gboolean item_clicked;
+ gboolean handled = FALSE;
+ gboolean path_is_selected = FALSE;
g_return_val_if_fail (E_IS_ATTACHMENT_VIEW (view), FALSE);
g_return_val_if_fail (event != NULL, FALSE);
- editable = e_attachment_view_get_editable (view);
+ priv = e_attachment_view_get_private (view);
- /* If the user clicked on a selected item, retain the current
- * selection. If the user clicked on an unselected item, select
- * the clicked item only. If the user did not click on an item,
- * clear the current selection. */
- path = e_attachment_view_get_path_at_pos (view, event->x, event->y);
- if (path != NULL) {
- if (!e_attachment_view_path_is_selected (view, path)) {
- e_attachment_view_unselect_all (view);
- e_attachment_view_select_path (view, path);
- }
- gtk_tree_path_free (path);
- item_clicked = TRUE;
- } else {
- e_attachment_view_unselect_all (view);
- item_clicked = FALSE;
+ if (g_list_find (priv->event_list, event) != NULL)
+ return FALSE;
+
+ if (priv->event_list != NULL) {
+ /* Save the event to be propagated in order. */
+ priv->event_list = g_list_append (
+ priv->event_list,
+ gdk_event_copy ((GdkEvent *) event));
+ return TRUE;
}
- /* Cancel drag and drop if there are no selected items,
- * or if any of the selected items are loading or saving. */
+ editable = e_attachment_view_get_editable (view);
+ path = e_attachment_view_get_path_at_pos (view, event->x, event->y);
+ path_is_selected = e_attachment_view_path_is_selected (view, path);
+
if (event->button == 1 && event->type == GDK_BUTTON_PRESS) {
GList *selected, *iter;
gboolean busy = FALSE;
selected = e_attachment_view_get_selected_attachments (view);
+
for (iter = selected; iter != NULL; iter = iter->next) {
EAttachment *attachment = iter->data;
busy |= e_attachment_get_loading (attachment);
busy |= e_attachment_get_saving (attachment);
}
- if (selected == NULL || busy)
- e_attachment_view_drag_source_unset (view);
+
+ /* Prepare for dragging if the clicked item is selected
+ * and none of the selected items are loading or saving. */
+ if (path_is_selected && !busy) {
+ priv->start_x = event->x;
+ priv->start_y = event->y;
+ priv->event_list = g_list_append (
+ priv->event_list,
+ gdk_event_copy ((GdkEvent *) event));
+ handled = TRUE;
+ }
+
g_list_foreach (selected, (GFunc) g_object_unref, NULL);
g_list_free (selected);
}
if (event->button == 3 && event->type == GDK_BUTTON_PRESS) {
+ /* If the user clicked on a selected item, retain the
+ * current selection. If the user clicked on an unselected
+ * item, select the clicked item only. If the user did not
+ * click on an item, clear the current selection. */
+ if (path == NULL)
+ e_attachment_view_unselect_all (view);
+ else if (!path_is_selected) {
+ e_attachment_view_unselect_all (view);
+ e_attachment_view_select_path (view, path);
+ }
+
/* Non-editable attachment views should only show a
* popup menu when right-clicking on an attachment,
* but editable views can show the menu any time. */
- if (item_clicked || editable) {
+ if (path != NULL || editable) {
e_attachment_view_show_popup_menu (
view, event, NULL, NULL);
- return TRUE;
+ handled = TRUE;
}
}
- return FALSE;
+ if (path != NULL)
+ gtk_tree_path_free (path);
+
+ return handled;
}
gboolean
e_attachment_view_button_release_event (EAttachmentView *view,
GdkEventButton *event)
{
+ EAttachmentViewPrivate *priv;
+ GtkWidget *widget = GTK_WIDGET (view);
+ GList *iter;
+
g_return_val_if_fail (E_IS_ATTACHMENT_VIEW (view), FALSE);
g_return_val_if_fail (event != NULL, FALSE);
- /* Restore the attachment view as a drag source, in case
- * we had to cancel during a button press event. */
- if (event->button == 1)
- e_attachment_view_drag_source_set (view);
+ priv = e_attachment_view_get_private (view);
+
+ for (iter = priv->event_list; iter != NULL; iter = iter->next) {
+ GdkEvent *event = iter->data;
+
+ gtk_propagate_event (widget, event);
+ gdk_event_free (event);
+ }
+
+ g_list_free (priv->event_list);
+ priv->event_list = NULL;
return FALSE;
}
gboolean
+e_attachment_view_motion_notify_event (EAttachmentView *view,
+ GdkEventMotion *event)
+{
+ EAttachmentViewPrivate *priv;
+ GtkWidget *widget = GTK_WIDGET (view);
+ GdkDragContext *context;
+ GtkTargetList *targets;
+
+ g_return_val_if_fail (E_IS_ATTACHMENT_VIEW (view), FALSE);
+ g_return_val_if_fail (event != NULL, FALSE);
+
+ priv = e_attachment_view_get_private (view);
+
+ if (priv->event_list == NULL)
+ return FALSE;
+
+ if (!gtk_drag_check_threshold (
+ widget, priv->start_x, priv->start_y, event->x, event->y))
+ return TRUE;
+
+ g_list_foreach (priv->event_list, (GFunc) gdk_event_free, NULL);
+ g_list_free (priv->event_list);
+ priv->event_list = NULL;
+
+ targets = gtk_drag_source_get_target_list (widget);
+
+ context = gtk_drag_begin (
+ widget, targets, GDK_ACTION_COPY, 1, (GdkEvent *) event);
+
+ gtk_drag_set_icon_default (context);
+
+ return TRUE;
+}
+
+gboolean
e_attachment_view_key_press_event (EAttachmentView *view,
GdkEventKey *event)
{
@@ -1201,7 +1276,10 @@ e_attachment_view_path_is_selected (EAttachmentView *view,
EAttachmentViewIface *iface;
g_return_val_if_fail (E_IS_ATTACHMENT_VIEW (view), FALSE);
- g_return_val_if_fail (path != NULL, FALSE);
+
+ /* Handle NULL paths gracefully. */
+ if (path == NULL)
+ return FALSE;
iface = E_ATTACHMENT_VIEW_GET_IFACE (view);
g_return_val_if_fail (iface->path_is_selected != NULL, FALSE);
@@ -1287,18 +1365,23 @@ e_attachment_view_sync_selection (EAttachmentView *view,
void
e_attachment_view_drag_source_set (EAttachmentView *view)
{
+ EAttachmentViewIface *iface;
GtkTargetEntry *targets;
GtkTargetList *list;
gint n_targets;
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
+ iface = E_ATTACHMENT_VIEW_GET_IFACE (view);
+ if (iface->drag_source_set == NULL)
+ return;
+
list = gtk_target_list_new (NULL, 0);
gtk_target_list_add_uri_targets (list, 0);
targets = gtk_target_table_new_from_list (list, &n_targets);
- gtk_drag_source_set (
- GTK_WIDGET (view), GDK_BUTTON1_MASK,
+ iface->drag_source_set (
+ view, GDK_BUTTON1_MASK,
targets, n_targets, GDK_ACTION_COPY);
gtk_target_table_free (targets, n_targets);
@@ -1308,34 +1391,55 @@ e_attachment_view_drag_source_set (EAttachmentView *view)
void
e_attachment_view_drag_source_unset (EAttachmentView *view)
{
+ EAttachmentViewIface *iface;
+
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
- gtk_drag_source_unset (GTK_WIDGET (view));
+ iface = E_ATTACHMENT_VIEW_GET_IFACE (view);
+ if (iface->drag_source_unset == NULL)
+ return;
+
+ iface->drag_source_unset (view);
}
void
e_attachment_view_drag_begin (EAttachmentView *view,
GdkDragContext *context)
{
+ EAttachmentViewPrivate *priv;
+
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
g_return_if_fail (GDK_IS_DRAG_CONTEXT (context));
+ priv = e_attachment_view_get_private (view);
+
/* Prevent the user from dragging and dropping to
* the same attachment view, which would duplicate
* the attachment. */
e_attachment_view_drag_dest_unset (view);
+
+ g_warn_if_fail (priv->selected == NULL);
+ priv->selected = e_attachment_view_get_selected_attachments (view);
}
void
e_attachment_view_drag_end (EAttachmentView *view,
GdkDragContext *context)
{
+ EAttachmentViewPrivate *priv;
+
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
g_return_if_fail (GDK_IS_DRAG_CONTEXT (context));
+ priv = e_attachment_view_get_private (view);
+
/* Restore the previous drag destination state. */
if (e_attachment_view_get_editable (view))
e_attachment_view_drag_dest_set (view);
+
+ g_list_foreach (priv->selected, (GFunc) g_object_unref, NULL);
+ g_list_free (priv->selected);
+ priv->selected = NULL;
}
static void
@@ -1363,8 +1467,8 @@ e_attachment_view_drag_data_get (EAttachmentView *view,
guint info,
guint time)
{
+ EAttachmentViewPrivate *priv;
EAttachmentStore *store;
- GList *selected;
struct {
gchar **uris;
@@ -1378,19 +1482,16 @@ e_attachment_view_drag_data_get (EAttachmentView *view,
status.uris = NULL;
status.done = FALSE;
+ priv = e_attachment_view_get_private (view);
store = e_attachment_view_get_store (view);
- selected = e_attachment_view_get_selected_attachments (view);
- if (selected == NULL)
+ if (priv->selected == NULL)
return;
e_attachment_store_get_uris_async (
- store, selected, (GAsyncReadyCallback)
+ store, priv->selected, (GAsyncReadyCallback)
attachment_view_got_uris_cb, &status);
- g_list_foreach (selected, (GFunc) g_object_unref, NULL);
- g_list_free (selected);
-
/* We can't return until we have results, so crank
* the main loop until the callback gets triggered. */
while (!status.done)
@@ -1407,19 +1508,22 @@ void
e_attachment_view_drag_dest_set (EAttachmentView *view)
{
EAttachmentViewPrivate *priv;
+ EAttachmentViewIface *iface;
GtkTargetEntry *targets;
gint n_targets;
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
+ iface = E_ATTACHMENT_VIEW_GET_IFACE (view);
+ if (iface->drag_dest_set == NULL)
+ return;
+
priv = e_attachment_view_get_private (view);
targets = gtk_target_table_new_from_list (
priv->target_list, &n_targets);
- gtk_drag_dest_set (
- GTK_WIDGET (view), GTK_DEST_DEFAULT_ALL,
- targets, n_targets, priv->drag_actions);
+ iface->drag_dest_set (view, targets, n_targets, priv->drag_actions);
gtk_target_table_free (targets, n_targets);
}
@@ -1427,9 +1531,15 @@ e_attachment_view_drag_dest_set (EAttachmentView *view)
void
e_attachment_view_drag_dest_unset (EAttachmentView *view)
{
+ EAttachmentViewIface *iface;
+
g_return_if_fail (E_IS_ATTACHMENT_VIEW (view));
- gtk_drag_dest_unset (GTK_WIDGET (view));
+ iface = E_ATTACHMENT_VIEW_GET_IFACE (view);
+ if (iface->drag_dest_unset == NULL)
+ return;
+
+ iface->drag_dest_unset (view);
}
gboolean
diff --git a/widgets/misc/e-attachment-view.h b/widgets/misc/e-attachment-view.h
index 89d2d28664..071de0705a 100644
--- a/widgets/misc/e-attachment-view.h
+++ b/widgets/misc/e-attachment-view.h
@@ -103,6 +103,12 @@ struct _EAttachmentViewPrivate {
GtkUIManager *ui_manager;
guint merge_id;
+ /* Multi-DnD State */
+ GList *event_list;
+ GList *selected;
+ gint start_x;
+ gint start_y;
+
guint editable : 1;
};
@@ -139,6 +145,9 @@ gboolean e_attachment_view_button_press_event
gboolean e_attachment_view_button_release_event
(EAttachmentView *view,
GdkEventButton *event);
+gboolean e_attachment_view_motion_notify_event
+ (EAttachmentView *view,
+ GdkEventMotion *event);
gboolean e_attachment_view_key_press_event
(EAttachmentView *view,
GdkEventKey *event);