Use symbolic constants rather than numeric values
Zero represents 'this' object which is identified by wxACC_SELF symbol.
This commit is contained in:
@@ -3662,7 +3662,7 @@ wxAccStatus wxWindowAccessible::GetLocation(wxRect& rect, int elementId)
|
|||||||
wxCHECK( GetWindow() != NULL, wxACC_FAIL );
|
wxCHECK( GetWindow() != NULL, wxACC_FAIL );
|
||||||
|
|
||||||
wxWindow* win = NULL;
|
wxWindow* win = NULL;
|
||||||
if (elementId == 0)
|
if (elementId == wxACC_SELF)
|
||||||
{
|
{
|
||||||
win = GetWindow();
|
win = GetWindow();
|
||||||
}
|
}
|
||||||
@@ -3718,7 +3718,7 @@ wxAccStatus wxWindowAccessible::Navigate(wxNavDir navDir, int fromId,
|
|||||||
{
|
{
|
||||||
wxWindowList::compatibility_iterator node =
|
wxWindowList::compatibility_iterator node =
|
||||||
wxWindowList::compatibility_iterator();
|
wxWindowList::compatibility_iterator();
|
||||||
if (fromId == 0)
|
if (fromId == wxACC_SELF)
|
||||||
{
|
{
|
||||||
// Can't navigate to sibling of this window
|
// Can't navigate to sibling of this window
|
||||||
// if we're a top-level window.
|
// if we're a top-level window.
|
||||||
@@ -3748,7 +3748,7 @@ wxAccStatus wxWindowAccessible::Navigate(wxNavDir navDir, int fromId,
|
|||||||
{
|
{
|
||||||
wxWindowList::compatibility_iterator node =
|
wxWindowList::compatibility_iterator node =
|
||||||
wxWindowList::compatibility_iterator();
|
wxWindowList::compatibility_iterator();
|
||||||
if (fromId == 0)
|
if (fromId == wxACC_SELF)
|
||||||
{
|
{
|
||||||
// Can't navigate to sibling of this window
|
// Can't navigate to sibling of this window
|
||||||
// if we're a top-level window.
|
// if we're a top-level window.
|
||||||
@@ -3825,7 +3825,7 @@ wxAccStatus wxWindowAccessible::GetChild(int childId, wxAccessible** child)
|
|||||||
{
|
{
|
||||||
wxCHECK( GetWindow() != NULL, wxACC_FAIL );
|
wxCHECK( GetWindow() != NULL, wxACC_FAIL );
|
||||||
|
|
||||||
if (childId == 0)
|
if (childId == wxACC_SELF)
|
||||||
{
|
{
|
||||||
*child = this;
|
*child = this;
|
||||||
return wxACC_OK;
|
return wxACC_OK;
|
||||||
|
Reference in New Issue
Block a user