00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #pragma once
00023
00024 #include "WndBaseMatch.h"
00025 #include "CtrlSearchPanel.h"
00026 #include "CtrlSearchDetailPanel.h"
00027
00028 class CManagedSearch;
00029
00030
00031 class CSearchWnd : public CBaseMatchWnd
00032 {
00033 public:
00034 CSearchWnd(CQuerySearch* pSearch = NULL);
00035 virtual ~CSearchWnd();
00036
00037 DECLARE_DYNCREATE(CSearchWnd)
00038 friend class CRemote;
00039
00040
00041 protected:
00042 CSearchPanel m_wndPanel;
00043 BOOL m_bPanel;
00044 BOOL m_bSetFocus;
00045 CSearchDetailPanel m_wndDetails;
00046 BOOL m_bDetails;
00047 int m_nDetails;
00048 int m_nLastSearchHelp;
00049 public:
00050 CPtrList m_pSearches;
00051 DWORD m_tSearch;
00052 DWORD m_nCacheHits;
00053 DWORD m_nCacheHubs;
00054 DWORD m_nCacheLeaves;
00055 CString m_sCaption;
00056 BOOL m_bWaitMore;
00057 DWORD m_nMaxResults;
00058 DWORD m_nMaxED2KResults;
00059 DWORD m_nMaxQueryCount;
00060
00061
00062 public:
00063 void Serialize(CArchive& ar);
00064 CManagedSearch* GetLastManager();
00065 CQuerySearch* GetLastSearch();
00066 void ExecuteSearch();
00067 protected:
00068 BOOL DoSizeDetails();
00069 public:
00070 virtual void OnSkinChange();
00071 virtual BOOL OnQueryHits(CQueryHit* pHits);
00072 virtual void UpdateMessages(BOOL bActive = TRUE);
00073 virtual void UpdateMessages(BOOL bActive, CManagedSearch* pManaged);
00074
00075
00076 protected:
00077 DECLARE_MESSAGE_MAP()
00078 afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
00079 afx_msg void OnDestroy();
00080 afx_msg void OnContextMenu(CWnd* pWnd, CPoint point);
00081 afx_msg void OnTimer(UINT nIDEvent);
00082 afx_msg void OnSize(UINT nType, int cx, int cy);
00083 afx_msg void OnPaint();
00084 afx_msg void OnSelChangeMatches();
00085 afx_msg void OnUpdateSearchSearch(CCmdUI* pCmdUI);
00086 afx_msg void OnSearchSearch();
00087 afx_msg void OnSearchClear();
00088 afx_msg void OnUpdateSearchStop(CCmdUI* pCmdUI);
00089 afx_msg void OnSearchStop();
00090 afx_msg void OnUpdateSearchPanel(CCmdUI* pCmdUI);
00091 afx_msg void OnSearchPanel();
00092 afx_msg void OnUpdateSearchClear(CCmdUI* pCmdUI);
00093 afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
00094 afx_msg void OnUpdateSearchDetails(CCmdUI* pCmdUI);
00095 afx_msg void OnSearchDetails();
00096 afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
00097 afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
00098 afx_msg void OnMDIActivate(BOOL bActivate, CWnd* pActivateWnd, CWnd* pDeactivateWnd);
00099 };