dxdiag: implement DxDiagCOM_GetContainer (1/2)

Austin English austinenglish at gmail.com
Thu Aug 27 14:29:23 CDT 2009


Based on the UCLA students work.

P.S. If anyone's bored and wants to help cherry pick this stuff in,
let me know...

-- 
-Austin
-------------- next part --------------
diff --git a/programs/dxdiag/Makefile.in b/programs/dxdiag/Makefile.in
index a8dd0d9..79383c8 100644
--- a/programs/dxdiag/Makefile.in
+++ b/programs/dxdiag/Makefile.in
@@ -8,6 +8,7 @@ APPMODE   = -mwindows -municode
 IMPORTS   = kernel32
 
 C_SRCS = \
+	dxdiag_com.c \
 	main.c
 
 @MAKE_PROG_RULES@
diff --git a/programs/dxdiag/dxdiag_com.c b/programs/dxdiag/dxdiag_com.c
new file mode 100644
index 0000000..4107dee
--- /dev/null
+++ b/programs/dxdiag/dxdiag_com.c
@@ -0,0 +1,39 @@
+/*
+ * DxDiag common functions
+ * 
+ * Copyright 2009 Austin English
+ * 
+ * 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
+ */
+
+
+#define WIN32_LEAN_AND_MEAN
+#include <dxdiag.h>
+#include <windows.h>
+#include <dxdiag_com.h>
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(dxdiag);
+
+HRESULT DxDiagCOM_GetContainer(IDxDiagContainer* source, LPWSTR query, IDxDiagContainer** container)
+{
+    HRESULT hr;
+
+    hr = IDxDiagContainer_GetChildContainer(source, query, container);
+    if (FAILED(hr))
+        WINE_ERR("IDxDiagContainer_GetChildContainer failed: %s\n", wine_dbgstr_w(query));
+    return hr;
+}
+
diff --git a/programs/dxdiag/dxdiag_com.h b/programs/dxdiag/dxdiag_com.h
new file mode 100644
index 0000000..b13afbf
--- /dev/null
+++ b/programs/dxdiag/dxdiag_com.h
@@ -0,0 +1,22 @@
+/*
+ * DxDiag common header
+ *
+ * Copyright 2009 Austin English
+ *
+ * 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
+ */
+
+HRESULT DxDiagCOM_GetContainer(IDxDiagContainer* source, LPWSTR query, IDxDiagContainer** container);
+
-- 
1.5.4.3


More information about the wine-patches mailing list