NO

Author Topic: STDMETHODIMP_(ULONG) breaks the function browser  (Read 1248 times)

Offline algernon_77

  • Member
  • *
  • Posts: 33
STDMETHODIMP_(ULONG) breaks the function browser
« on: August 16, 2020, 11:24:09 AM »
Hello!

Today I was tinkering with a Shell context menu example from the forum and I noticed that STDMETHODIMP_(ULONG) seems to break the function browser.
Replaced it with ULONG STDMETHODCALLTYPE and all is peachy. I'm on W7 x64 with Pelle 10.
Example below:

Code: [Select]
STDMETHODIMP_(ULONG) CClassFactory_AddRef ( IClassFactory *this )
{
    ClassFactoryStruct * pCF = (ClassFactoryStruct*)this;
    return ++pCF->m_ulRef;
}

STDMETHODIMP_(ULONG) CClassFactory_Release ( IClassFactory *this )
{
    ClassFactoryStruct * pCF = (ClassFactoryStruct*)this;
    if ( --pCF->m_ulRef == 0 )
    {
        free(this);
        --g_uiRefThisDll;
        return 0;
    }
    return pCF->m_ulRef;
}

Regards!

Offline Pelle

  • Administrator
  • Member
  • *****
  • Posts: 2266
    • http://www.smorgasbordet.com
Re: STDMETHODIMP_(ULONG) breaks the function browser
« Reply #1 on: August 23, 2020, 09:22:42 PM »
I will look at this when I have some more time...
/Pelle