Index: mail/ChangeLog
===================================================================
--- mail/ChangeLog	(revision 34980)
+++ mail/ChangeLog	(working copy)
@@ -1,3 +1,10 @@
+2008-02-26  Qinkuangyu  <qinkuangyu@gmail.com>
+
+        ** Fix for bug #458506
+	
+	* em-folder-view.c: 
+	Add Forward As submenu and menuitems in popup menu
+
 2008-02-08  Matthew Barnes  <mbarnes@redhat.com>
 
 	** Fixes part of bug #509741
Index: mail/em-folder-view.c
===================================================================
--- mail/em-folder-view.c	(revision 34980)
+++ mail/em-folder-view.c	(working copy)
@@ -945,6 +945,59 @@
 }
 
 static void
+emfv_popup_forward_attached (EPopup *ep, EPopupItem *pitem, void *data)
+{
+	EMFolderView *emfv = data;
+	GPtrArray *uids;
+
+	if (!em_utils_check_user_can_send_mail ((GtkWidget *) emfv))
+		return;
+
+	uids = message_list_get_selected (emfv->list);
+	em_utils_forward_attached (emfv->folder, uids, emfv->folder_uri);
+}
+
+static void
+emfv_popup_forward_inline (EPopup *ep, EPopupItem *pitem, void *data)
+{
+	EMFolderView *emfv = data;
+	GPtrArray *uids;
+
+	if (!em_utils_check_user_can_send_mail ((GtkWidget *) emfv))
+		return;
+
+	uids = message_list_get_selected (emfv->list);
+	em_utils_forward_inline (emfv->folder, uids, emfv->folder_uri);
+}
+
+static void
+emfv_popup_forward_quoted (EPopup *ep, EPopupItem *pitem, void *data)
+{
+	EMFolderView *emfv = data;
+	GPtrArray *uids;
+
+	if (!em_utils_check_user_can_send_mail ((GtkWidget *) emfv))
+		return;
+
+	uids = message_list_get_selected (emfv->list);
+	em_utils_forward_quoted (emfv->folder, uids, emfv->folder_uri);
+}
+
+static void
+emfv_popup_forward_redirect (EPopup *ep, EPopupItem *pitem, void *data)
+{
+	EMFolderView *emfv = data;
+
+	if (emfv->list->cursor_uid == NULL)
+		return;
+
+	if (!em_utils_check_user_can_send_mail ((GtkWidget *) emfv))
+		return;
+
+	em_utils_redirect_message_by_uid (emfv->folder, emfv->list->cursor_uid);
+}
+
+static void
 emfv_popup_flag_followup(EPopup *ep, EPopupItem *pitem, void *data)
 {
 	EMFolderView *emfv = data;
@@ -1334,6 +1387,12 @@
 	{ E_POPUP_ITEM, "10.emfv.00", N_("_Reply to Sender"), emfv_popup_reply_sender, NULL, "mail-reply-sender", EM_POPUP_SELECT_ONE },
 	{ E_POPUP_ITEM, "10.emfv.01", N_("Reply to _All"), emfv_popup_reply_all, NULL, "mail-reply-all", EM_POPUP_SELECT_ONE },
 	{ E_POPUP_ITEM, "10.emfv.02", N_("_Forward"), emfv_popup_forward, NULL, "mail-forward", EM_POPUP_SELECT_MANY },
+  { E_POPUP_SUBMENU, "10.emfv.03", N_("F_orward As"), NULL, NULL, NULL, EM_POPUP_SELECT_MANY|EM_FOLDER_VIEW_SELECT_LISTONLY },
+  { E_POPUP_ITEM, "10.emfv.03/00.00", N_("_Attached"), emfv_popup_forward_attached, NULL, NULL, EM_POPUP_SELECT_MANY },
+  { E_POPUP_ITEM, "10.emfv.03/00.01", N_("_Inline"), emfv_popup_forward_inline, NULL, NULL, EM_POPUP_SELECT_ONE },
+  { E_POPUP_ITEM, "10.emfv.03/00.02", N_("_Quated"), emfv_popup_forward_quoted, NULL, NULL, EM_POPUP_SELECT_ONE },
+  { E_POPUP_BAR, "10.emfv.03/10", NULL, NULL, NULL, NULL },
+  { E_POPUP_ITEM, "10.emfv.03/10.00", N_("Re_direct"), emfv_popup_forward_redirect, NULL, NULL, EM_POPUP_SELECT_ONE },
 
 	{ E_POPUP_BAR, "20.emfv", NULL, NULL, NULL, NULL },
 	/* EM_POPUP_EDIT was used here. This is changed to EM_POPUP_SELECT_ONE as Edit-as-new-messaeg need not be restricted to Sent-Items folder alone */
