diff options
author | George Hazan <george.hazan@gmail.com> | 2014-01-11 16:23:36 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-01-11 16:23:36 +0000 |
commit | c559a18ca21a2a1fa3199c4bb60bcd031ec17134 (patch) | |
tree | 23a3716abd31956933bb8e01a90bff2c9eaf452b /include/m_utils.h | |
parent | 764b106951b4c47cef929d17ca99e8f4a8165483 (diff) |
MS_UTILS_ENTERSTRING moved from Jabber to the core, cause it's very handy
git-svn-id: http://svn.miranda-ng.org/main/trunk@7593 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'include/m_utils.h')
-rw-r--r-- | include/m_utils.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/include/m_utils.h b/include/m_utils.h index a400842fa3..7b25987b6a 100644 --- a/include/m_utils.h +++ b/include/m_utils.h @@ -461,4 +461,36 @@ __forceinline TCHAR* Utils_ReplaceVarsT(const TCHAR *szData) { #define MS_UTILS_GETBITMAPFILTERSTRINGST MS_UTILS_GETBITMAPFILTERSTRINGS
#endif
+/////////////////////////////////////////////////////////////////////////////////////////
+// one field form
+
+#define ESF_MULTILINE 1
+#define ESF_COMBO 2
+#define ESF_RICHEDIT 3
+#define ESF_PASSWORD 4
+
+typedef struct
+{
+ int cbSize; // structure size
+ int type; // one of ESF_* constants
+ LPCSTR szModuleName; // module name to save window size and combobox strings
+ LPCSTR szDataPrefix; // prefix for stored database variables
+ LPCTSTR caption; // window caption
+ LPTSTR *result; // initial value + result entered
+ int recentCount; // number of combobox strings to store
+ int timeout; // timeout for the form auto-close
+}
+ENTER_STRING;
+
+// enters one string
+// wParam = 0 (unused)
+// lParam = ENTER_STRING* (form description)
+// returns TRUE on pressing OK if Cancel was pressed
+#define MS_UTILS_ENTERSTRING "Utils/EnterString"
+
+__forceinline BOOL EnterString(ENTER_STRING *pForm)
+{
+ return (BOOL)CallService(MS_UTILS_ENTERSTRING, 0, (LPARAM)pForm);
+}
+
#endif // M_UTILS_H__
|