📄 mainfrm.h
字号:
// MainFrm.h : interface of the CMainFrame class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_MAINFRM_H__A70BFFAA_2939_11D3_873E_000000000000__INCLUDED_)
#define AFX_MAINFRM_H__A70BFFAA_2939_11D3_873E_000000000000__INCLUDED_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
#ifndef __AFXWIN_H__
#error include 'stdafx.h' before including this file for PCH
#endif
#include "C02IDEVIEW.h"
#include "OutputBar.h"
#include "MemoryBar.h"
//#include "SynEditView.h"
#include "FileTreeView.h"
#include "FileTreeDoc.h"
#include "FormatBar.h"
#include "TabFileView.h"
#include "MDITabs.h"
#include "WatchBar.h"
#include"simulator.h"
#include"DisassemblyBar.h"
//#include "LmSimulate.h"
//#include "C02IDEDoc.h"
#include "RegBar.h"
#define CFrameWnd CCJMDIFrameWnd
#define CToolBar CCJToolBar
#define CToolBarCtrl CCJToolBarCtrl
// class forwards.
class CTabClassDoc;
class CTabResourceDoc;
class CTabFileDoc;
class CFileTreeDoc;
class CMainFrame : public CFrameWnd
{
DECLARE_DYNCREATE(CMainFrame)
// Attributes
public:
simulator sim;
CStringArray typearray;
CTabFileView* m_pFileTree;
bool m_bFullScreenMode;
CMainFrame();
CFileTreeDoc* m_pDocFileTree;
CTabResourceDoc* m_pDocResource;
BOOL m_bFlat;
CMultiDocTemplate* m_pDocTemplate;
DWORD dwCtrlStyle;
// DWORD dwStyle;
CRect rcBorders;
CWnd* pParentWnd;
// The ID of the control bar.
UINT nID;
// Points to a null-terminated character string that contains the
// control bar title.
LPCTSTR lpszWindowName;
// The default size the control bar is to be.
CSize sizeDefaul;
// Specifies the window style attributes.
DWORD dwStyle;
// TRUE for flat style control bars.
BOOL bFlatBorders;
//当前正在处理的行索引
int currentline;
//得到的函数名称
CString str_funcnametest;
//得到的关键字名称
CString currentkey;
//当前处理行字符串
CString currentstring;
//当前处理的项目指针
struct ProjectList * curpro;
//当前处理的子窗口的指针
CMDIChildWnd * m_ptestwnd;
//当前处理的文件信息的指针
struct FileList * m_ptifile;
//函数是否已经声明过
BOOL b_havesheng;
BOOL b_Gotofunctiondeclaration;
BOOL b_Gotofunctiondefinition;
// Operations
public:
void UpDateFuncInfo(CString str_name,int lineno,BOOL isshengming);
BOOL IsC02Key(CString str_test);
int IsOneTab(CString str_test,int n_tab,int n_lkh);
int IsShengming(CString str_key,CString str_test);
void InsertToTree();
BOOL HaveShengming(CString str_test);
void ExpandAllFile();
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CMainFrame)
public:
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
virtual BOOL OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext);
//}}AFX_VIRTUAL
// Implementation
public:
virtual ~CMainFrame();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
void updatecomfile();
void delcomfile();
public: // control bar embedded members
// CCJControlBar m_wndDateBar;
// CTreeViewFile m_pTreeViewFile;
CDisassemblyBar m_dissemblybar;
CRegBar m_regbar;
CWatchBar m_wndWatchBar;
CMDITabs m_wndMDITabs;
CTabFileView* m_pTabFileView;
CCJToolBar m_wndDlgBar;
CCJToolBar m_wndToolBarBuild;
CCJToolBar m_wndToolBarFastget;
CCJToolBar m_wndWizardBar;
CCJReBar m_wndReBar;
//变量观察窗口
// CWatchBar m_wndWatchBar;
CStatusBar m_wndStatusBar;
CToolBar m_wndToolBar;
CCJTabCtrlBar m_wndWorkspace;
COutputBar m_wndOutput;
CMemoryBar m_wndMemory;
CImageList m_TabImages;
CCJMenuBar m_wndMenuBar;
CComboBox* m_pComboBox;
CComboBox* m_pComboBoxpro;
CComboBox* m_pComboBoxfile;
CComboBox* m_pComboBoxfunc;
CComboBox m_wndCombofunc;
CComboBox m_wndCombofile;
// CComboBox m_wndComboMembers;
CComboBox m_wndComboproject;
HBITMAP m_hBmp;
CImageList m_imageList;
//状态条
// CStatusBar m_wndStatusBar;
//编译工具条
CCJToolBar m_wndDebugBar;
BOOL b_buildgo;
BOOL b_buildstopgo;
void OnViewFullScreen();
void OnUpdateViewFullScreen(CCmdUI* pCmdUI);
void FullScreenModeOn();
void FullScreenModeOff();
BOOL InitializeComboBoxEx();
BOOL InitializeDateTimeCtrls();
// Generated message map functions
protected:
// BOOL InitializeDateTimeCtrls();
CFormatBar m_wndFormatBar;
// CMDITabs m_wndMDITabs;
CRect GetDialogBarItemRect(UINT nID) const;
CString m_strReplace;
CString m_strFind;
FINDREPLACE m_fr;
CFindReplaceDialog *m_fd;
void DoSearchReplaceDlg(bool bSearch);
LONG OnFindReplace(UINT wParam, LONG lParam);
//{{AFX_MSG(CMainFrame)
afx_msg void OnFileMruFile1();
afx_msg void InsertPre();
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnClose();
afx_msg void OnToggleflat();
afx_msg void OnUpdateToggleflat(CCmdUI* pCmdUI);
afx_msg void OnInitTabClass();
afx_msg void OnInitTabFile();
afx_msg void OnInitTabRsrc();
afx_msg void OnFileSave();
afx_msg void OnFileSaveAs();
afx_msg void OnButton();
afx_msg void OnUpdateBuildBuild(CCmdUI* pCmdUI);
afx_msg void OnWizbarActions();
afx_msg void OnUpdateWizbarActions(CCmdUI* pCmdUI);
afx_msg void OnWizbarClass();
afx_msg void OnUpdateWizbarClass(CCmdUI* pCmdUI);
afx_msg void OnAppAbout();
afx_msg void OnAbout();
afx_msg void OnSelendOkCombo();
afx_msg BOOL CreateStatusBar();
afx_msg void OnAct();
virtual void OnUpdateFrameTitle(BOOL bAddToTitle);
afx_msg void OnUpdateComboboxfunction(CCmdUI* pCmdUI);
afx_msg void OnSelendOkComboFile() ;
afx_msg void OnSearchThisfile();
afx_msg void OnReplaceCurfile();
afx_msg void OnReplaceProject();
afx_msg void OnWizbarActionsAdd();
afx_msg void OnWizbarActionsDel();
afx_msg void OnWizbarGotofunctiondeclaration();
afx_msg void OnWizbarGotofunctiondefinition();
afx_msg void OnBuildGo();
afx_msg void OnBuildStopGo();
afx_msg void OnUpdateBuildGo(CCmdUI* pCmdUI);
afx_msg void OnUpdateBuildStop(CCmdUI* pCmdUI);
afx_msg void OnUpdateWizbarGotofunctiondeclaration(CCmdUI* pCmdUI);
afx_msg void OnUpdateWizbarGotofunctiondefinition(CCmdUI* pCmdUI);
afx_msg void OnComboboxfunction();
afx_msg void OnSimu();
afx_msg void OnMenuNextbreak();
afx_msg void OnUpdateMenuStepone(CCmdUI* pCmdUI);
afx_msg void OnUpdateMenuNextbreak(CCmdUI* pCmdUI);
afx_msg void OnMenuStepone();
afx_msg void OnMenuStepinto();
afx_msg void OnUpdateMenuStepinto(CCmdUI* pCmdUI);
afx_msg void OnMenuStepout();
afx_msg void OnUpdateMenuStepout(CCmdUI* pCmdUI);
afx_msg void OnMenuStepover();
afx_msg void OnUpdateMenuStepover(CCmdUI* pCmdUI);
afx_msg void OnMenuCursor();
afx_msg void OnUpdateMenuCursor(CCmdUI* pCmdUI);
afx_msg void OnMenuRedibug();
afx_msg void OnUpdateMenuRedibug(CCmdUI* pCmdUI);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
private:
BOOL m_bAutoReturn;
bool m_bStatusBarWasVisible,m_bToolBarWasVisible,m_bFormatBarWasVisible;
CRect m_mainRect;
CToolBar* m_pwndFullScreenBar;
bool m_bChildMax;
};
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Developer Studio will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_MAINFRM_H__A70BFFAA_2939_11D3_873E_000000000000__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -