
/***************************************************************************
**
**    $Header:   D:/ECB2S/SRC/LOG/TRCWIN.H__   1.2.1.4   17 Apr 1997 16:08:06   ZJRD  $
**
**    $Log:   D:/ECB2S/SRC/LOG/TRCWIN.H__  $
** 
**    Rev 1.2.1.4   17 Apr 1997 16:08:06   ZJRD
** No change.
** 
**    Rev 1.2.1.3   16 Apr 1997 10:43:02   ZJRD
** No change.
** 
**    Rev 1.2.1.2   10 Apr 1997 15:48:18   ZJRD
** No change.
** 
**    Rev 1.2.1.1   03 Apr 1997 15:27:26   ZJRD
** No change.
** 
**    Rev 1.2.1.0   28 Mar 1997 10:30:44   ZJRD
** easy pack sld 2.09d
** 
**    Rev 1.1   19 Mar 1997 11:40:00   ZJRD
** No change.
** 
**    Rev 1.0   12 Mar 1997 14:52:58   ZJRD
** Initial revision.
** 
**    Rev 1.7.1.0.1.2   09 Dec 1996 10:15:40   ZJRD
** EasyPack/SLD Version 2.0P
** 
**    Rev 1.7.1.0.1.0   11 Nov 1996 12:58:56   ZJRD
** EasyPack/SLD Version 2.01
** 
**    Rev 1.7.1.4   09 Sep 1996 13:17:00   ZJRD
** No change.
** 
**    Rev 1.7.1.3   05 Sep 1996 11:28:32   ZJRD
** No change.
** 
**    Rev 1.7.1.2   02 Sep 1996 09:55:38   ZJRD
** No change.
** 
**    Rev 1.7.1.1   28 Aug 1996 15:49:22   ZJRD
** EasyPack/SLD Version 1.9b
** 
**    Rev 1.7   11 Jun 1996 10:28:10   ZJRD
** EasyPack/SLD Version 1.97
** 
**    Rev 1.5   05 Jun 1996 14:56:48   ZJRD
** No change.
** 
**    Rev 1.4   29 May 1996 09:30:14   ZJRD
** No change.
** 
**    Rev 1.3   16 May 1996 09:07:32   ZJRD
** No change.
** 
**    Rev 1.2   10 May 1996 09:10:30   ZJRD
** No change.
** 
**    Rev 1.1   02 May 1996 10:27:06   ZJRD
** EasyPack/SLD Version 1.92
** 
**    Rev 1.31   18 Apr 1996 13:00:46   Shirley
** No change.
** 
**    Rev 1.30   12 Apr 1996 10:37:50   Shirley
** EasyPack/SLD Version 1.90
** 
**    Rev 1.28   15 Feb 1996 08:52:22   Shirley
** No change.
** 
**    Rev 1.27   12 Feb 1996 14:06:54   Shirley
** No change.
** 
**    Rev 1.26   06 Feb 1996 15:33:22   Shirley
** No change.
** 
**    Rev 1.25   06 Feb 1996 13:48:16   Shirley
** No change.
** 
**    Rev 1.24   01 Feb 1996 10:12:36   Shirley
** No change.
** 
**    Rev 1.23   26 Jan 1996 09:12:20   Shirley
** No change.
** 
**    Rev 1.22   25 Jan 1996 13:13:00   Shirley
** No change.
** 
**    Rev 1.21   24 Jan 1996 10:36:38   Shirley
** No change.
** 
**    Rev 1.20   23 Jan 1996 11:27:08   Shirley
** No change.
** 
**    Rev 1.19   18 Jan 1996 10:10:24   Shirley
** No change.
** 
**    Rev 1.18   15 Jan 1996 16:11:26   Shirley
** No change.
** 
**    Rev 1.17   04 Jan 1996 11:12:24   Shirley
** No change.
** 
**    Rev 1.16   30 Nov 1995 09:11:38   Shirley
** No change.
** 
**    Rev 1.15   28 Nov 1995 15:32:16   Shirley
** No change.
** 
**    Rev 1.14   21 Nov 1995 11:22:46   Shirley
** No change.
** 
**    Rev 1.13   13 Nov 1995 09:28:06   Shirley
** No change.
** 
**    Rev 1.12   12 Nov 1995 11:29:56   Shirley
** No change.
** 
**    Rev 1.11   08 Nov 1995 16:33:08   Shirley
** No change.
** 
**    Rev 1.10   08 Nov 1995 12:45:06   Shirley
** EasyPack/SLD Version 0.22
** 
**    Rev 1.7   27 Oct 1995 13:44:20   Shirley
** EasyPack/SLD Version 0.1g
** 
**    Rev 1.4   13 Oct 1995 13:24:00   Shirley
** No change.
** 
**    Rev 1.3   29 Sep 1995 09:53:34   Shirley
** No change.
** 
**    Rev 1.2   20 Sep 1995 10:58:14   Shirley
** No change.
** 
**    Rev 1.1   15 Sep 1995 09:46:08   Shirley
** EasyPack/SLDV0.1a 
** 
**    Rev 1.0   07 Sep 1995 09:54:02   Shirley
** Initial revision.
**
****************************************************************************/

/////////////////////////////////////////////////////////////////////////////
//
//  File name:  TRCWIN.H
//
//  Description:The header file for the class: CTraceWindow
//
//  Author:     Chris Fang
//
//  Date:       09/10/95
//
//  Modification:
//
//      1. 09/10/95, Initial version
//
//
//  Copyright (C) 1995 Microtek International. All rights reserved.
//
/////////////////////////////////////////////////////////////////////////////


#ifndef _TRCWIN_
#define _TRCWIN_


/////////////////////////////////////////////////////////////////////////////
// CTraceWindow frame

class CTraceWindow : public CMDIChildWnd
{
    DECLARE_DYNCREATE(CTraceWindow)
public:
    CTraceWindow();         
    BOOL Create(LPCSTR szTitle, LONG style = 0,
        const RECT& rect = rectDefault, CMDIFrameWnd * pParent = NULL );

// Implementation
protected:
   static CMenu NEAR m_menu;    
   
   virtual ~CTraceWindow();

private:
    CTraceView	m_viewTrace;
	int			m_nMousePointx;
	BOOL		m_bSizeCursor;
	BOOL		m_bLBtnPress;
	int			m_nChangeCol;
	int			m_nLeftMax;
	int			m_nRightMax;	

private:
	void DrawStatic(LPCSTR, UINT, RECT, CDC*);     
	int	 	CursorOnCol(int x, int y);
	long 	SearchBus(int);
    long 	SearchIns(int);
    long 	SearchSrc(int);
	
public:
	int			m_nCxVscroll;
    WORD		m_wTitleHeight;
   

protected:
    // Generated message map functions
    //{{AFX_MSG(CTraceWindow)                      
	afx_msg int  OnCreate(LPCREATESTRUCT lpCreateStruct);
    afx_msg void OnSize(UINT nType, int cx, int cy);
    afx_msg void OnPaint();
    afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
    afx_msg void OnEditSearch();
    afx_msg void OnEditSearchnext();
    afx_msg void OnViewBus();
    afx_msg void OnUpdateViewBus(CCmdUI* pCmdUI);
    afx_msg void OnViewInstruction();
    afx_msg void OnUpdateViewInstruction(CCmdUI* pCmdUI);
    afx_msg void OnEditGotoframe();
    afx_msg void OnEditGotostartframe();
    afx_msg void OnEditGotoendframe();
    afx_msg void OnTraceControl();
    afx_msg void OnTraceEvent();
    afx_msg void OnTraceFilter();
    afx_msg void OnTraceTrigger();
    afx_msg void OnFileSavetrace();
    afx_msg void OnUpdateFileSavetrace(CCmdUI* pCmdUI);
	afx_msg void OnViewSource();
	afx_msg void OnUpdateViewSource(CCmdUI* pCmdUI);
	afx_msg void OnViewRefresh();
	afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnShiftreturn();
	afx_msg void OnUpdateEditSearchnext(CCmdUI* pCmdUI);
	afx_msg void OnMDIActivate(BOOL bActivate, CWnd* pActivateWnd, CWnd* pDeactivateWnd);
	afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
	afx_msg void OnMouseMove(UINT nFlags, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnViewMixed();
	afx_msg void OnUpdateViewMixed(CCmdUI* pCmdUI);
	afx_msg void OnTraceClear();
	afx_msg void OnUpdateTraceClear(CCmdUI* pCmdUI);
	//}}AFX_MSG
	afx_msg long OnXMRepaint(UINT,LONG);
    DECLARE_MESSAGE_MAP()
};

#endif
////////////////////////////(EOF)///////////////////////////
