summaryrefslogtreecommitdiff
path: root/win32/makedrop/processpage.h
diff options
context:
space:
mode:
authorStef Walter <stef@thewalter.net>2003-09-20 07:12:49 +0000
committerStef Walter <stef@thewalter.net>2003-09-20 07:12:49 +0000
commitb49d8ebefe9b10c53a6a09ad564e22111b7b25c6 (patch)
tree1d5dd4abc38170a7bc106dabbc59b915017222f0 /win32/makedrop/processpage.h
parent1cda9ebbd62916c7c2136722597a86c583e1ecf6 (diff)
Initial Import
Diffstat (limited to 'win32/makedrop/processpage.h')
-rw-r--r--win32/makedrop/processpage.h75
1 files changed, 75 insertions, 0 deletions
diff --git a/win32/makedrop/processpage.h b/win32/makedrop/processpage.h
new file mode 100644
index 0000000..74ad6de
--- /dev/null
+++ b/win32/makedrop/processpage.h
@@ -0,0 +1,75 @@
+/*
+ * AUTHOR
+ * N. Nielsen
+ *
+ * LICENSE
+ * This software is in the public domain.
+ *
+ * The software is provided "as is", without warranty of any kind,
+ * express or implied, including but not limited to the warranties
+ * of merchantability, fitness for a particular purpose, and
+ * noninfringement. In no event shall the author(s) be liable for any
+ * claim, damages, or other liability, whether in an action of
+ * contract, tort, or otherwise, arising from, out of, or in connection
+ * with the software or the use or other dealings in the software.
+ *
+ * SUPPORT
+ * Send bug reports to: <nielsen@memberwebs.com>
+ */
+
+#ifndef __PROCESSPAGE_H__
+#define __PROCESSPAGE_H__
+
+#include "resource.h" // main symbols
+#include <atlhost.h>
+#include "common/droplet.h"
+
+
+// ProcessPage: -------------------------------------------------------
+// Property page for script and buffer size
+
+class ProcessPage :
+ public CPropertyPage
+{
+public:
+ ProcessPage(Droplet& droplet);
+
+ BEGIN_MSG_MAP(ProcessPage)
+ MESSAGE_HANDLER(WM_INITDIALOG, onInitDialog)
+ MESSAGE_HANDLER(PSM_QUERYSIBLINGS, onQuerySiblings)
+ COMMAND_ID_HANDLER(IDC_BROWSE, onBrowse)
+ COMMAND_CODE_HANDLER(BN_CLICKED, onChange)
+ COMMAND_CODE_HANDLER(EN_CHANGE, onChange)
+ NOTIFY_CODE_HANDLER(PSN_APPLY, onApply)
+ END_MSG_MAP()
+
+// Message Handlers
+protected:
+ LRESULT onInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+ LRESULT onQuerySiblings(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+ LRESULT onApply(int idCtrl, LPNMHDR pnmh, BOOL& bHandled);
+ LRESULT onChange(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled);
+ LRESULT onBrowse(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled);
+
+// Helper Functions
+protected:
+ // Updates all status etc...
+ void updateControls();
+
+ // Load data from droplet to page
+ void loadData();
+
+ // Load an already compiled rep script
+ HRESULT compileAlready(FILE* f);
+
+ // Load and possibly compile a rep script
+ HRESULT compileScript(const string& script);
+
+protected:
+ Droplet& m_droplet; // Pointer to sheet's main droplet
+ string m_script; // The script file name last time it was saved
+ // Will not reload if the same
+ bool m_inited; // Have we finished being initialized (used by onChange)
+};
+
+#endif //__PROCESSPAGE_H__