зеркало из https://github.com/mozilla/pjs.git
bug 673689 - fix some new places where nsIAccessibleRole::ROLE_FOO was added r=me
This commit is contained in:
Родитель
a393ef72bf
Коммит
3fcda57d51
|
@ -601,11 +601,9 @@ nsAccessible::VisibilityState()
|
||||||
do {
|
do {
|
||||||
// We don't want background tab page content to be aggressively invisible.
|
// We don't want background tab page content to be aggressively invisible.
|
||||||
// Otherwise this foils screen reader virtual buffer caches.
|
// Otherwise this foils screen reader virtual buffer caches.
|
||||||
PRUint32 role = accessible->Role();
|
roles::Role role = accessible->Role();
|
||||||
if (role == nsIAccessibleRole::ROLE_PROPERTYPAGE ||
|
if (role == roles::PROPERTYPAGE || role == roles::PANE)
|
||||||
role == nsIAccessibleRole::ROLE_PANE) {
|
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
|
|
||||||
nsIFrame* frame = accessible->GetFrame();
|
nsIFrame* frame = accessible->GetFrame();
|
||||||
if (!frame)
|
if (!frame)
|
||||||
|
|
|
@ -209,9 +209,9 @@ public:
|
||||||
*/
|
*/
|
||||||
inline void MaybeNotifyOfValueChange(nsAccessible* aAccessible)
|
inline void MaybeNotifyOfValueChange(nsAccessible* aAccessible)
|
||||||
{
|
{
|
||||||
PRUint32 role = aAccessible->Role();
|
mozilla::a11y::role role = aAccessible->Role();
|
||||||
if (role == nsIAccessibleRole::ROLE_ENTRY ||
|
if (role == mozilla::a11y::roles::ENTRY ||
|
||||||
role == nsIAccessibleRole::ROLE_COMBOBOX) {
|
role == mozilla::a11y::roles::COMBOBOX) {
|
||||||
nsRefPtr<AccEvent> valueChangeEvent =
|
nsRefPtr<AccEvent> valueChangeEvent =
|
||||||
new AccEvent(nsIAccessibleEvent::EVENT_VALUE_CHANGE, aAccessible,
|
new AccEvent(nsIAccessibleEvent::EVENT_VALUE_CHANGE, aAccessible,
|
||||||
eAutoDetect, AccEvent::eRemoveDupes);
|
eAutoDetect, AccEvent::eRemoveDupes);
|
||||||
|
|
|
@ -72,7 +72,7 @@
|
||||||
/**
|
/**
|
||||||
* The nsIAccessible role of our gecko accessible.
|
* The nsIAccessible role of our gecko accessible.
|
||||||
*/
|
*/
|
||||||
PRUint32 mRole;
|
mozilla::a11y::role mRole;
|
||||||
}
|
}
|
||||||
|
|
||||||
// inits with the gecko owner.
|
// inits with the gecko owner.
|
||||||
|
|
|
@ -254,8 +254,7 @@ GetLocalizedString(const nsString& aString)
|
||||||
if ([attribute isEqualToString:NSAccessibilityValueAttribute])
|
if ([attribute isEqualToString:NSAccessibilityValueAttribute])
|
||||||
return [self value];
|
return [self value];
|
||||||
if ([attribute isEqualToString:NSAccessibilityRoleDescriptionAttribute]) {
|
if ([attribute isEqualToString:NSAccessibilityRoleDescriptionAttribute]) {
|
||||||
if ((mRole == nsIAccessibleRole::ROLE_INTERNAL_FRAME)
|
if (mRole == roles::INTERNAL_FRAME || mRole == roles::DOCUMENT_FRAME)
|
||||||
|| (mRole == nsIAccessibleRole::ROLE_DOCUMENT_FRAME))
|
|
||||||
return GetLocalizedString(NS_LITERAL_STRING("htmlContent")) ? : @"HTML Content";
|
return GetLocalizedString(NS_LITERAL_STRING("htmlContent")) ? : @"HTML Content";
|
||||||
|
|
||||||
return NSAccessibilityRoleDescription([self role], nil);
|
return NSAccessibilityRoleDescription([self role], nil);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче