summaryrefslogtreecommitdiffabout
path: root/ConfirmWRQDlg.cpp
authorMichael Krelin <hacker@klever.net>2004-07-05 01:53:09 (UTC)
committer Michael Krelin <hacker@klever.net>2004-07-05 01:53:09 (UTC)
commit9938ea772d372ba955b7bc1f1c48a062c3a36f8a (patch) (side-by-side diff)
treea98185df944e3a763f9557aa74bc2837b343f048 /ConfirmWRQDlg.cpp
downloadpumpkin-9938ea772d372ba955b7bc1f1c48a062c3a36f8a.zip
pumpkin-9938ea772d372ba955b7bc1f1c48a062c3a36f8a.tar.gz
pumpkin-9938ea772d372ba955b7bc1f1c48a062c3a36f8a.tar.bz2
initial commit into svn repository
git-svn-id: http://svn.klever.net/kin/pumpkin/trunk@1 fe716a7a-6dde-0310-88d9-d003556173a8
Diffstat (limited to 'ConfirmWRQDlg.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--ConfirmWRQDlg.cpp89
1 files changed, 89 insertions, 0 deletions
diff --git a/ConfirmWRQDlg.cpp b/ConfirmWRQDlg.cpp
new file mode 100644
index 0000000..c0380e3
--- a/dev/null
+++ b/ConfirmWRQDlg.cpp
@@ -0,0 +1,89 @@
+// ConfirmWRQDlg.cpp : implementation file
+//
+
+#include "stdafx.h"
+#include "PumpKIN.h"
+#include "ConfirmWRQDlg.h"
+
+#include "PumpKINDlg.h"
+
+#ifdef _DEBUG
+#define new DEBUG_NEW
+#undef THIS_FILE
+static char THIS_FILE[] = __FILE__;
+#endif
+
+/////////////////////////////////////////////////////////////////////////////
+// CConfirmWRQDlg dialog
+
+
+CConfirmWRQDlg::CConfirmWRQDlg(CWnd* pParent /*=NULL*/)
+ : CDialog(CConfirmWRQDlg::IDD, pParent)
+{
+ //{{AFX_DATA_INIT(CConfirmWRQDlg)
+ m_File = _T("");
+ m_Host = _T("");
+ //}}AFX_DATA_INIT
+}
+
+
+void CConfirmWRQDlg::DoDataExchange(CDataExchange* pDX)
+{
+ CDialog::DoDataExchange(pDX);
+ //{{AFX_DATA_MAP(CConfirmWRQDlg)
+ DDX_Control(pDX, IDC_RESUME, m_ResumeCtl);
+ DDX_Control(pDX, IDOK, m_OkCtl);
+ DDX_Control(pDX, IDC_RENAME, m_RenameCtl);
+ DDX_Text(pDX, IDC_FILE, m_File);
+ DDX_Text(pDX, IDC_HOST, m_Host);
+ //}}AFX_DATA_MAP
+}
+
+
+BEGIN_MESSAGE_MAP(CConfirmWRQDlg, CDialog)
+ //{{AFX_MSG_MAP(CConfirmWRQDlg)
+ ON_BN_CLICKED(IDC_RENAME, OnRename)
+ ON_WM_TIMER()
+ ON_BN_CLICKED(IDC_RESUME, OnResume)
+ //}}AFX_MSG_MAP
+END_MESSAGE_MAP()
+
+/////////////////////////////////////////////////////////////////////////////
+// CConfirmWRQDlg message handlers
+
+void CConfirmWRQDlg::OnRename()
+{
+ EndDialog(IDC_RENAME);
+}
+
+BOOL CConfirmWRQDlg::OnInitDialog()
+{
+ CDialog::OnInitDialog();
+
+ m_Daddy->m_Daddy->m_bnw.StartSound(m_Daddy->m_Daddy->m_bnwRequest);
+ if(m_Daddy->m_Daddy->m_PromptTimeOut)
+ SetTimer(1,m_Daddy->m_Daddy->m_PromptTimeOut*1000,NULL);
+ SetWindowPos(&CWnd::wndTopMost,0,0,0,0,SWP_NOACTIVATE|SWP_NOMOVE|SWP_NOSIZE);
+ m_ResumeCtl.EnableWindow(m_Daddy->m_bResume);
+ if(m_Daddy->m_Rename){
+ m_OkCtl.SetButtonStyle(m_OkCtl.GetButtonStyle()&~BS_DEFPUSHBUTTON);
+ m_RenameCtl.SetButtonStyle(m_RenameCtl.GetButtonStyle()|BS_DEFPUSHBUTTON);
+ m_RenameCtl.SetFocus();
+ return FALSE;
+ }
+
+ return TRUE; // return TRUE unless you set the focus to a control
+ // EXCEPTION: OCX Property Pages should return FALSE
+}
+
+void CConfirmWRQDlg::OnTimer(UINT nIDEvent)
+{
+ if(nIDEvent==1)
+ EndDialog(IDCANCEL);
+ CDialog::OnTimer(nIDEvent);
+}
+
+void CConfirmWRQDlg::OnResume()
+{
+ EndDialog(IDC_RESUME);
+}