bug 659620 - Hang when trying to edit a page on WikiMo with NVDA running r=surkov

From e0a6515b9f894ab39bcd6db51d43e24a677667b3 Mon Sep 17 00:00:00 2001
---
 accessible/src/base/nsBaseWidgetAccessible.cpp     |    3 +-
 .../tests/mochitest/actions/test_general.html      |   21 ++++++++++++++++++++
 2 files changed, 22 insertions(+), 2 deletions(-)
This commit is contained in:
Trevor Saunders 2011-05-25 07:52:01 -07:00
Родитель 06f52112ce
Коммит 50f1ab05f3
2 изменённых файлов: 22 добавлений и 2 удалений

Просмотреть файл

@ -141,7 +141,7 @@ nsLinkableAccessible::GetNumActions(PRUint8 *aNumActions)
{
NS_ENSURE_ARG_POINTER(aNumActions);
*aNumActions = mActionAcc ? 1 : 0;
*aNumActions = (mIsOnclick || mIsLink) ? 1 : 0;
return NS_OK;
}
@ -228,7 +228,6 @@ nsLinkableAccessible::BindToParent(nsAccessible* aParent,
mIsOnclick = PR_FALSE;
if (nsCoreUtils::HasClickListener(mContent)) {
mActionAcc = this;
mIsOnclick = PR_TRUE;
return;
}

Просмотреть файл

@ -36,9 +36,19 @@
ID: "li_clickable3",
actionName: "click",
events: CLICK_EVENTS
},
{
ID: "onclick_img",
actionName: "click",
events: CLICK_EVENTS
}
];
testActions(actionsArray);
getAccessible("onclick_img").takeFocus();
is(getAccessible("link1").numActions, 1, "links should have one action");
is(getAccessible("link2").numActions, 1, "link with onclick handler should have 1 action");
}
SimpleTest.waitForExplicitFinish();
@ -58,6 +68,11 @@
title="Expose click action if mouseup and mousedown are registered">
Mozilla Bug 423409
</a>
<a target="_blank"
href="https://bugzilla.mozilla.org/show_bug.cgi?id=659620"
title="hang when trying to edit a page on wikimo with NVDA running">
Mozilla Bug 659620
</a>
<p id="display"></p>
<div id="content" style="display: none"></div>
<pre id="test">
@ -68,5 +83,11 @@
<li id="li_clickable2" onmousedown="">Clickable list item</li>
<li id="li_clickable3" onmouseup="">Clickable list item</li>
</ul>
<!-- linkable accessibles -->
<img id="onclick_img" onclick="" src="../moz.png">
<a id="link1" href="www">linkable textleaf accessible</a>
<div id="link2" onclick="">linkable textleaf accessible</div>
</body>
</html>