From 24c870cfd6c316e9df7cc532c6501a82428e032a Mon Sep 17 00:00:00 2001 From: "aaronleventhal%moonset.net" Date: Mon, 17 Jul 2006 17:12:11 +0000 Subject: [PATCH] Fixing more bustage --- accessible/src/atk/nsAccessibleWrap.h | 17 +++++++++++++++++ accessible/src/atk/nsRoleMap.h | 20 ++++++++++++++++++++ 2 files changed, 37 insertions(+) diff --git a/accessible/src/atk/nsAccessibleWrap.h b/accessible/src/atk/nsAccessibleWrap.h index c2194e4dc967..f467bbed64c4 100644 --- a/accessible/src/atk/nsAccessibleWrap.h +++ b/accessible/src/atk/nsAccessibleWrap.h @@ -51,6 +51,23 @@ #define MAI_LOGGING #endif /* #ifdef PR_LOGGING */ +// ATK 1.1.1 or later +#if ATK_MAJOR_VERSION >=2 || \ + (ATK_MAJOR_VERSION == 1 && ATK_MINOR_VERSION >= 2) || \ + (ATK_MAJOR_VERSION == 1 && ATK_MINOR_VERSION == 1 && ATK_REV_VERSION >=1) +#define USE_ATK_ROLE_PARAGRAPH +#define USE_ATK_ROLE_HEADER +#define USE_ATK_ROLE_FOOTER +#define USE_ATK_ROLE_RULER +#endif + +// ATK 1.1.3 or later +#if ATK_MAJOR_VERSION >=2 || \ + (ATK_MAJOR_VERSION == 1 && ATK_MINOR_VERSION >= 2) || \ + (ATK_MAJOR_VERSION == 1 && ATK_MINOR_VERSION == 1 && ATK_REV_VERSION >=3) +#define USE_ATK_ROLE_APPLICATION +#endif + // ATK 1.3.3 or later #if ATK_MAJOR_VERSION >=2 || \ (ATK_MAJOR_VERSION == 1 && ATK_MINOR_VERSION >= 4) || \ diff --git a/accessible/src/atk/nsRoleMap.h b/accessible/src/atk/nsRoleMap.h index 00fe4db6ed8b..ecd714fe2191 100644 --- a/accessible/src/atk/nsRoleMap.h +++ b/accessible/src/atk/nsRoleMap.h @@ -60,7 +60,11 @@ PRUint32 atkRoleMap[] = { ATK_ROLE_MENU, // nsIAccessible::ROLE_MENUPOPUP 11 ATK_ROLE_MENU_ITEM, // nsIAccessible::ROLE_MENUITEM 12 ATK_ROLE_TOOL_TIP, // nsIAccessible::ROLE_TOOLTIP 13 +#ifdef USE_ATK_ROLE_APPLICATION ATK_ROLE_APPLICATION, // nsIAccessible::ROLE_APPLICATION 14 +#else + ATK_ROLE_PANEL, // nsIAccessible::ROLE_APPLICATION 14 +#endif #ifdef USE_ATK_ROLE_DOCUMENT_FRAME ATK_ROLE_DOCUMENT_FRAME, // nsIAccessible::ROLE_DOCUMENT 15 #else @@ -156,10 +160,26 @@ PRUint32 atkRoleMap[] = { ATK_ROLE_TOGGLE_BUTTON, // nsIAccessible::ROLE_TOGGLE_BUTTON 95 ATK_ROLE_TREE_TABLE, // nsIAccessible::ROLE_TREE_TABLE 96 ATK_ROLE_VIEWPORT, // nsIAccessible::ROLE_VIEWPORT 97 +#ifdef USE_ATK_ROLE_HEADER ATK_ROLE_HEADER, // nsIAccessible::ROLE_HEADER 98 +#else + ATK_ROLE_TEXT, // nsIAccessible::ROLE_HEADER 98 +#endif +#ifdef USE_ATK_ROLE_FOOTER ATK_ROLE_FOOTER, // nsIAccessible::ROLE_FOOTER 99 +#else + ATK_ROLE_TEXT, // nsIAccessible::ROLE_FOOTER 99 +#endif +#ifdef USE_ATK_ROLE_PARAGRAPH ATK_ROLE_PARAGRAPH, // nsIAccessible::ROLE_PARAGRAPH 100 +#else + ATK_ROLE_TEXT, // nsIAccessible::ROLE_PARAGRAPH 100 +#endif +#ifdef USE_ATK_ROLE_RULER ATK_ROLE_RULER, // nsIAccessible::ROLE_RULER 101 +#else + ATK_ROLE_UNKNOWN, // nsIAccessible::ROLE_RULER 101 +#endif #ifdef USE_ATK_ROLE_AUTOCOMPLETE ATK_ROLE_AUTOCOMPLETE, // nsIAccessible::ROLE_AUTOCOMPLETE 102 #else