Updating freebasic windows .bi

Windows specific questions.
Post Reply
aloberoger
Posts: 507
Joined: Jan 13, 2009 19:23

Updating freebasic windows .bi

Post by aloberoger »

Update For Win/oleauto.bi

Code: Select all


declare function  GetRecordInfoFromTypeInfo (byval As ITypeInfo ptr,byval As IRecordInfo Ptr Ptr) As HRESULT
declare function  GetRecordInfoFromGuids (byval As REFGUID,byval As ULong,byval As ULong,byval As LCID,byval As REFGUID,byval As IRecordInfo Ptr Ptr)  as HRESULT


Update For Win/oaidl.bi

Code: Select all


 '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''ADDED ''''''''''''''''''''''''''''''''''''
 
#Define ITypeMarshal_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#Define ITypeMarshal_AddRef(This) (This)->lpVtbl->AddRef(This)
#Define ITypeMarshal_Release(This) (This)->lpVtbl->Release(This)
#Define ITypeMarshal_Size(This,pvType,dwDestContext,pvDestContext,pSize) (This)->lpVtbl->Size(This,pvType,dwDestContext,pvDestContext,pSize)
#Define ITypeMarshal_Marshal(This,pvType,dwDestContext,pvDestContext,cbBufferLength,pBuffer,pcbWritten) (This)->lpVtbl->Marshal(This,pvType,dwDestContext,pvDestContext,cbBufferLength,pBuffer,pcbWritten)
#Define ITypeMarshal_Unmarshal(This,pvType,dwFlags,cbBufferLength,pBuffer,pcbRead) (This)->lpVtbl->Unmarshal(This,pvType,dwFlags,cbBufferLength,pBuffer,pcbRead)
#Define ITypeMarshal_Free(This,pvType) (This)->lpVtbl->Free(This,pvType)
 

Type ICreateTypeInfoVtbl_ As ICreateTypeInfoVtbl 
type ICreateTypeInfo 
     lpVtbl As ICreateTypeInfoVtbl_ ptr   
end Type

Type ICreateTypeInfoVtbl
     QueryInterface as function(ByVal  As  ICreateTypeInfo ptr,As REFIID,As pvoid Ptr)As HRESULT
     AddRef as function(ByVal  As  ICreateTypeInfo Ptr)As ULong
      Release as function(ByVal  As  ICreateTypeInfo Ptr)As ULong
     SetGuid as function (ByVal  As ICreateTypeInfo Ptr, As REFGUID)As HRESULT
     SetTypeFlags as function(ByVal  As  ICreateTypeInfo Ptr, As UINT)As HRESULT
     SetDocString as function (ByVal  As ICreateTypeInfo Ptr, As LPOLESTR)As HRESULT
     SetHelpContext as function(ByVal  As  ICreateTypeInfo Ptr, As DWORD)As HRESULT
     SetVersion as function(ByVal  As  ICreateTypeInfo Ptr,As WORD, As WORD)As HRESULT
     AddRefTypeInfo as function(ByVal  As  ICreateTypeInfo ptr, As ITypeInfo ptr, As HREFTYPE Ptr)As HRESULT
     AddFuncDesc as function(ByVal  As  ICreateTypeInfo ptr, As Integer, As FUNCDESC Ptr)As HRESULT
     AddImplType as function (ByVal  As ICreateTypeInfo Ptr, As UINT, As HREFTYPE)As HRESULT
     SetImplTypeFlags as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As Integer)As HRESULT
     SetAlignment as function(ByVal  As  ICreateTypeInfo Ptr, As WORD)As HRESULT
     SetSchema as function(ByVal  As  ICreateTypeInfo Ptr, As LPOLESTR)As HRESULT
     AddVarDesc as function(ByVal  As  ICreateTypeInfo ptr, As UINT, As VARDESC Ptr)As HRESULT
     SetFuncAndParamNames as function(ByVal  As  ICreateTypeInfo ptr, As UINT, As LPOLESTR Ptr, As UINT)As HRESULT
     SetVarName as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As LPOLESTR)As HRESULT
     SetTypeDescAlias as function(ByVal  As  ICreateTypeInfo ptr, As TYPEDESC Ptr)As HRESULT
     DefineFuncAsDllEntry as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As LPOLESTR, As LPOLESTR)As HRESULT
     SetFuncDocString as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As LPOLESTR)As HRESULT
     SetVarDocString as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As LPOLESTR)As HRESULT
     SetFuncHelpContext as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As DWORD)As HRESULT
     SetVarHelpContext as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As DWORD)As HRESULT
     SetMops as function(ByVal  As  ICreateTypeInfo Ptr, As UINT, As BSTR)As HRESULT
     SetTypeIdldesc as function (ByVal  As ICreateTypeInfo ptr, As IDLDESC Ptr)As HRESULT
     LayOut as function (ByVal  As ICreateTypeInfo Ptr)As HRESULT
    
End Type



 
#Define ICreateTypeInfo_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#Define ICreateTypeInfo_AddRef(This) (This)->lpVtbl->AddRef(This)
#Define ICreateTypeInfo_Release(This) (This)->lpVtbl->Release(This)
#Define ICreateTypeInfo_SetGuid(This,guid) (This)->lpVtbl->SetGuid(This,guid)
#Define ICreateTypeInfo_SetTypeFlags(This,uTypeFlags) (This)->lpVtbl->SetTypeFlags(This,uTypeFlags)
#Define ICreateTypeInfo_SetDocString(This,pStrDoc) (This)->lpVtbl->SetDocString(This,pStrDoc)
#Define ICreateTypeInfo_SetHelpContext(This,dwHelpContext) (This)->lpVtbl->SetHelpContext(This,dwHelpContext)
#Define ICreateTypeInfo_SetVersion(This,wMajorVerNum,wMinorVerNum) (This)->lpVtbl->SetVersion(This,wMajorVerNum,wMinorVerNum)
#Define ICreateTypeInfo_AddRefTypeInfo(This,pTInfo,phRefType) (This)->lpVtbl->AddRefTypeInfo(This,pTInfo,phRefType)
#Define ICreateTypeInfo_AddFuncDesc(This,index,pFuncDesc) (This)->lpVtbl->AddFuncDesc(This,index,pFuncDesc)
#Define ICreateTypeInfo_AddImplType(This,index,hRefType) (This)->lpVtbl->AddImplType(This,index,hRefType)
#Define ICreateTypeInfo_SetImplTypeFlags(This,index,implTypeFlags) (This)->lpVtbl->SetImplTypeFlags(This,index,implTypeFlags)
#Define ICreateTypeInfo_SetAlignment(This,cbAlignment) (This)->lpVtbl->SetAlignment(This,cbAlignment)
#Define ICreateTypeInfo_SetSchema(This,pStrSchema) (This)->lpVtbl->SetSchema(This,pStrSchema)
#Define ICreateTypeInfo_AddVarDesc(This,index,pVarDesc) (This)->lpVtbl->AddVarDesc(This,index,pVarDesc)
#Define ICreateTypeInfo_SetFuncAndParamNames(This,index,rgszNames,cNames) (This)->lpVtbl->SetFuncAndParamNames(This,index,rgszNames,cNames)
#Define ICreateTypeInfo_SetVarName(This,index,szName) (This)->lpVtbl->SetVarName(This,index,szName)
#Define ICreateTypeInfo_SetTypeDescAlias(This,pTDescAlias) (This)->lpVtbl->SetTypeDescAlias(This,pTDescAlias)
#Define ICreateTypeInfo_DefineFuncAsDllEntry(This,index,szDllName,szProcName) (This)->lpVtbl->DefineFuncAsDllEntry(This,index,szDllName,szProcName)
#Define ICreateTypeInfo_SetFuncDocString(This,index,szDocString) (This)->lpVtbl->SetFuncDocString(This,index,szDocString)
#Define ICreateTypeInfo_SetVarDocString(This,index,szDocString) (This)->lpVtbl->SetVarDocString(This,index,szDocString)
#Define ICreateTypeInfo_SetFuncHelpContext(This,index,dwHelpContext) (This)->lpVtbl->SetFuncHelpContext(This,index,dwHelpContext)
#Define ICreateTypeInfo_SetVarHelpContext(This,index,dwHelpContext) (This)->lpVtbl->SetVarHelpContext(This,index,dwHelpContext)
#Define ICreateTypeInfo_SetMops(This,index,bstrMops) (This)->lpVtbl->SetMops(This,index,bstrMops)
#Define ICreateTypeInfo_SetTypeIdldesc(This,pIdlDesc) (This)->lpVtbl->SetTypeIdldesc(This,pIdlDesc)
#Define ICreateTypeInfo_LayOut(This) (This)->lpVtbl->LayOut(This)
 

 

type ICreateTypeInfo2Vtbl_ As ICreateTypeInfo2Vtbl  

Type ICreateTypeInfo2 
	 lpVtbl As ICreateTypeInfo2Vtbl_ Ptr
End Type
type  ICreateTypeInfo2Vtbl 
	 QueryInterface As function(As ICreateTypeInfo2 Ptr,As REFIID,As lpvoid Ptr)As HRESULT
	 AddRef As function(As ICreateTypeInfo2 Ptr)As ULong
	 Release As function(As ICreateTypeInfo2 Ptr)As ULong
	 SetGuid As Function (As ICreateTypeInfo2 Ptr,as REFGUID )As HRESULT
	 SetTypeFlags As function(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
	 SetDocString As function(As ICreateTypeInfo2 Ptr,As LPOLESTR)As HRESULT
	 SetHelpContext As function(As ICreateTypeInfo2 Ptr,As DWORD)As HRESULT
	 SetVersion As function(As ICreateTypeInfo2 Ptr,As WORD,As WORD)As HRESULT
	 AddRefTypeInfo As function(As ICreateTypeInfo2 Ptr,As ITypeInfo PTR,As HREFTYPE Ptr)As HRESULT
	 AddFuncDesc As function(As ICreateTypeInfo2 Ptr,As UINT,As FUNCDESC Ptr)As HRESULT
	 AddImplType As function(As ICreateTypeInfo2 Ptr,As UINT,As HREFTYPE)As HRESULT
	 SetImplTypeFlags As function(As ICreateTypeInfo2 Ptr,As UINT,As Integer)As HRESULT
	 SetAlignment As function(As ICreateTypeInfo2 Ptr,As WORD)As HRESULT
	 SetSchema As function(As ICreateTypeInfo2 Ptr,As LPOLESTR)As HRESULT
	 AddVarDesc As function(As ICreateTypeInfo2 Ptr,As UINT,As VARDESC Ptr)As HRESULT
	 SetFuncAndParamNames As function(As ICreateTypeInfo2 Ptr,As UINT,As LPOLESTR Ptr,As UINT)As HRESULT
	 SetVarName As function(As ICreateTypeInfo2 Ptr,As UINT,As LPOLESTR)As HRESULT
	 SetTypeDescAlias As function(As ICreateTypeInfo2 Ptr,As TYPEDESC Ptr)As HRESULT
	 DefineFuncAsDllEntry As function(As ICreateTypeInfo2 Ptr,As UINT,As LPOLESTR,As LPOLESTR)As HRESULT
	 SetFuncDocString As function(As ICreateTypeInfo2 Ptr,As UINT,As LPOLESTR)As HRESULT
	 SetVarDocString As function(As ICreateTypeInfo2 Ptr,As UINT,As LPOLESTR)As HRESULT
	 SetFuncHelpContext As function(As ICreateTypeInfo2 Ptr,As UINT,As DWORD)As HRESULT
	 SetVarHelpContext As function(As ICreateTypeInfo2 Ptr,As UINT,As DWORD)As HRESULT
	 SetMops As function(As ICreateTypeInfo2 Ptr,As UINT,As BSTR)As HRESULT
	 SetTypeIdldesc As function(As ICreateTypeInfo2 Ptr,As IDLDESC Ptr)As HRESULT
	 LayOut As function(As ICreateTypeInfo2 Ptr)As HRESULT
	 DeleteFuncDesc As function(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
	 DeleteFuncDescByMemId As function(As ICreateTypeInfo2 Ptr,As MEMBERID,As INVOKEKIND)As HRESULT
	 DeleteVarDesc As function(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
	 DeleteVarDescByMemId As function(As ICreateTypeInfo2 Ptr,As MEMBERID)As HRESULT
	 DeleteImplType As function(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
	 SetCustData As function(As ICreateTypeInfo2 Ptr,As REFGUID,As VARIANT Ptr)As HRESULT
	 SetFuncCustData As function(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
	 SetParamCustData As function(As ICreateTypeInfo2 Ptr,As UINT,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
	 SetVarCustData As function(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
	 SetImplTypeCustData As function(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
	 SetHelpStringContext As function(As ICreateTypeInfo2 Ptr,As ULong)As HRESULT
	 SetFuncHelpStringContext As function(As ICreateTypeInfo2 Ptr,As UINT,As ULong)As HRESULT
	 SetVarHelpStringContext As function(As ICreateTypeInfo2 Ptr,As UINT,As ULong)As HRESULT
	 Invalidate As function(As ICreateTypeInfo2 Ptr)As HRESULT
	 SetName As function(As ICreateTypeInfo2 Ptr,As LPOLESTR)As HRESULT
End Type


#define ICreateTypeInfo2_QueryInterface(A,B,C) (A)->lpVtbl->QueryInterface(A,B,C)
#define ICreateTypeInfo2_AddRef(A) (A)->lpVtbl->AddRef(A)
#define ICreateTypeInfo2_Release(A) (A)->lpVtbl->Release(A)
#define ICreateTypeInfo2_SetGuid(A,B) (A)->lpVtbl->SetGuid(A,B)
#define ICreateTypeInfo2_SetTypeFlags(A,B) (A)->lpVtbl->SetTypeFlags(A,B)
#define ICreateTypeInfo2_SetDocString(A,B) (A)->lpVtbl->SetDocString(A,B)
#define ICreateTypeInfo2_SetHelpContext(A,B) (A)->lpVtbl->SetHelpContext(A,B)
#define ICreateTypeInfo2_SetVersion(A,B,C) (A)->lpVtbl->SetVersion(A,B,C)
#define ICreateTypeInfo2_AddRefTypeInfo(A,B,C) (A)->lpVtbl->AddRefTypeInfo(A,B,C)
#define ICreateTypeInfo2_AddFuncDesc(A,B,C) (A)->lpVtbl->AddFuncDesc(A,B,C)
#define ICreateTypeInfo2_AddImplType(A,B,C) (A)->lpVtbl->AddImplType(A,B,C)
#define ICreateTypeInfo2_SetImplTypeFlags(A,B,C) (A)->lpVtbl->SetImplTypeFlags(A,B,C)
#define ICreateTypeInfo2_SetAlignment(A,B) (A)->lpVtbl->SetAlignment(A,B)
#define ICreateTypeInfo2_SetSchema(A,B) (A)->lpVtbl->SetSchema(A,B)
#define ICreateTypeInfo2_AddVarDesc(A,B,C) (A)->lpVtbl->AddVarDesc(A,B,C)
#define ICreateTypeInfo2_SetFuncAndParamNames(A,B,C,D) (A)->lpVtbl->SetFuncAndParamNames(A,B,C,D)
#define ICreateTypeInfo2_SetVarName(A,B,C) (A)->lpVtbl->SetVarName(A,B,C)
#define ICreateTypeInfo2_SetTypeDescAlias(A,B) (A)->lpVtbl->SetTypeDescAlias(A,B)
#define ICreateTypeInfo2_DefineFuncAsDllEntry(A,B,C,D) (A)->lpVtbl->DefineFuncAsDllEntry(A,B,C,D)
#define ICreateTypeInfo2_SetFuncDocString(A,B,C) (A)->lpVtbl->SetFuncDocString(A,B,C)
#define ICreateTypeInfo2_SetVarDocString(A,B,C) (A)->lpVtbl->SetVarDocString(A,B,C)
#define ICreateTypeInfo2_SetFuncHelpContext(A,B,C) (A)->lpVtbl->SetFuncHelpContext(A,B,C)
#define ICreateTypeInfo2_SetVarHelpContext(A,B,C) (A)->lpVtbl->SetVarHelpContext(A,B,C)
#define ICreateTypeInfo2_SetMops(A,B,C) (A)->lpVtbl->SetMops(A,B,C)
#define ICreateTypeInfo2_SetTypeIdldesc(A,B) (A)->lpVtbl->SetTypeIdldesc(A,B)
#define ICreateTypeInfo2_LayOut(A) (A)->lpVtbl->LayOut(A)
#define ICreateTypeInfo2_DeleteFuncDesc(A,B) (A)->lpVtbl->DeleteFuncDesc(A,B)
#define ICreateTypeInfo2_DeleteFuncDescByMemId(A,B,C) (A)->lpVtbl->DeleteFuncDescByMemId(A,B,C)
#define ICreateTypeInfo2_DeleteVarDesc(A,B) (A)->lpVtbl->DeleteVarDesc(A,B)
#define ICreateTypeInfo2_DeleteVarDescByMemId(A,B) (A)->lpVtbl->DeleteVarDescByMemId(A,B)
#define ICreateTypeInfo2_DeleteImplType(A,B) (A)->lpVtbl->DeleteImplType(A,B)
#define ICreateTypeInfo2_SetCustData(A,B,C) (A)->lpVtbl->SetCustData(A,B,C)
#define ICreateTypeInfo2_SetFuncCustData(A,B,C,D) (A)->lpVtbl->SetFuncCustData(A,B,C,D)
#define ICreateTypeInfo2_SetParamCustData(A,B,C,D,E) (A)->lpVtbl->SetParamCustData(A,B,C,D,E)
#define ICreateTypeInfo2_SetVarCustData(A,B,C,D) (A)->lpVtbl->SetVarCustData(A,B,C,D)
#define ICreateTypeInfo2_SetImplTypeCustData(A,B,C,D) (A)->lpVtbl->SetImplTypeCustData(A,B,C,D)
#define ICreateTypeInfo2_SetHelpStringContext(A,B) (A)->lpVtbl->SetHelpStringContext(A,B)
#define ICreateTypeInfo2_SetFuncHelpStringContext(A,B,C) (A)->lpVtbl->SetFuncHelpStringContext(A,B,C)
#define ICreateTypeInfo2_SetVarHelpStringContext(A,B,C) (A)->lpVtbl->SetVarHelpStringContext(A,B,C)
#define ICreateTypeInfo2_Invalidate(A) (A)->lpVtbl->Invalidate(A)
#define ICreateTypeInfo2_SetName(T,s) (T)->lpVtbl->SetName(T,s)

DECLARE FUNCTION ICreateTypeInfo2_DeleteFuncDesc_Proxy(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
DECLARE Sub ICreateTypeInfo2_DeleteFuncDesc_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_DeleteFuncDescByMemId_Proxy(As ICreateTypeInfo2 Ptr,As MEMBERID,As INVOKEKIND)As HRESULT
DECLARE Sub ICreateTypeInfo2_DeleteFuncDescByMemId_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_DeleteVarDesc_Proxy(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
DECLARE Sub ICreateTypeInfo2_DeleteVarDesc_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_DeleteVarDescByMemId_Proxy(As ICreateTypeInfo2 Ptr,As MEMBERID)As HRESULT
DECLARE SUB ICreateTypeInfo2_DeleteVarDescByMemId_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_DeleteImplType_Proxy(As ICreateTypeInfo2 Ptr,As UINT)As HRESULT
DECLARE Sub ICreateTypeInfo2_DeleteImplType_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetCustData_Proxy(As ICreateTypeInfo2 Ptr,As REFGUID,As VARIANT Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetCustData_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetFuncCustData_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetFuncCustData_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetParamCustData_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetParamCustData_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetVarCustData_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetVarCustData_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetImplTypeCustData_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As REFGUID,As VARIANT Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetImplTypeCustData_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetHelpStringContext_Proxy(As ICreateTypeInfo2 Ptr,As ULong)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetHelpStringContext_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetFuncHelpStringContext_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As ULong)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetFuncHelpStringContext_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_SetVarHelpStringContext_Proxy(As ICreateTypeInfo2 Ptr,As UINT,As ULong)As HRESULT
DECLARE Sub ICreateTypeInfo2_SetVarHelpStringContext_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE Function ICreateTypeInfo2_Invalidate_Proxy(As ICreateTypeInfo2 Ptr)As HRESULT
DECLARE Sub ICreateTypeInfo2_Invalidate_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD Ptr)
DECLARE FUNCTION ICreateTypeInfo2_SetName_Proxy(As ICreateTypeInfo2 Ptr,As LPOLESTR)As HRESULT
DECLARE SUB ICreateTypeInfo2_SetName_Stub(As IRpcStubBuffer PTR,As IRpcChannelBuffer PTR,As PRPC_MESSAGE,As DWORD PTR)
 
 
 
 
 
Type ICreateTypeLibVtbl_ As ICreateTypeLibVtbl
Type ICreateTypeLib  
     lpVtbl As  ICreateTypeLibVtbl_ Ptr   
end Type
Type ICreateTypeLibVtbl
    
     QueryInterface as function(ByVal As ICreateTypeLib Ptr,As REFIID,as pvoid Ptr)As HRESULT
     AddRef as function(ByVal As ICreateTypeLib Ptr)As ULong
     Release as function(ByVal As ICreateTypeLib Ptr)As ULong
     CreateTypeInfo as function(ByVal As ICreateTypeLib ptr,As LPOLESTR,As TYPEKIND,As ICreateTypeInfo ptr Ptr)As HRESULT
     SetName as function(ByVal As ICreateTypeLib Ptr,As LPOLESTR)As HRESULT
     SetVersion as function(ByVal As ICreateTypeLib Ptr,As WORD,As WORD)As HRESULT
     SetGuid as function(ByVal As ICreateTypeLib Ptr,As REFGUID)As HRESULT
     SetDocString as function(ByVal As ICreateTypeLib Ptr,As LPOLESTR)As HRESULT
     SetHelpFileName as function(ByVal As ICreateTypeLib Ptr,As LPOLESTR)As HRESULT
     SetHelpContext as function(ByVal As ICreateTypeLib Ptr,As DWORD)As HRESULT
     SetLcid as function(ByVal As ICreateTypeLib Ptr,As LCID)As HRESULT
     SetLibFlags as function(ByVal As ICreateTypeLib Ptr,As UINT)As HRESULT
     SaveAllChanges as function(ByVal As ICreateTypeLib Ptr)As HRESULT
    
End Type


 
#Define ICreateTypeLib_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#Define ICreateTypeLib_AddRef(This) (This)->lpVtbl->AddRef(This)
#Define ICreateTypeLib_Release(This) (This)->lpVtbl->Release(This)
#Define ICreateTypeLib_CreateTypeInfo(This,szName,tkind,ppCTInfo) (This)->lpVtbl->CreateTypeInfo(This,szName,tkind,ppCTInfo)
#Define ICreateTypeLib_SetName(This,szName) (This)->lpVtbl->SetName(This,szName)
#Define ICreateTypeLib_SetVersion(This,wMajorVerNum,wMinorVerNum) (This)->lpVtbl->SetVersion(This,wMajorVerNum,wMinorVerNum)
#Define ICreateTypeLib_SetGuid(This,guid) (This)->lpVtbl->SetGuid(This,guid)
#Define ICreateTypeLib_SetDocString(This,szDoc) (This)->lpVtbl->SetDocString(This,szDoc)
#Define ICreateTypeLib_SetHelpFileName(This,szHelpFileName) (This)->lpVtbl->SetHelpFileName(This,szHelpFileName)
#Define ICreateTypeLib_SetHelpContext(This,dwHelpContext) (This)->lpVtbl->SetHelpContext(This,dwHelpContext)
#Define ICreateTypeLib_SetLcid(This,lcid) (This)->lpVtbl->SetLcid(This,lcid)
#Define ICreateTypeLib_SetLibFlags(This,uLibFlags) (This)->lpVtbl->SetLibFlags(This,uLibFlags)
#Define ICreateTypeLib_SaveAllChanges(This) (This)->lpVtbl->SaveAllChanges(This)
 



Type ICreateTypeLib2Vtbl_ As ICreateTypeLib2Vtbl
 type ICreateTypeLib2 
	lpVtbl As ICreateTypeLib2Vtbl_ Ptr  
End Type
type  ICreateTypeLib2Vtbl
	BEGIN_INTERFACE
	 QueryInterface As Function(As ICreateTypeLib2 Ptr,As REFIID,As LPVOID PTR) As HRESULT
	 AddRef As Function(As ICreateTypeLib2 Ptr) As ULONG
	 Release As Function(As ICreateTypeLib2 Ptr) As ULong
	 CreateTypeInfo As Function(As ICreateTypeLib2 Ptr,As LPOLESTR,As TYPEKIND,As ICreateTypeInfo Ptr Ptr) As HRESULT
	 SetName As Function(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
	 SetVersion As Function(As ICreateTypeLib2 Ptr,As WORD,As WORD) As HRESULT
	 SetGuid As Function(As ICreateTypeLib2 Ptr,As REFGUID) As HRESULT
	 SetDocString As Function(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
	 SetHelpFileName As Function(As ICreateTypeLib2 Ptr,As LPOLESTR )As HRESULT
	 SetHelpContext As Function(As ICreateTypeLib2 Ptr,As DWORD) As HRESULT
	 SetLcid As Function(As ICreateTypeLib2 Ptr,As LCID) As HRESULT
	 SetLibFlags As Function(As ICreateTypeLib2 Ptr,As UINT) As HRESULT
	 SaveAllChanges As Function(As ICreateTypeLib2 Ptr) As HRESULT
	 DeleteTypeInfo As Function(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
	 SetCustData As Function(As ICreateTypeLib2 Ptr,As REFGUID,As VARIANT Ptr) As HRESULT
	 SetHelpStringContext As Function(As ICreateTypeLib2 Ptr,As ULong) As HRESULT
	 SetHelpStringDll As Function(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
	END_INTERFACE
End Type

#define ICreateTypeLib2_QueryInterface(A,B,C) (A)->lpVtbl->QueryInterface(A,B,C)
#define ICreateTypeLib2_AddRef(A) (A)->lpVtbl->AddRef(A)
#define ICreateTypeLib2_Release(A) (A)->lpVtbl->Release(A)
#define ICreateTypeLib2_CreateTypeInfo(A,B,C,D) (A)->lpVtbl->CreateTypeInfo(A,B,C,D)
#define ICreateTypeLib2_SetName(A,B) (A)->lpVtbl->SetName(A,B)
#define ICreateTypeLib2_SetVersion(A,B,C) (A)->lpVtbl->SetVersion(A,B,C)
#define ICreateTypeLib2_SetGuid(A,B) (A)->lpVtbl->SetGuid(A,B)
#define ICreateTypeLib2_SetDocString(A,B) (A)->lpVtbl->SetDocString(A,B)
#define ICreateTypeLib2_SetHelpFileName(A,B) (A)->lpVtbl->SetHelpFileName(A,B)
#define ICreateTypeLib2_SetHelpContext(A,B) (A)->lpVtbl->SetHelpContext(A,B)
#define ICreateTypeLib2_SetLcid(A,B) (A)->lpVtbl->SetLcid(A,B)
#define ICreateTypeLib2_SetLibFlags(A,B) (A)->lpVtbl->SetLibFlags(A,B)
#define ICreateTypeLib2_SaveAllChanges(A) (A)->lpVtbl->SaveAllChanges(A)
#define ICreateTypeLib2_DeleteTypeInfo(A,B) (A)->lpVtbl->DeleteTypeInfo(A,B)
#define ICreateTypeLib2_SetCustData(A,B,C) (A)->lpVtbl->SetCustData(A,B,C)
#define ICreateTypeLib2_SetHelpStringContext(A,B) (A)->lpVtbl->SetHelpStringContext(A,B)
#define ICreateTypeLib2_SetHelpStringDll(A,B) (A)->lpVtbl->SetHelpStringDll(A,B)

Declare Function ICreateTypeLib2_DeleteTypeInfo_Proxy(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
Declare Sub ICreateTypeLib2_DeleteTypeInfo_Stub(As IRpcStubBuffer Ptr,As IRpcChannelBuffer Ptr,As PRPC_MESSAGE,As DWORD Ptr) 
Declare Function  ICreateTypeLib2_SetCustData_Proxy(As ICreateTypeLib2 Ptr,As REFGUID,As VARIANT Ptr) As HRESULT
Declare Sub ICreateTypeLib2_SetCustData_Stub(As IRpcStubBuffer Ptr,As IRpcChannelBuffer Ptr,As PRPC_MESSAGE,As DWORD Ptr) 
Declare Function  ICreateTypeLib2_SetHelpStringContext_Proxy(As ICreateTypeLib2 Ptr,As ULong)As HRESULT
Declare Sub ICreateTypeLib2_SetHelpStringContext_Stub(As IRpcStubBuffer Ptr,As IRpcChannelBuffer Ptr,As PRPC_MESSAGE,As DWORD Ptr) 
Declare Function  ICreateTypeLib2_SetHelpStringDll_Proxy(As ICreateTypeLib2 Ptr,As LPOLESTR) As HRESULT
Declare Sub ICreateTypeLib2_SetHelpStringDll_Stub(As IRpcStubBuffer Ptr,As IRpcChannelBuffer Ptr,As PRPC_MESSAGE,As DWORD Ptr) 
 


Update For Win/wingdi.bi

Code: Select all

#inclib  "msimg32" 

#Define GRADIENT_FILL_RECT_H  &h00000000
#define GRADIENT_FILL_RECT_V  &h00000001
#define GRADIENT_FILL_TRIANGLE  &h00000002
#define GRADIENT_FILL_OP_FLAG  &h000000ff

Declare Function GradientFill   ( byval  hdc As HDC , byval pVertex as PTRIVERTEX , byval  dwNumVertex as DWORD , byval  pMesh as CONST PVOID , byval   dwNumMesh as DWORD, byval dwMode As DWORD ) As BOOL

counting_pine
Site Admin
Posts: 6323
Joined: Jul 05, 2005 17:32
Location: Manchester, Lancs

Re: Updating freebasic .bi

Post by counting_pine »

Hi aloberoger. Thanks for these. Sorry, I don't really know much about Win32..
Can you explain what changes you've made?
Are they additions, changes or replacements? If additions, where do you want them to be inserted? If you can provide a diff of the changes, or maybe a Github fork, that might be easier.
And can anyone else verify that the changes are valid, and perhaps make sure that they fit in with the existing style of the headers?
aloberoger
Posts: 507
Joined: Jan 13, 2009 19:23

Re: Updating freebasic .bi

Post by aloberoger »

they are additions
copy the contents and paste them in they freebasic named files
counting_pine
Site Admin
Posts: 6323
Joined: Jul 05, 2005 17:32
Location: Manchester, Lancs

Re: Updating freebasic .bi

Post by counting_pine »

I'd prefer not to simply append them to the end, because there is probably some sort of reasonable ordering going on inside the files. That's why I'd like to know where would be good to insert the changes, and why a diff would be helpful.

I'd also like to know what the nature of the changes are - i.e. what functionality they add, and why they might not have been there before now. I'd also like for someone else to verify them.


Basically, I personally don't really understand anything you've done, but I'm reluctant to see your changes get buried in the forum unimplemented because there is too much work needed on the part of the people who will implement them.
And if that person is me, I want to be very careful I'm not adding bad information to existing headers.

The only intelligent comment I can really make, is that I see some areas where parameters are not being passed byval or byref, and I will want those to be explicit before they are added.
aloberoger
Posts: 507
Joined: Jan 13, 2009 19:23

Re: Updating freebasic windows .bi

Post by aloberoger »

OK counting_pine, you can think so. But this compilation results from the various ends of program that I had to translate and of which
declarations not figured in the provided compilation of FreeBasic. It was necessary that I draw them from the headers C++ either of Lcc or of pelleC or of g++.
The majority was tested in these codes which I cannot publish for the moment because either too length or in court of completion. Very of same I posted " Creating tlb by code " in the Windows forum, and NicebuttonC, I will post other codes according to the oppotunity.
It also should be announced that these updates relates initially to those which write FreeBasic which can get a glance test them and is to compare them with the heders C before placing them at the disposal of the users in a forthcoming version.
St_W
Posts: 1626
Joined: Feb 11, 2009 14:24
Location: Austria
Contact:

Re: Updating freebasic windows .bi

Post by St_W »

@counting_pine:
The Windows API has been extended/modified several times with each new version of Microsoft Windows. The original C Headers include Version-specific defines, which seem to be not included in the FreeBasic Headers. For example, the missing Defines in "wingdi.bi" are wrapped in an

Code: Select all

#if (WINVER >= 0x0500)
#define GRADIENT_FILL_RECT_H 0x00
#define GRADIENT_FILL_RECT_V 0x01
#define GRADIENT_FILL_TRIANGLE 0x02
#define GRADIENT_FILL_OP_FLAG 0xff
#define COLORMATCHTOTARGET_EMBEDED 0x00000001
#define CREATECOLORSPACE_EMBEDED   0x00000001
#define SETICMPROFILE_EMBEDED      0x00000001
#endif
block, whose content is only defined when WINVER is defined as &h500 or higher (that's Windows 2000 or newer).

FreeBasic's Windows headers seem to be quite old. Some parts may have been updated, so that they include such additions of later Windows versions, but others have not. "wingdi.bi" is such an example - the definitions above are simply missing.

I don't know whether it is right to just append these lines. It updates some of the outdated headers and adds some missing definitions/declarations, but there would be more missing definitions/declarations to add. I don't think appending these lines is an appropriate fix for the GIT repo, it's rather dirty.
The best thing would be to go through all the headers, compare them with the C Headers (e.g. these from MinGW) and add all missing definitions/declarations - but I know, thats A LOT of work.
marcov
Posts: 3462
Joined: Jun 16, 2005 9:45
Location: Netherlands
Contact:

Re: Updating freebasic windows .bi

Post by marcov »

St_W wrote: I don't know whether it is right to just append these lines. It updates some of the outdated headers and adds some missing definitions/declarations, but there would be more missing definitions/declarations to add. I don't think appending these lines is an appropriate fix for the GIT repo, it's rather dirty.
The best thing would be to go through all the headers, compare them with the C Headers (e.g. these from MinGW) and add all missing definitions/declarations - but I know, thats A LOT of work.
Note that it might also have license consequences. IIRC Wine and mingw's used to be cleanroomed, thus free from MS copyright, and usable for e.g. ReactOS. If you copy stuff from the SDK, you effectively subject the headers to MS copyright, which excludes use for non Windows platforms (ReactOS, Wine, winapi based dosextenders, certain OS/2 plugins).

This was played up very high with the initial mingw ports (when we also started off with the mingw headers, late nineties), but we've abandoned this as too hard/costly, and carry MS copyright messages now for all but one header.

I also don't know if the cleanroom argument was merely a purity thing or a real threat. Microsoft drummed up the holiness of the Windows platform/api pretty strong back then (probably wanted to avoid the multiple vendor DOS situation).
St_W
Posts: 1626
Joined: Feb 11, 2009 14:24
Location: Austria
Contact:

Re: Updating freebasic windows .bi

Post by St_W »

I don't know about the legal situation, but the code excerpt in my last post above was taken from MinGW's Win32 Headers, not from the original Microsoft Windows SDK. The defines/declarations mentioned are present in MinGW's Win32 Headers, but missing in FreeBasic's.
TJF
Posts: 3809
Joined: Dec 06, 2009 22:27
Location: N47°, E15°
Contact:

Re: Updating freebasic windows .bi

Post by TJF »

I inserted a lot of CONST keywords in my crt/ headers. Obviously SWIG doesn't support translation of this declaration type. There's still a lot of work to do in most headers, not only in windows.bi.
Post Reply