[PATCH v2 2/3] include: Add initial IDL for cmnquery.h

Zebediah Figura zfigura at codeweavers.com
Mon Jul 31 14:24:56 CDT 2017


v2: fix a typo in MSDN
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
---
 include/Makefile.in  |  1 +
 include/cmnquery.idl | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 85 insertions(+)
 create mode 100644 include/cmnquery.idl

diff --git a/include/Makefile.in b/include/Makefile.in
index 1dd6aafa324..c04a0fac04e 100644
--- a/include/Makefile.in
+++ b/include/Makefile.in
@@ -24,6 +24,7 @@ IDL_SRCS = \
 	chprst.idl \
 	cmdbas.idl \
 	cmdtxt.idl \
+	cmnquery.idl \
 	colinf.idl \
 	comcat.idl \
 	commoncontrols.idl \
diff --git a/include/cmnquery.idl b/include/cmnquery.idl
new file mode 100644
index 00000000000..c5311e5bd43
--- /dev/null
+++ b/include/cmnquery.idl
@@ -0,0 +1,84 @@
+/*
+ * Copyright 2017 Zebediah Figura for Codeweavers
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+import "unknwn.idl";
+import "objidl.idl";
+import "oaidl.idl";
+
+interface ICommonQuery;
+interface IPersistQuery;
+
+[
+    object,
+    uuid(1a3114b8-a62e-11d0-a6c5-00a0c906af45),
+    local
+]
+interface IPersistQuery : IPersist
+{
+    HRESULT Clear();
+
+    HRESULT ReadInt([in] LPCWSTR section, [in] LPCWSTR name, [out] INT *value);
+
+    HRESULT ReadString([in] LPCWSTR section, [in] LPCWSTR name, [out, size_is(buflen)] LPWSTR buffer, [in] INT buflen);
+
+    HRESULT ReadStruct([in] LPCWSTR section, [in] LPCWSTR name, [out, size_is(buflen)] LPVOID buffer, [in] DWORD buflen);
+
+    HRESULT WriteInt([in] LPCWSTR section, [in] LPCWSTR name, [in] INT value);
+
+    HRESULT WriteString([in] LPCWSTR section, [in] LPCWSTR name, [in] LPCWSTR value);
+
+    HRESULT WriteStruct([in] LPCWSTR section, [in] LPCWSTR name, [in] LPVOID value, [in] DWORD size);
+};
+
+cpp_quote("#define OQWF_OKCANCEL            0x00000001")
+cpp_quote("#define OQWF_DEFAULTFORM         0x00000002")
+cpp_quote("#define OQWF_SINGLESELECT        0x00000004")
+cpp_quote("#define OQWF_LOADQUERY           0x00000008")
+cpp_quote("#define OQWF_REMOVESCOPES        0x00000010")
+cpp_quote("#define OQWF_REMOVEFORMS         0x00000020")
+cpp_quote("#define OQWF_ISSUEONOPEN         0x00000040")
+cpp_quote("#define OQWF_SHOWOPTIONAL        0x00000080")
+cpp_quote("#define OQWF_SAVEQUERYONOK       0x00000200")
+cpp_quote("#define OQWF_HIDEMENUS           0x00000400")
+cpp_quote("#define OQWF_HIDESEARCHUI        0x00000800")
+cpp_quote("#define OQWF_PARAMISPROPERTYBAG  0x80000000")
+
+[
+    object,
+    uuid(ab50dec0-6f1d-11d0-a1c4-00aa00c16e65),
+    local
+]
+interface ICommonQuery : IUnknown
+{
+typedef struct {
+    DWORD         cbStruct;
+    DWORD         dwFlags;
+    CLSID         clsidHandler;
+    LPVOID        pHandlerParameters;
+    CLSID         clsidDefaultForm;
+    IPersistQuery *pPersistQuery;
+    union {
+        void         *pFormParameters;
+        IPropertyBag *ppbFormParameters;
+    };
+} OPENQUERYWINDOW, *LPOPENQUERYWINDOW;
+
+    HRESULT OpenQueryWindow([in] HWND parent, [in] LPOPENQUERYWINDOW query_window, [out] IDataObject **data_object);
+};
+
+cpp_quote("DEFINE_GUID(CLSID_CommonQuery, 0x83BC5EC0, 0x6F2A, 0x11D0, 0xA1,0xC4, 0x00,0xAA,0x00,0xC1,0x6E,0x65);")
-- 
2.13.3




More information about the wine-patches mailing list