msi: automation: clean up comments.
Misha Koshelev
mk144210 at bcm.tmc.edu
Tue Feb 27 23:37:09 CST 2007
Looking back at James comments, maybe I did have a little too much
commenting there :)
Changelog:
* msi: automation: clean up comments.
-------------- next part --------------
From 345fec452e3d7a254e71bb8798731390fe738cb2 Mon Sep 17 00:00:00 2001
From: Misha Koshelev <mk144210 at bcm.tmc.edu>
Date: Tue, 27 Feb 2007 23:31:51 -0600
Subject: msi: automation: clean up comments.
---
dlls/msi/automation.c | 39 +++++----------------------------------
1 files changed, 5 insertions(+), 34 deletions(-)
diff --git a/dlls/msi/automation.c b/dlls/msi/automation.c
index 970f98a..67399c4 100644
--- a/dlls/msi/automation.c
+++ b/dlls/msi/automation.c
@@ -37,19 +37,12 @@ #include "msiserver_dispids.h"
WINE_DEFAULT_DEBUG_CHANNEL(msi);
-/*
- * If you would like to implement a new automation function/object, look towards the bottom of this
- * file for the "meat and potatoes" section.
- */
-
/* FIXME: I don't know how big this should be */
#define MAX_MSI_STRING 1000
/*
- * AutomationObject - "base" class for all automation objects so we don't have to repeat functions. Just
- * need to implement Invoke function for each dispinterface that is called from within
- * the AutomationObject Invoke function which performs error checking, and pass the new
- * function to create_automation_object.
+ * AutomationObject - "base" class for all automation objects. For each interface, we implement Invoke function
+ * called from AutomationObject::Invoke, and pass this function to create_automation_object.
*/
typedef interface AutomationObject AutomationObject;
@@ -73,9 +66,7 @@ interface AutomationObject {
/* The MSI handle of the current object */
MSIHANDLE msiHandle;
- /* A function that is called from IDispatch::Invoke, specific to this type of object. By the
- * time this function is called, basic error checking has been done in the AutomationObject
- * Invoke function */
+ /* A function that is called from AutomationObject::Invoke, specific to this type of object. */
HRESULT (STDMETHODCALLTYPE *funcInvoke)(
AutomationObject* This,
DISPID dispIdMember,
@@ -193,20 +184,11 @@ static HRESULT WINAPI AutomationObject_Q
TRACE("(%p/%p)->(%s,%p)\n", iface, This, debugstr_guid(riid), ppvObject);
- /*
- * Perform a sanity check on the parameters.
- */
if ( (This==0) || (ppvObject==0) )
return E_INVALIDARG;
- /*
- * Initialize the return parameter.
- */
*ppvObject = 0;
- /*
- * Compare the riid with the interface IDs implemented by this object.
- */
if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IDispatch) || IsEqualGUID(riid, This->clsid))
*ppvObject = This;
else if (IsEqualGUID(riid, &IID_IProvideClassInfo))
@@ -216,9 +198,6 @@ static HRESULT WINAPI AutomationObject_Q
else if (IsEqualGUID(riid, &IID_IProvideMultipleClassInfo))
*ppvObject = (IProvideMultipleClassInfo*)&(This->lpvtblIProvideMultipleClassInfo);
- /*
- * Check that we obtained an interface.
- */
if ((*ppvObject)==0)
{
TRACE("() : asking for unsupported interface %s\n",debugstr_guid(riid));
@@ -557,17 +536,9 @@ static const IProvideMultipleClassInfoVt
};
/*
- * Individual Object Invocation Functions - Our meat and potatoes
+ * Individual Object Invocation Functions
*
- * - To add a method, just add an appropriate case to an appropriate switch statement
- * * Follow syntax here for property get/puts and method calls. Remember, parameters
- * are passed IN REVERSE ORDER (last parameter to function is first in array). This got me at first.
- * * MSI specs seem to indicate that most functions return an S_OK. If you don't, chances are the
- * script will stop running, but check the MSI documentation for your specific function.
- * - To add a new object, just add an ObjectImpl_Invoke method and appropriate method call that
- * creates your object. Note that these are not true Invoke methods, but are called from
- * AutomationObject_Invoke with some appropriate parameter error checking, made to ensure that
- * the functions below remain just down to what they need to do.
+ * - Method parameters are passed IN REVERSE ORDER
*/
/* Macros for variant conversions */
--
1.4.1
More information about the wine-patches
mailing list