PopupBrowserDlgView.h
1.93 KB
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
68
69
70
71
72
73
74
75
76
77
78
79
//
#pragma once
#include <afxwin.h>
#include "Resource.h"
#include "include/internal/cef_ptr.h"
#include "etradeclient/browser/embedded_browser.h"
// Forward declaration.
class PopupBrowserHandler;
class CPopupBrowserView : public CDialog
{
public:
explicit CPopupBrowserView(const RECT& main_wnd_rect, CWnd* pParent = NULL);
virtual ~CPopupBrowserView();
public:
afx_msg virtual void OnClose();
protected:
virtual BOOL OnInitDialog();
private:
virtual std::string URL() const = 0;
enum { IDD = IDD_POPUP_BROWSER_VIEW };
int OnCreate(LPCREATESTRUCT create_struct);
void OnSize(UINT type, int cx, int cy);
afx_msg LRESULT OnAttachCEFBrowser(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnDetachCEFBrowser(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnSessionExpired(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnTitleChange(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnLoadEnd(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnCefJsCammandCloseWnd(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnCefJsCammandUserRelogin(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnCefJsCammandAppExit(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnCefJsCammandAppRelaunch(WPARAM wParam, LPARAM lParam);
DECLARE_MESSAGE_MAP()
protected:
RECT m_rect;
private:
CefRefPtr<PopupBrowserHandler> m_browser_handler;
EmbeddedBrower m_browser;
};
class CUserMsgView : public CPopupBrowserView
{
public:
explicit CUserMsgView(const RECT& main_wnd_rect, CWnd* pParent = NULL);
private:
std::string URL() const;
};
class CModifyPwdView : public CPopupBrowserView
{
public:
explicit CModifyPwdView(const RECT& main_wnd_rect, CWnd* pParent = NULL);
private:
std::string URL() const;
public:
virtual BOOL OnInitDialog();
};
class CCreateMerchantView : public CPopupBrowserView
{
public:
explicit CCreateMerchantView(const RECT& main_wnd_rect, CWnd* pParent = NULL);
private:
std::string URL() const;
public:
virtual BOOL OnInitDialog();
};