Even more accessibility debugging.

This commit is contained in:
Pietro Gagliardi 2014-12-25 15:56:06 -05:00
parent 3e2275af43
commit 7487dbb27c
1 changed files with 9 additions and 4 deletions

View File

@ -27,16 +27,19 @@ static HRESULT STDMETHODCALLTYPE tableAccQueryInterface(IAccessible *this, REFII
static ULONG STDMETHODCALLTYPE tableAccAddRef(IAccessible *this)
{
printf("AddRef()\n");
TA->refcount++;
// TODO correct?
return TA->refcount;
}
static ULONG STDMETHODCALLTYPE tableAccRelease(IAccessible *this)
{
printf("refcount %d\n", TA->refcount);
printf("Release(): refcount %d\n", TA->refcount);
TA->refcount--;
if (TA->refcount == 0) {
tableFree(TA, "error freeing Table accessibility object");
printf("FREEING\n");
//TODO tableFree(TA, "error freeing Table accessibility object");
return 0;
}
return TA->refcount;
@ -251,7 +254,9 @@ static struct tableAcc *newTableAcc(struct table *t)
ta = (struct tableAcc *) tableAlloc(sizeof (struct tableAcc), "error creating Table accessibility object");
ta->vtbl = &tableAccVtbl;
printf("create: %d -> ", ta->refcount);
ta->vtbl->AddRef(ta);
printf("%d\n", ta->refcount);
ta->t = t;
return ta;
}
@ -268,9 +273,9 @@ HANDLER(accessibilityHandler)
return FALSE;
if (((DWORD) lParam) != OBJID_CLIENT)
return FALSE;
printf("getobject\n");
printf("before LresultFromObject()\n");
*lResult = LresultFromObject(&IID_IAccessible, wParam, t->ta);
printf("0x%X\n", *lResult);
printf("after LresultFromObject(): 0x%X\n", *lResult);
// TODO check *lResult
return TRUE;
}