⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 navigatorview.h

📁 基于超图sne开发的一个详细的例子。提供查询
💻 H
字号:
// NavigatorView.h : interface of the CNavigatorView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_NavigatorVIEW_H__0CF628EB_B7A0_4710_981B_928D3F25E191__INCLUDED_)
#define AFX_NavigatorVIEW_H__0CF628EB_B7A0_4710_981B_928D3F25E191__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "NavigatorDoc.h"
#include "SNPOIQuery.h"
#include "SNPathPlanning.h"
#include "SNGuide.h"

class CNavigatorView : public CView
{
protected: // create from serialization only
	CNavigatorView();
	DECLARE_DYNCREATE(CNavigatorView)

public:
	virtual ~CNavigatorView();

// Attributes

public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CNavigatorView)
	public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	virtual void OnInitialUpdate();
	protected:
	//}}AFX_VIRTUAL

// Implementation
public:
	//! \brief 关闭地图。
	void OnCloseMap();

	//! \brief 关闭工作空间。
	void OnCloseWs();
	
	//! \brief 打开地图。
	UGbool OnOpenMap(UGString strMapName = "");
	
	//! \brief 打开工作空间。
	UGbool OnOpenWS(UGString strWorkspaceName);
	
	//! \brief 获取工作空间中索引的数据源。
	UGDataSource* GetDataSource(UGint iIndex);
	
	CNavigatorDoc*	GetDocument();

#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif
	
public:
	// 起始点在跟踪层上的ID
	UGint  m_nStartID;
	// 终点在跟踪层上的ID
	UGint  m_nEndID;
	
	//! \brief 判断是否绘制查询点。
	UGbool				m_bPOIQuery;
	
	//! \brief 判断是否有路径分析。
	UGbool				m_bPathPlanning;
	
	//! \brief 判断是否引导初始化。
	UGbool				m_bInitGuide;
	
	//! \brief 判断是否正在引导过程中。
	UGbool				m_bGuiding;

	//! \brief 导航点。
	UGPoint2D m_pntGuide;
	
    //! \brief 道路信息字符串。
	UGString			m_strRouteInfo;

	//! \brief 地图窗口指针。
	UGMapWnd*		    m_pMapWnd;
	
	//! \brief 工作空间对象。
	UGWorkspace		    m_Workspace;
	
    //! \brief POI点查询对象。
	SNPOIQuery		    m_POIQuery;

	//! \brief 路径分析对象。
	SNPathPlanning		m_pathPlanning;
	
	//! \brief 引导对象。
	SNGuide				m_Guide;
	

// Generated message map functions
protected:
	//{{AFX_MSG(CNavigatorView)
	afx_msg void OnFileOpen();
	afx_msg void OnFileClose();
	afx_msg void OnMapZoomin();
	afx_msg void OnMapZoomout();
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnMapPan();
	afx_msg void OnMapViewentire();
	afx_msg void OnPOIQuery();
	afx_msg void OnSetDeparture();
	afx_msg void OnSetDestination();
	afx_msg void OnPathplanningDo();
	afx_msg void OnPathplanningClean();
	afx_msg void OnSimulateNavi();
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnCancleNavi();
	afx_msg void OnUpdateFileOpen(CCmdUI* pCmdUI);
	afx_msg void OnUpdateFileClose(CCmdUI* pCmdUI);
	afx_msg void OnUpdatePoiQuery(CCmdUI* pCmdUI);
	afx_msg void OnUpdateQueryDeparture(CCmdUI* pCmdUI);
	afx_msg void OnUpdateQueryDestination(CCmdUI* pCmdUI);
	afx_msg void OnUpdateRaDo(CCmdUI* pCmdUI);
	afx_msg void OnUpdateRaClean(CCmdUI* pCmdUI);
	afx_msg void OnUpdateNaviSimulate(CCmdUI* pCmdUI);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in NavigatorView.cpp
inline CNavigatorDoc* CNavigatorView::GetDocument()
   { return (CNavigatorDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_NavigatorVIEW_H__0CF628EB_B7A0_4710_981B_928D3F25E191__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -