Skip to content

Commit

Permalink
Patch #42 Mapping of names to dispIDs implemented
Browse files Browse the repository at this point in the history
  • Loading branch information
clay_shooter committed Jun 22, 2015
1 parent bcd0f80 commit 205d20b
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 8 deletions.
13 changes: 7 additions & 6 deletions jacob/docs/BuildingJacobFromSource.html
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,11 @@ <H1>Development Environment</h1>
In that situation, you would just create the <i>compilation_tools.properties</i>
using the example at the top of build.xml as a template.
<UL>
<li> Microsoft Visual Studio 10.0 and it's included library. (to C:\ProgramFiles (X86) in my case)
<li> Eclipse 3.4 or later from www.eclipse.org as the Java IDE.
<li> Eclipse 3.4 or later with the C/C++ plugin can be used for C coding in place of VC++ IDE.
<li> Java JDK 1.6 (1.18 was built using 1.7.0_31)
<li> Microsoft Visual Studio 2013 and it's included library. (to C:\ProgramFiles (X86) in my case)
<li> Eclipse from www.eclipse.org as the Java IDE.
<li> Eclipse C/C++ plugin can be used for C coding in place of VC++ IDE.
<li> Java JDK 1.6 , latest available
<li> Install the V7.1A libraries that originally came with VS2010
</ul>
<p>
<p>
Expand All @@ -58,10 +59,10 @@ <H1>Development Environment</h1>
<TR><TD>1.14</TD><TD>VC 2005 (8)</TD><TD>1.5.0 (49)</TD><TD>1.7.0</TD><TD>3.3</TD><TD>32 and 64 bit</TD></TR>
<TR><TD>1.15</TD><TD>VC 2005 (8)</TD><TD>1.5.0 (49)</TD><TD>1.7.0</TD><TD>3.4</TD><TD>32 and 64 bit</TD></TR>
<TR><TD>1.17</TD><TD>VC 2005 (8)</TD><TD>1.5.0 (49)</TD><TD>1.8.4 Eclipse Embedded</TD><TD>4.3</TD><TD>32 and 64 bit</TD></TR>
<TR><TD>1.18</TD><TD>VS 2010 (10) Windows SDK VS2010 (7.0A)</TD><TD>1.6.0 (50)</TD><TD>1.8.4 Eclipse Embedded</TD><TD>4.3</TD><TD>32 and 64 bit</TD></TR>
<TR><TD>1.18</TD><TD>VS 2013 (12) Windows SDK 7.1A</TD><TD>1.6.0 (50)</TD><TD>1.8.4 Eclipse Embedded</TD><TD>4.3</TD><TD>32 and 64 bit</TD></TR>

</table>
Microsoft Visual Studio 10 supports 64 bit builds. so no additional tools are required.<BR>
Microsoft Visual Studio 13 supports 64 bit builds. so no additional tools are required.<BR>
Microsoft changed the location of the windows sdk (formerly known as platform sdk) after VC 8.0. https://en.wikipedia.org/wiki/Microsoft_Windows_SDK

<p>
Expand Down
16 changes: 15 additions & 1 deletion jacob/docs/ReleaseNotes.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,35 @@ <h2>JACOB 1.18</h2>
<h3>What's New</h3>
<ul>
<li>
Built with Java 1.6 and Visual Studio 2010
(M2) Built with Java 1.6 and Visual Studio 2013 Microsoft Platform SDK V7.1A (introduced with VS2012)instead of v7.0A (vs2010)
Targeting SDK V7.1 with USING_V110_SDK71" http://en.wikipedia.org/wiki/Microsoft_Windows_SDK
</li><li>
(M2) Temporarily using AMD64 compiler instead of x86_amd64 because of installation issues on dev machine.
Should generate same output even though dll files are different sizes between M1 and M2. http://msdn.microsoft.com/en-us/library/x4d2c09s.aspx
</li><li>
(M2) Dropped support for XP
</li>
</ul>
<h3>Tracked Changes</h3>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" >
<tr>
<td colspan="2"><b>Bugs</b></td>
</tr>
<tr>
<td width="13%" valign="top">119 (new numbers)</td>
<td width="87%" valign="top"> Attribute lacking in MANIFEST.MF required since Java 1.7u45</td>
</tr>
<tr>
<td width="13%" valign="top">&nbsp;</td>
<td width="87%" valign="top">&nbsp;</td>
</tr>
<tr>
<td colspan="2"><b>Patches</b></td>
</tr>
<tr>
<td width="13%" valign="top">42 (new numbers)</td>
<td width="87%" valign="top"> Mapping of names to dispIDs implemented</td>
</tr>
<tr>
<td width="13%" valign="top">&nbsp;</td>
<td width="87%" valign="top">&nbsp;</td>
Expand Down
22 changes: 21 additions & 1 deletion jacob/jni/EventProxy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,30 @@ STDMETHODIMP EventProxy::QueryInterface(REFIID rid, void **ppv)

// This should never get called - the event source fires events
// by dispid's, not by name
// But however sometimes it is called, so do the mapping as defined
// by the API Patch #42 provided by abp-futura
STDMETHODIMP EventProxy::GetIDsOfNames(REFIID riid,
OLECHAR **rgszNames, UINT cNames, LCID lcid, DISPID *rgDispID)
{
return E_UNEXPECTED;
HRESULT result = S_OK;
for (UINT n = 0; n < cNames; n++) {
rgDispID[n] = DISPID_UNKNOWN;
USES_CONVERSION;
const char *current = W2A((OLECHAR *) rgszNames[n]);
// map name to dispID
for(int i=0; i<MethNum; i++)
{
const char *found = W2A((OLECHAR *) MethName[i]);
if (strcmp(current, found) == 0) {
rgDispID[n] = MethID[i];
}
}
if (rgDispID[n] == DISPID_UNKNOWN) {
result = DISP_E_UNKNOWNNAME;
}
}

return result;
}

// The actual callback from the connection point arrives here
Expand Down

0 comments on commit 205d20b

Please sign in to comment.