home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / winfe / mailfrm.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  16.4 KB  |  485 lines

  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  2.  *
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18.  
  19. #ifndef _MAILFRM_H
  20. #define _MAILFRM_H
  21. #include "mailmisc.h"
  22. #include "mailpriv.h"
  23.  
  24. #ifndef _APIMSG_H
  25. #include "apimsg.h"
  26. #endif
  27.  
  28. #ifndef DYNAMIC_DOWNCAST
  29. #define DYNAMIC_DOWNCAST( classname, ptr ) ((classname *)(ptr))
  30. #endif
  31.  
  32. #ifndef DOWNCAST
  33. #define DOWNCAST( classname, ptr ) ((classname *)(ptr))
  34. #endif
  35.  
  36. // mailfrm.h : header file
  37. //
  38.  
  39. #define    SORT_BYDATE        0        
  40. #define    SORT_BYSUBJECT    1
  41. #define    SORT_BYSENDER    2
  42. #define    SORT_BYNUMBER    3
  43. #define    SORT_BYPRIORITY    4
  44. #define SORT_BYTHREAD    5
  45. #define SORT_BYSTATUS    6
  46. #define SORT_BYSIZE        7
  47. #define SORT_BYFLAG        8
  48. #define SORT_BYUNREAD    9
  49.  
  50. #define THREADS_NEW        0
  51. #define THREADS_ALL        1
  52. #define THREADS_WATCHED    2
  53. #define THREADS_KILLED    3
  54. #define THREADS_NEWONLY    4
  55.  
  56. #define IDW_FOLDER_PANE            AFX_IDW_PANE_FIRST
  57. #define IDW_THREAD_PANE            (AFX_IDW_PANE_FIRST+1)
  58. #define IDW_MESSAGE_PANE        (AFX_IDW_PANE_FIRST+2)
  59. #define IDW_CATEGORY_PANE        (AFX_IDW_PANE_FIRST+3)
  60. #define IDW_ATTACHMENTS_PANE    (AFX_IDW_PANE_FIRST+4)
  61. #define IDW_MESSAGE_VIEW        (AFX_IDW_PANE_FIRST+5)
  62.  
  63. /////////////////////////////////////////////////////////////////////////////
  64. // CMailNewsCX
  65.  
  66. class CMailNewsCX: public CStubsCX {
  67. protected:
  68.     LPCHROME m_pIChrome;
  69.  
  70.     CFrameWnd *m_pFrame;
  71.  
  72.     int32 m_lPercent;
  73.     CString m_csProgress;
  74.     BOOL m_bAnimated;
  75.  
  76. public:
  77.     CMailNewsCX(ContextType ctMyType, CFrameWnd *pFrame);
  78.     ~CMailNewsCX();
  79.  
  80.     LPUNKNOWN GetChrome() const { return m_pIChrome; }
  81.     void SetChrome( LPUNKNOWN pChrome );
  82.  
  83. public:
  84.     int32 QueryProgressPercent();
  85.     void SetProgressBarPercent(MWContext *pContext, int32 lPercent);
  86.  
  87.     void SetDocTitle( MWContext *pContext, char *pTitle );
  88.  
  89.     void StartAnimation();
  90.     void StopAnimation();
  91.  
  92.     void Progress(MWContext *pContext, const char *pMessage);
  93.     void AllConnectionsComplete(MWContext *pContext);
  94.  
  95.     void UpdateStopState( MWContext *pContext );
  96.     
  97.     CWnd *GetDialogOwner() const;
  98. };
  99.  
  100. class C3PaneMailFrame;
  101. class CFolderFrame;
  102. class CMessageFrame;
  103. class CMailInfoBar;
  104. class CMessageView;
  105. class CFolderPropertyPage;
  106. class CDiskSpaceProptertyPage;
  107.  
  108. extern int g_iModalDelay;
  109. #define MODAL_DELAY (g_iModalDelay)
  110.  
  111. /////////////////////////////////////////////////////////////////////////////
  112. // CMailNewsFrame frame
  113.  
  114. class CMailNewsFrame : public CGenericFrame, public IMailFrame
  115. {
  116.     DECLARE_DYNCREATE(CMailNewsFrame)
  117.  
  118. protected:
  119.     unsigned long m_ulRefCount;
  120.  
  121.     HACCEL m_hAccel;
  122.  
  123. public:
  124. // IUnknown Interface
  125.     STDMETHODIMP            QueryInterface(REFIID,LPVOID *);
  126.     STDMETHODIMP_(ULONG)    AddRef(void);
  127.     STDMETHODIMP_(ULONG)    Release(void);
  128.  
  129. // Support for IMailFrame
  130.     virtual CMailNewsFrame *GetMailNewsFrame();
  131.     virtual MSG_Pane *GetPane();
  132.     virtual void PaneChanged( MSG_Pane *pane, XP_Bool asynchronous, 
  133.                               MSG_PANE_CHANGED_NOTIFY_CODE, int32 value);
  134.     virtual void AttachmentCount(MSG_Pane *messagepane, void* closure,
  135.                                  int32 numattachments, XP_Bool finishedloading);
  136.     virtual void UserWantsToSeeAttachments(MSG_Pane *messagepane, void *closure);
  137.  
  138. protected:
  139.     CMailNewsFrame();           // protected constructor used by dynamic creation
  140.  
  141. // Attributes
  142.  
  143.     MSG_Pane *m_pPane;
  144.     MSG_Pane *m_pMessagePane;
  145.     MSG_Master *m_pMaster;
  146.     BOOL m_bNews; // Are we showing mail or news?
  147.     BOOL m_bCategory;
  148.     CMailNewsOutliner *m_pOutliner;
  149.     CMailInfoBar *m_pInfoBar;
  150.  
  151.  
  152.     MSG_AttachmentData *m_pAttachmentData;
  153.     int32 m_nAttachmentCount;
  154.     CMessageView *m_pMessageView;
  155.  
  156. protected:
  157.     virtual ~CMailNewsFrame();
  158.  
  159.     BOOL LoadAccelerators( UINT nID );
  160.     BOOL LoadAccelerators( LPCSTR lpszResource );
  161.  
  162. public:
  163.     // Attributes
  164.     CAbstractCX *GetContext() const { return GetMainContext(); }
  165.  
  166.     virtual LPCTSTR GetWindowMenuTitle() { return _T(""); };
  167.  
  168.     BOOL IsNews() const { return m_bNews; }
  169.     virtual MessageKey GetCurMessage() const { return MSG_MESSAGEKEYNONE; }
  170.     virtual MSG_FolderInfo *GetCurFolder() const { return NULL; }
  171.  
  172.     static BOOL CheckWizard( CWnd *pParent = NULL ); // See if prefs have been initialized
  173.  
  174.     static C3PaneMailFrame *GetLastThreadFrame(CFrameWnd *pExclude = NULL);
  175.     static CMessageFrame *GetLastMessageFrame(CFrameWnd *pExclude = NULL);
  176.  
  177.     static void UpdateMenu( MSG_FolderInfo *mailRoot,
  178.                             HMENU hMenu, UINT &nID, int nStart = 0);
  179.  
  180.     void ActivateFrame( int nCmdShow = -1 );
  181.     virtual void RefreshNewEncoding(int16 doc_csid, BOOL bSave = TRUE);
  182.  
  183. protected:
  184.     virtual void SetSort( int idSort ) {}
  185.     virtual void SetCSID( int csid );
  186.  
  187.     virtual MSG_FolderInfo *FolderInfoFromMenuID( MSG_FolderInfo *mailRoot,
  188.                                                   UINT &nBase, UINT nID );
  189.     virtual MSG_FolderInfo *FolderInfoFromMenuID( UINT nID );
  190.  
  191.     int m_iMessageMenuPos;
  192.     int m_iMoveMenuPos;
  193.     int m_iCopyMenuPos;
  194.  
  195.     int m_iFileMenuPos;
  196.     int m_iAttachMenuPos;
  197.  
  198.     virtual void UpdateFileMenus();
  199.     virtual void UpdateAttachmentMenus();
  200.  
  201.     void ModalStatusBegin( int iModalDelay );
  202.     void ModalStatusEnd();
  203.  
  204.     void DoUpdateCommand( CCmdUI* pCmdUI, MSG_CommandType cmd, BOOL bUseCheck = TRUE );
  205.     void DoCommand(MSG_CommandType msgCommand, int iModalDelay = -1, BOOL bAsync = TRUE );
  206.     void DoMessageCommand( MSG_CommandType );
  207.     void DoUpdateMessageCommand( CCmdUI *, MSG_CommandType, BOOL = TRUE );
  208.     virtual void DoUpdateNavigate( CCmdUI* pCmdUI, MSG_MotionType cmd ) {}
  209.     virtual void DoNavigate( MSG_MotionType msgCommand ) {}
  210.  
  211.     void DoSubscribe(MSG_Host* pThisHost);
  212.  
  213.     // MFC Overrides
  214.     virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  215.     virtual BOOL PreTranslateMessage( MSG* pMsg );
  216.     virtual void GetMessageString( UINT nID, CString& rMessage ) const;
  217.  
  218.     // Message Map
  219.     afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
  220.     afx_msg void OnPaint( );
  221.     afx_msg    HCURSOR OnQueryDragIcon();
  222.     afx_msg void OnClose( );
  223.     afx_msg void OnDestroy( );
  224.     afx_msg void OnInitMenuPopup( CMenu* pPopupMenu, UINT nIndex, BOOL bSysMenu );
  225.     afx_msg LRESULT CMailNewsFrame::OnButtonMenuOpen(WPARAM wParam, LPARAM lParam);
  226.   
  227. #ifndef ON_COMMAND_RANGE
  228.     afx_msg BOOL OnCmdMsg(UINT nID, int nCode, void* pExtra, AFX_CMDHANDLERINFO* pHandlerInfo);
  229. #endif
  230.  
  231.     // File Menu Items
  232.     afx_msg BOOL OnCommand( WPARAM wParam, LPARAM lParam );
  233.     afx_msg void OnNew ();
  234.     afx_msg void OnUpdateNew ( CCmdUI* pCmdUI );
  235.     afx_msg void OnNewNewsgroup();
  236.     afx_msg void OnUpdateNewNewsgroup( CCmdUI *pCmdUI );
  237.     afx_msg void OnNewNewshost();
  238.     afx_msg void OnUpdateNewNewshost( CCmdUI *pCmdUI );
  239.     afx_msg void OnNewCategory();
  240.     afx_msg void OnUpdateNewCategory( CCmdUI *pCmdUI );
  241.     afx_msg void OnSave ();
  242.     afx_msg void OnUpdateSave ( CCmdUI* pCmdUI );
  243.     afx_msg void OnEditMessage ();
  244.     afx_msg void OnUpdateEditMessage( CCmdUI* pCmdUI );
  245.     afx_msg void OnAddNewsGroup();
  246.     afx_msg void OnUpdateAddNewsGroup ( CCmdUI * pCmdUI );
  247.     afx_msg void OnSubscribe ();
  248.     afx_msg void OnUpdateSubscribe ( CCmdUI * pCmdUI );
  249.     afx_msg void OnUnsubscribe ();
  250.     afx_msg void OnUpdateUnsubscribe ( CCmdUI * pCmdUI );
  251.     afx_msg void OnOpenAttach( UINT nID );
  252.     afx_msg void OnUpdateOpenAttach( CCmdUI *pCmdUI );
  253.     afx_msg void OnSaveAttach( UINT nID );
  254.     afx_msg void OnUpdateSaveAttach( CCmdUI *pCmdUI );
  255.     afx_msg void OnAttachProperties( UINT nID );
  256.     afx_msg void OnUpdateAttachProperties( CCmdUI *pCmdUI );
  257.  
  258.     // Edit Menu Items
  259.     afx_msg void OnEditUndo();
  260.     afx_msg void OnUpdateEditUndo( CCmdUI* pCmdUI );
  261.     afx_msg void OnEditRedo();
  262.     afx_msg void OnUpdateEditRedo( CCmdUI* pCmdUI );
  263.     afx_msg void OnDeleteMessage();
  264.     afx_msg void OnReallyDeleteMessage();
  265.     afx_msg void OnUpdateDeleteMessage( CCmdUI *pCmdUI );
  266.     afx_msg void OnDeleteFolder();
  267.     afx_msg void OnUpdateDeleteFolder( CCmdUI *pCmdUI );
  268.     afx_msg void OnSelectAll();
  269.     afx_msg void OnUpdateSelectAll ( CCmdUI * pCmdUI );
  270.     afx_msg void OnSetupWizard ();
  271.     afx_msg void OnUpdateSetupWizard( CCmdUI *pCmdUI );
  272.     afx_msg void OnServerStuff();
  273.     afx_msg void OnUpdateServerStuff( CCmdUI *pCmdUI );
  274.  
  275.     // View/Sort Menu Items
  276.     afx_msg void OnSortAgain ();
  277.     afx_msg void OnUpdateSortAgain ( CCmdUI* pCmdUI );
  278.     afx_msg void OnThread ();
  279.     afx_msg void OnUpdateThread ( CCmdUI* pCmdUI );
  280.     afx_msg void OnAscending ();
  281.     afx_msg void OnUpdateAscending ( CCmdUI* pCmdUI );
  282.     afx_msg void OnDescending ();
  283.     afx_msg void OnUpdateDescending ( CCmdUI* pCmdUI );
  284.     afx_msg void OnSortNumber ();
  285.     afx_msg void OnUpdateSortNumber ( CCmdUI* pCmdUI );
  286.     afx_msg void OnSortDate ();
  287.     afx_msg void OnUpdateSortDate ( CCmdUI* pCmdUI );
  288.     afx_msg void OnSortSubject ();
  289.     afx_msg void OnUpdateSortSubject ( CCmdUI* pCmdUI );
  290.     afx_msg void OnSortSender ();
  291.     afx_msg void OnUpdateSortSender ( CCmdUI* pCmdUI );
  292.     afx_msg void OnSortPriority();
  293.     afx_msg void OnUpdateSortPriority( CCmdUI *pCmdUI );
  294.     afx_msg void OnSortStatus();
  295.     afx_msg void OnUpdateSortStatus( CCmdUI *pCmdUI );
  296.     afx_msg void OnSortSize();
  297.     afx_msg void OnUpdateSortSize( CCmdUI *pCmdUI );
  298.     afx_msg void OnSortFlag();
  299.     afx_msg void OnUpdateSortFlag( CCmdUI *pCmdUI );
  300.     afx_msg void OnSortUnread();
  301.     afx_msg void OnUpdateSortUnread( CCmdUI *pCmdUI );
  302.     afx_msg void OnViewAll();
  303.     afx_msg void OnUpdateViewAll( CCmdUI * pCmdUI );
  304.     afx_msg void OnViewKilled();
  305.     afx_msg void OnUpdateViewKilled( CCmdUI * pCmdUI );
  306.     afx_msg void OnViewWatched();
  307.     afx_msg void OnUpdateViewWatched( CCmdUI * pCmdUI );
  308.     afx_msg void OnViewNew();
  309.     afx_msg void OnUpdateViewNew( CCmdUI * pCmdUI );
  310.     afx_msg void OnViewNewOnly();
  311.     afx_msg void OnUpdateViewNewOnly( CCmdUI * pCmdUI );
  312.     afx_msg void OnHeadersMicro();
  313.     afx_msg void OnUpdateHeadersMicro( CCmdUI *pCmdUI );
  314.     afx_msg void OnHeadersShort();
  315.     afx_msg void OnUpdateHeadersShort( CCmdUI *pCmdUI );
  316.     afx_msg void OnHeadersAll();
  317.     afx_msg void OnUpdateHeadersAll( CCmdUI *pCmdUI );
  318.     afx_msg void OnMessageReuse();
  319.     afx_msg void OnUpdateMessageReuse(CCmdUI* pCmdUI);
  320.     afx_msg void OnViewInline();
  321.     afx_msg void OnUpdateViewInline(CCmdUI*);
  322.     afx_msg void OnViewAsLinks();
  323.     afx_msg void OnUpdateViewAsLinks(CCmdUI*);
  324.  
  325.     // Navigate Menu Items
  326.     afx_msg void OnPreviousUnread ();
  327.     afx_msg void OnUpdatePreviousUnread ( CCmdUI* pCmdUI );
  328.     afx_msg void OnPrevious ();
  329.     afx_msg void OnUpdatePrevious ( CCmdUI* pCmdUI );
  330.     afx_msg void OnNextUnread ();
  331.     afx_msg void OnUpdateNextUnread ( CCmdUI* pCmdUI );
  332.     afx_msg void OnNext();
  333.     afx_msg void OnUpdateNext ( CCmdUI* pCmdUI );
  334.     afx_msg void OnNextFolder();
  335.     afx_msg void OnUpdateNextFolder( CCmdUI* pCmdUI );
  336.     afx_msg void OnNextUnreadThread();
  337.     afx_msg void OnUpdateNextUnreadThread(CCmdUI* pCmdUI);
  338.     afx_msg void OnNextUnreadFolder();
  339.     afx_msg void OnUpdateNextUnreadFolder(CCmdUI* pCmdUI);
  340.     afx_msg void OnNextFlagged();
  341.     afx_msg void OnUpdateNextFlagged(CCmdUI* pCmdUI);
  342.     afx_msg void OnPreviousFlagged();
  343.     afx_msg void OnUpdatePreviousFlagged(CCmdUI* pCmdUI);
  344.     afx_msg void OnFirstFlagged();
  345.     afx_msg void OnUpdateFirstFlagged(CCmdUI* pCmdUI);
  346.     
  347.     /* hack for message backtracking */
  348.     afx_msg void OnGoBack();
  349.     afx_msg void OnUpdateGoBack( CCmdUI* pCmdUI );
  350.     afx_msg void OnGoForward();
  351.     afx_msg void OnUpdateGoForward( CCmdUI* pCmdUI );
  352.  
  353.     // Message Menu Items
  354.     afx_msg void OnGetMail ();
  355.     afx_msg void OnUpdateGetMail ( CCmdUI* pCmdUI );
  356.     afx_msg void OnGetNext();
  357.     afx_msg void OnUpdateGetNext( CCmdUI* pCmdUI );
  358.     afx_msg void OnDeliverNow();
  359.     afx_msg void OnUpdateDeliverNow(CCmdUI*);
  360.     afx_msg void OnReply ();
  361.     afx_msg void OnUpdateReply ( CCmdUI* pCmdUI );
  362.     afx_msg void OnReplyAll ();
  363.     afx_msg void OnUpdateReplyAll ( CCmdUI* pCmdUI );
  364.     afx_msg void OnPostNew ();
  365.     afx_msg void OnUpdatePostNew ( CCmdUI* pCmdUI );
  366.     afx_msg void OnPostAndMailReply ();
  367.     afx_msg void OnUpdatePostAndMailReply ( CCmdUI * pCmdUI );
  368.     afx_msg void OnPostAndMail ();
  369.     afx_msg void OnUpdatePostAndMail ( CCmdUI * pCmdUI );
  370.     afx_msg void OnPostReply ();
  371.     afx_msg void OnUpdatePostReply ( CCmdUI* pCmdUI );
  372.     afx_msg void OnForward ();
  373.     afx_msg void OnUpdateForward  ( CCmdUI* pCmdUI );
  374.     afx_msg void OnForwardQuoted ();
  375.     afx_msg void OnUpdateForwardQuoted ( CCmdUI * pCmdUI );
  376.     afx_msg void OnKill();
  377.     afx_msg void OnUpdateKill( CCmdUI *pCmdUI );
  378.     afx_msg void OnWatch();
  379.     afx_msg void OnUpdateWatch( CCmdUI *pCmdUI );
  380.     afx_msg void OnCancelMessage();
  381.     afx_msg void OnUpdateCancelMessage( CCmdUI * pCmdUI );
  382.     afx_msg void OnRetrieveSelected();
  383.     afx_msg void OnUpdateRetrieveSelected( CCmdUI *pCmdUI );
  384.     afx_msg void OnMarkMessagesRead();
  385.     afx_msg void OnUpdateMarkMessagesRead( CCmdUI *pCmdUI );
  386.     afx_msg void OnMarkMessagesUnread();
  387.     afx_msg void OnUpdateMarkMessagesUnread( CCmdUI *pCmdUI );
  388.     afx_msg void OnMarkMessagesLater();
  389.     afx_msg void OnUpdateMarkMessagesLater( CCmdUI *pCmdUI );
  390.     afx_msg void OnMarkThreadRead();
  391.     afx_msg void OnUpdateMarkThreadRead( CCmdUI *pCmdUI );
  392.     afx_msg void OnMarkAllRead();
  393.     afx_msg void OnUpdateMarkAllRead( CCmdUI *pCmdUI );
  394.     afx_msg void OnCatchup();
  395.     afx_msg void OnUpdateCatchup( CCmdUI *pCmdUI );
  396.     afx_msg void OnRetrieveOffline();
  397.     afx_msg void OnUpdateRetrieveOffline( CCmdUI *pCmdUI );
  398.     afx_msg void OnMarkMessages();
  399.     afx_msg void OnUpdateMarkMessages( CCmdUI *pCmdUI );
  400.     afx_msg void OnUnmarkMessages();
  401.     afx_msg void OnUpdateUnmarkMessages( CCmdUI *pCmdUI );
  402.     afx_msg void OnWrapLongLines ( );
  403.     afx_msg void OnUpdateWrapLongLines ( CCmdUI * pCmdUI );
  404.     afx_msg void OnViewRot13 ( );
  405.     afx_msg void OnUpdateViewRot13 ( CCmdUI * pCmdUI );
  406.  
  407.     // Organize Menu Items
  408.     afx_msg void OnNewFolder ();
  409.     afx_msg void OnUpdateNewFolder ( CCmdUI* pCmdUI );
  410.     afx_msg void OnRenameFolder();
  411.     afx_msg void OnUpdateRenameFolder( CCmdUI *pCmdUI );
  412.     afx_msg void OnCompressFolder ();
  413.     afx_msg void OnUpdateCompressFolder ( CCmdUI* pCmdUI );
  414.     afx_msg void OnCompressAll ();
  415.     afx_msg void OnUpdateCompressAll ( CCmdUI* pCmdUI );
  416.     afx_msg void OnEmptyTrash ();
  417.     afx_msg void OnUpdateEmptyTrash ( CCmdUI * pCmdUI );
  418.     afx_msg void OnAddToAddressBook ();
  419.     afx_msg void OnUpdateAddToAddressBook ( CCmdUI * pCmdUI );
  420.     afx_msg void OnAddAllToAddressBook ();
  421.     afx_msg void OnUpdateAddAllToAddressBook ( CCmdUI * pCmdUI );
  422.  
  423.     // Stop
  424.     afx_msg void OnInterrupt();
  425.     afx_msg void OnUpdateInterrupt( CCmdUI* pCmdUI );
  426.  
  427.     // Non menu Items
  428.     afx_msg void OnTips();
  429.     afx_msg void OnSearch();
  430.     afx_msg void OnFilter();
  431.     afx_msg void OnQuickFile();
  432.     afx_msg void OnUpdateQuickFile( CCmdUI *pCmdUI );
  433.     afx_msg void OnUpdateSecurity(CCmdUI *pCmdUI);
  434.     afx_msg void OnUpdateSecureStatus(CCmdUI *pCmdUI);
  435.  
  436.     afx_msg void OnPriorityLowest();
  437.     afx_msg void OnPriorityLow();
  438.     afx_msg void OnPriorityNormal();
  439.     afx_msg void OnPriorityHigh();
  440.     afx_msg void OnPriorityHighest();
  441.     afx_msg void OnUpdatePriority( CCmdUI *pCmdUI );
  442.  
  443.     DECLARE_MESSAGE_MAP()
  444. };
  445.  
  446. /////////////////////////////////////////////////////////////////////////////
  447. // CMsgListFrame frame
  448.  
  449. class CMsgListFrame : public CMailNewsFrame, public IMsgList {
  450.     DECLARE_DYNCREATE(CMsgListFrame)
  451. public:
  452. // IUnknown Interface
  453.     STDMETHODIMP            QueryInterface(REFIID,LPVOID *);
  454.     STDMETHODIMP_(ULONG)    AddRef(void);
  455.     STDMETHODIMP_(ULONG)    Release(void);
  456.  
  457. // Support for IMsgList Interface (Called by CMailMsgList)
  458.     virtual void ListChangeStarting( MSG_Pane* pane, XP_Bool asynchronous,
  459.                                      MSG_NOTIFY_CODE notify, MSG_ViewIndex where,
  460.                                      int32 num);
  461.     virtual void ListChangeFinished( MSG_Pane* pane, XP_Bool asynchronous,
  462.                                      MSG_NOTIFY_CODE notify, MSG_ViewIndex where,
  463.                                      int32 num);
  464.     virtual void GetSelection( MSG_Pane* pane, MSG_ViewIndex **indices, int *count, 
  465.                                int *focus);
  466.     virtual void SelectItem( MSG_Pane* pane, int item );
  467.  
  468.     virtual void CopyMessagesInto( MSG_Pane *pane, MSG_ViewIndex *indices, int count,
  469.                                    MSG_FolderInfo *folderInfo);
  470.     virtual void MoveMessagesInto( MSG_Pane *pane, MSG_ViewIndex *indices, int count,
  471.                                    MSG_FolderInfo *folderInfo);
  472. protected:
  473.     CMsgListFrame();           // protected constructor used by dynamic creation
  474.  
  475.     // Message Map
  476.     afx_msg int OnCreate( LPCREATESTRUCT lpCreateStruct );
  477.     afx_msg void OnDestroy();
  478.     DECLARE_MESSAGE_MAP()
  479. };
  480.  
  481. extern MSG_MessagePaneCallbacks MsgPaneCB;
  482.  
  483. /////////////////////////////////////////////////////////////////////////////
  484. #endif
  485.