xj qian
2024-07-17 b1d01ea6fa62ce12c2e592b3315186f6b3c8359d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#include <wobject/xstring.hpp>
#include <xcontrol/xtreeview.hpp>
#include <xcontrol/xdwgrid.hpp>
#include <wobject/xdouble.hpp>
#include <xcontrol/xlayersheet.hpp>
#include <xcontrol/xdatetimepick.hpp>
 
 
#include "vbusiness/vframe/listwin.vframe.vbusiness.hpp"
#include "viewobject/view.base.hpp"
 
using xml = KXMLDOMDocument;
    class  __declspec(dllexport) TestRetrieveingWin:  public xframe
    {
    public:
        //xdwgrid    dw_list;
 
        xnode    m_agentNode;    //Agent Condition
    public:
        TestRetrieveingWin(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {}
    public:
        static TestRetrieveingWin* CreateInstance(void* implPtr, void* hWnd)
        {
            TestRetrieveingWin* pWin = new TestRetrieveingWin(implPtr, (HWND)hWnd);
            return pWin;
        }
        //½¹µã¼¤»î´¦Àíº¯Êý
        int OnSetFocus(TEvent* evt, LPARAM param)
        {
            //ÖØÖù¤¾ßÌõ
            return 1;
        }
 
        //ÃüÁî·¢²¼º¯Êý
        int OnCmdDispatch(xstring comdid)
        {
            if(comdid==L"RetrieveFinished")
            {
                CloseWindow();
                return 1;
            }
            return 0;
        }
        
        //ÃüÁî´¦Àíʼþ
        int OnXCommand(TEvent* evt, LPARAM param)
        {
            return OnCmdDispatch(evt->xcommand.pStrID);
        }
        
        int OnAttachEvent()
        {
            //°ó¶¨¹¤¾ßÌõµã»÷ʼþ
            AttachEvent(L"WM_XCOMMAND", (FEvent)&TestRetrieveingWin::OnXCommand);
            //»ñÈ¡½¹µãʼþ£¬ÓÃÓÚÖØÖù¤¾ßÌõ
            AttachEvent(L"WM_SETFOCUS", (FEvent)&TestRetrieveingWin::OnSetFocus);
            return 1;
        }
        
        int onload()
        {
            OnAttachEvent();    
            
            return 1;
        }
        
    };