summaryrefslogtreecommitdiffstats
path: root/content/browser/accessibility/browser_accessibility_manager_win.cc
Commit message (Collapse)AuthorAgeFilesLines
* Get rid of FrameAccessibility using AXTreeIDsdmazzoni2015-08-071-21/+25
| | | | | | | | | | | | | | | | | | Depends on: https://codereview.chromium.org/1257093005/ Instead of keeping track of the relationship between frames in FrameAccessibility, create a subclass of AXNodeData that's only allowed to be used within the content module, and once an AX tree is received in the browser process, convert routing IDs to global AXTreeIDs that can be stored AXNodeData. BUG=368298 Review URL: https://codereview.chromium.org/1267663002 Cr-Commit-Position: refs/heads/master@{#342251}
* Templatize some ui/accessibility code to enable subclassing AXNodeData.dmazzoni2015-08-041-4/+5
| | | | | | | | | | | A follow-up change will create a subclass of AXNodeData with some extra fields that only make sense within the content module. BUG=368298 Review URL: https://codereview.chromium.org/1257093005 Cr-Commit-Position: refs/heads/master@{#341793}
* Prevent OnWindowFocused from being called recursively.dmazzoni2015-07-291-2/+11
| | | | | | | | BUG=515073 Review URL: https://codereview.chromium.org/1262233004 Cr-Commit-Position: refs/heads/master@{#341019}
* Tolerate GetRoot() returning null.dmazzoni2015-07-281-2/+6
| | | | | | | | | | | When inside one of the AXTreeDelegate callbacks, GetRoot() might return null, we need to handle that case. BUG=514609 Review URL: https://codereview.chromium.org/1261073003 Cr-Commit-Position: refs/heads/master@{#340773}
* Pass the affected tree in AXTreeDelegate calls.dmazzoni2015-06-021-27/+31
| | | | | | | | | | | This will be used in a forthcoming change that uses AXTree in the automation extension process. BUG=495323 Review URL: https://codereview.chromium.org/1162223008 Cr-Commit-Position: refs/heads/master@{#332491}
* Fix menu list and list box screen reader accessibility.dmazzoni2015-04-241-6/+0
| | | | | | | | | | | | | | | | | | | The most important change here is getting rid of code in renderer_accessibility.cc that recreated the subtree whenever AXSelectedChildrenChanged was fired. This is no longer necessary because Blink now fires the right events on each individual option in a menu list or list box. The rest of the changes just make sure the exact attributes and events match the spec and match what Firefox and Safari do when interacting with these elements, including adding some good tests for those. BUG=323462 Review URL: https://codereview.chromium.org/1057083002 Cr-Commit-Position: refs/heads/master@{#326755}
* accessibility: Simpler AXTree root accessor.tfarina2015-02-201-1/+1
| | | | | | | | | | | | | | - It does not need to be virtual. - Since it is a simple getter accessor it can be inlined in the header file and thus renamed to just root(). BUG=None R=dmazzoni@chromium.org,avi@chromium.org TBR=dtseng@chromium.org Review URL: https://codereview.chromium.org/940753002 Cr-Commit-Position: refs/heads/master@{#317444}
* include vector headermostynb2015-02-121-0/+2
| | | | | | | | | | Drive-by fixup for https://codereview.chromium.org/799633007 BUG=368298 Review URL: https://codereview.chromium.org/889603008 Cr-Commit-Position: refs/heads/master@{#315994}
* Suppress accessibility events when user is navigating away.dmazzoni2015-02-081-0/+9
| | | | | | | | | | | | | | When the user navigates to a new page, stop sending accessibility events on the old page. BUG=421116,450409 Committed: https://crrev.com/6ce40a1e561892849c1f6ac070dda140f6cc0115 Cr-Commit-Position: refs/heads/master@{#314812} Review URL: https://codereview.chromium.org/830053004 Cr-Commit-Position: refs/heads/master@{#315231}
* Revert of Suppress accessibility events when user is navigating away. ↵kelvinp2015-02-051-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (patchset #6 id:100001 of https://codereview.chromium.org/830053004/) Reason for revert: NavigationAccessibilityTest.TestNavigateToNewUrl is failing on Win7 Tests (dbg)(1). Sample failure: http://build.chromium.org/p/chromium.win/builders/Win7%20Tests%20%28dbg%29%281%29/builds/35087 Original issue's description: > Suppress accessibility events when user is navigating away. > > When the user navigates to a new page, stop sending accessibility > events on the old page. > > BUG=421116,450409 > > Committed: https://crrev.com/6ce40a1e561892849c1f6ac070dda140f6cc0115 > Cr-Commit-Position: refs/heads/master@{#314812} TBR=nasko@chromium.org,dmazzoni@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=421116,450409 Review URL: https://codereview.chromium.org/892513004 Cr-Commit-Position: refs/heads/master@{#314884}
* Suppress accessibility events when user is navigating away.dmazzoni2015-02-051-0/+9
| | | | | | | | | | | When the user navigates to a new page, stop sending accessibility events on the old page. BUG=421116,450409 Review URL: https://codereview.chromium.org/830053004 Cr-Commit-Position: refs/heads/master@{#314812}
* Fire AX text inserted event when embedded obj char changes.dmazzoni2015-02-031-9/+31
| | | | | | | | | | | | | | | | See bug for details. This patch makes it so that we fire the events IA2_EVENT_TEXT_INSERTED and IA2_EVENT_TEXT_REMOVED when the children referenced by the embedded object characters changed, not just when the text changed. This patch also avoids incorrectly firing these same two events on a newly-created node. BUG=425861 Review URL: https://codereview.chromium.org/859133003 Cr-Commit-Position: refs/heads/master@{#314280}
* Add more logging to debug DumpAccessibilityEvent* test failuresdmazzoni2015-01-291-3/+12
| | | | | | | | | BUG=440579 TBR=thakis Review URL: https://codereview.chromium.org/867483008 Cr-Commit-Position: refs/heads/master@{#313753}
* Re-land: Send Windows accessibility events based on tree updates.dmazzoni2015-01-271-28/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The idea of this change is to fire Win AX events based on the AX tree changing, rather than based on Blink firing the right event and mapping it to a Win event. Store the Win-specific AX attributes (ia role, ia state, name, value, etc.) in a struct, and when a node is updated, compare the old value of each attribute to the new value and fire an appropriate event for each one (name changed, state changed, etc.). Handle hypertext_ similarly, and properly diff the old and new hypertext in get_oldText and get_newText. This enables all of the "event" tests that were previously added to pass now, and it makes live regions work correctly in NVDA and JAWS. BUG=447962 Committed: https://crrev.com/eb691a960bef3c2aefa38627baa7cbdde480b81e Cr-Commit-Position: refs/heads/master@{#313052} Review URL: https://codereview.chromium.org/848653002 Cr-Commit-Position: refs/heads/master@{#313179}
* Revert of Send Windows accessibility events based on tree updates. (patchset ↵pauljensen2015-01-261-64/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | #9 id:160001 of https://codereview.chromium.org/848653002/) Reason for revert: DumpAccessibilityEventsTest.AccessibilityEventsTextChanged failing frequently on Windows bots. Fails most of the time on Win8 Aura. Original issue's description: > Send Windows accessibility events based on tree updates. > > The idea of this change is to fire Win AX events > based on the AX tree changing, rather than based > on Blink firing the right event and mapping it to a > Win event. > > Store the Win-specific AX attributes (ia role, > ia state, name, value, etc.) in a struct, and when a > node is updated, compare the old value of each attribute > to the new value and fire an appropriate event for each > one (name changed, state changed, etc.). > > Handle hypertext_ similarly, and properly diff the old and new hypertext in get_oldText and get_newText. > > This enables all of the "event" tests that were > previously added to pass now, and it makes live regions > work correctly in NVDA and JAWS. > > BUG=447962 > > Committed: https://crrev.com/eb691a960bef3c2aefa38627baa7cbdde480b81e > Cr-Commit-Position: refs/heads/master@{#313052} TBR=dtseng@chromium.org,aboxhall@chromium.org,dmazzoni@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=447962 Review URL: https://codereview.chromium.org/880523002 Cr-Commit-Position: refs/heads/master@{#313067}
* Send Windows accessibility events based on tree updates.dmazzoni2015-01-261-28/+64
| | | | | | | | | | | | | | | | | | | | | | | | | The idea of this change is to fire Win AX events based on the AX tree changing, rather than based on Blink firing the right event and mapping it to a Win event. Store the Win-specific AX attributes (ia role, ia state, name, value, etc.) in a struct, and when a node is updated, compare the old value of each attribute to the new value and fire an appropriate event for each one (name changed, state changed, etc.). Handle hypertext_ similarly, and properly diff the old and new hypertext in get_oldText and get_newText. This enables all of the "event" tests that were previously added to pass now, and it makes live regions work correctly in NVDA and JAWS. BUG=447962 Review URL: https://codereview.chromium.org/848653002 Cr-Commit-Position: refs/heads/master@{#313052}
* Improve the notifications sent from AXTree updates.dmazzoni2015-01-241-4/+10
| | | | | | | | | | | | These notifications will be useful in order to fire the right Windows accessibility events for certain tree changes, but this patch just adds the notifications and refactors existing code to use them. BUG=447962 Review URL: https://codereview.chromium.org/830943004 Cr-Commit-Position: refs/heads/master@{#312973}
* Make Windows accessibility event firing aware of guest / child frames.dmazzoni2015-01-191-5/+22
| | | | | | | | | | | | | | | | | | Windows-specific fixes for accessibility of out-of-process iframes and guest frames (e.g. <webview>): 1. When firing an event or doing a bounds calculation, we need to call functions on the root BrowserAccessibilityManager's delegate (not on the child frame's delegate). 2. When a MSAA client tries to look up an MSAA object by child ID, we need to search child frames as well. BUG=330307, 368298 Review URL: https://codereview.chromium.org/799633007 Cr-Commit-Position: refs/heads/master@{#312080}
* Initialize initial AX tree after BrowserAccessibilityManagerWin.dmazzoni2014-10-071-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | This was a subtle bug - the initial AX tree was being initialized in the BrowserAccessibilityManager constructor, before the subclass, BrowserAccessibilityManagerWin, was constructed. That meant that BrowserAccessibilityManagerWin overrides were not being called, so the native Win objects for the initial tree were not working. In particular, BrowserAccessibilityManagerWin::OnNodeCreated wasn't getting called, so the mapping from Windows unique ids to objects wasn't getting initialized. The user impact of this is that when loading a new URL, NVDA would sometimes announce "Unknown" - this is because it'd get events on the initial document (before the real page loads), but attempts to query that initial document would fail. Adds a unit test to demonstrate exactly what failed and prevent it from regressing. BUG=421116 Review URL: https://codereview.chromium.org/631223005 Cr-Commit-Position: refs/heads/master@{#298573}
* Simplify access to LegacyRenderWidgetHostHWND.dmazzoni@chromium.org2014-07-261-52/+18
| | | | | | | | | | | | | | | | | | | | | Instead of giving BrowserAccessibilityManagerWin a pointer to a LegacyRenderWidgetHostHWND, which has been a source of problems due to complicated lifecycles, just have BAMW request the parent HWND and parent IAccessible from its delegate whenever needed, with the understanding that these may be NULL sometimes. Note: this change fixes a DrMemory UAF detected in the patch that migrated accessibility from RVH to RFH (codereview.chromium.org/273423004), and also fixes a potential concern in another fix to LegacyRenderWidgetHostHWND (codereview.chromium.org/387353004). BUG=368298,393665 Review URL: https://codereview.chromium.org/415633002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@285818 0039d316-1c4b-4281-b951-d872f2087c98
* Migrate accessibility from RenderView to RenderFrame and RVH to RFH.dmazzoni@chromium.org2014-07-261-1/+5
| | | | | | | | | | | | | | | | In preparation for out-of-process iframes, move almost all accessibility functionality from RenderView to RenderFrame, and from RVHI and RWHI to RFHI. In addition, the accessibility mode is moved to WebContents, and changing the mode triggers changing it on all frames. BUG=368298 R=jam@chromium.org, kenrb@chromium.org, nick@chromium.org Review URL: https://codereview.chromium.org/273423004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@285767 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 284065 "Revert of Revert of Migrate accessibility from Re..."bruening@google.com2014-07-211-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reason for revert: Use-after-free raised on MFYI waterfall. BUG=395670 > Revert of Revert of Migrate accessibility from RenderView to RenderFrame. (https://codereview.chromium.org/407493002/) > > Reason for revert: > Reverting the revert. This didn't break the tree; it's still broken without the patch. :( > > Sorry for the noise! > > Original issue's description: > > Revert of Migrate accessibility from RenderView to RenderFrame. (https://codereview.chromium.org/273423004/) > > > > Reason for revert: > > Speculative revert to fix XP bots. > > > > XP bots started crashing http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/32011 and http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%282%29/builds/34677 > > > > This CL is the most suspicious in the range. If it doesn't fix the bots, I'll unrevert it. > > > > Original issue's description: > > > Migrate accessibility from RenderView to RenderFrame and RVH to RFH. > > > > > > In preparation for out-of-process iframes, move almost all accessibility > > > functionality from RenderView to RenderFrame, and from RVHI and RWHI > > > to RFHI. > > > > > > In addition, the accessibility mode is moved to WebContents, and changing > > > the mode triggers changing it on all frames. > > > > > > BUG=368298 > > > R=jam@chromium.org, kenrb@chromium.org, nick@chromium.org > > > > > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=283994 > > > > TBR=dmazzoni@chromium.org > > NOTRY=true > > > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=284032 > > TBR=creis@chromium.org,nick@chromium.org,nasko@chromium.org,jam@chromium.org,dtseng@chromium.org,jschuh@chromium.org,tsepez@chromium.org,kenrb@chromium.org,dmazzoni@chromium.org > NOTREECHECKS=true > NOTRY=true > > Review URL: https://codereview.chromium.org/407493004 TBR=mkwst@chromium.org Review URL: https://codereview.chromium.org/408663006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284470 0039d316-1c4b-4281-b951-d872f2087c98
* Revert of Revert of Migrate accessibility from RenderView to RenderFrame. ↵mkwst@chromium.org2014-07-181-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/407493002/) Reason for revert: Reverting the revert. This didn't break the tree; it's still broken without the patch. :( Sorry for the noise! Original issue's description: > Revert of Migrate accessibility from RenderView to RenderFrame. (https://codereview.chromium.org/273423004/) > > Reason for revert: > Speculative revert to fix XP bots. > > XP bots started crashing http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/32011 and http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%282%29/builds/34677 > > This CL is the most suspicious in the range. If it doesn't fix the bots, I'll unrevert it. > > Original issue's description: > > Migrate accessibility from RenderView to RenderFrame and RVH to RFH. > > > > In preparation for out-of-process iframes, move almost all accessibility > > functionality from RenderView to RenderFrame, and from RVHI and RWHI > > to RFHI. > > > > In addition, the accessibility mode is moved to WebContents, and changing > > the mode triggers changing it on all frames. > > > > BUG=368298 > > R=jam@chromium.org, kenrb@chromium.org, nick@chromium.org > > > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=283994 > > TBR=dmazzoni@chromium.org > NOTRY=true > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=284032 TBR=creis@chromium.org,nick@chromium.org,nasko@chromium.org,jam@chromium.org,dtseng@chromium.org,jschuh@chromium.org,tsepez@chromium.org,kenrb@chromium.org,dmazzoni@chromium.org NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/407493004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284065 0039d316-1c4b-4281-b951-d872f2087c98
* Revert of Migrate accessibility from RenderView to RenderFrame. ↵mkwst@chromium.org2014-07-181-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/273423004/) Reason for revert: Speculative revert to fix XP bots. XP bots started crashing http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/32011 and http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%282%29/builds/34677 This CL is the most suspicious in the range. If it doesn't fix the bots, I'll unrevert it. Original issue's description: > Migrate accessibility from RenderView to RenderFrame and RVH to RFH. > > In preparation for out-of-process iframes, move almost all accessibility > functionality from RenderView to RenderFrame, and from RVHI and RWHI > to RFHI. > > In addition, the accessibility mode is moved to WebContents, and changing > the mode triggers changing it on all frames. > > BUG=368298 > R=jam@chromium.org, kenrb@chromium.org, nick@chromium.org > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=283994 TBR=dmazzoni@chromium.org NOTRY=true Review URL: https://codereview.chromium.org/407493002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284032 0039d316-1c4b-4281-b951-d872f2087c98
* Migrate accessibility from RenderView to RenderFrame and RVH to RFH.dmazzoni@chromium.org2014-07-181-1/+5
| | | | | | | | | | | | | | | | In preparation for out-of-process iframes, move almost all accessibility functionality from RenderView to RenderFrame, and from RVHI and RWHI to RFHI. In addition, the accessibility mode is moved to WebContents, and changing the mode triggers changing it on all frames. BUG=368298 R=jam@chromium.org, kenrb@chromium.org, nick@chromium.org Review URL: https://codereview.chromium.org/273423004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283994 0039d316-1c4b-4281-b951-d872f2087c98
* Implement accessible states and notifications for the tab strip.dmazzoni@chromium.org2014-07-101-8/+2
| | | | | | | | | | | | | | | | | | | This change just exposes information about what tabs are selected and fires proper notifications when tab selection changes. This will allow screen readers to announce when switching tabs even if the web content doesn't have focus. It's also a good first step towards making the tab strip fully accessible too (e.g. making it possible to perform operations on multiple tabs with just the keyboard). As part of this change I renamed the "selection changed" event to "text selection changed" so that there's no confusion between the text-selection-related events, and tab/list selection events. BUG=100412 Review URL: https://codereview.chromium.org/349033010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282396 0039d316-1c4b-4281-b951-d872f2087c98
* Don't send accessibility notifications on wrong HWND.dmazzoni@chromium.org2014-07-011-0/+10
| | | | | | | | | | | | | | | | | | | In r276950 (cl 329053004), we made it so that a BrowserAccessibilityManagerWin can be created without a LegacyRenderWidgetHostHWND, to fix a race condition. However, we should suppress all notifications from firing until the LegacyRenderWidgetHostHWND is ready because they'd just go to the wrong HWND. As soon as the LegacyRenderWidgetHostHWND is passed in, we'll fire a focus event on the root and all events from then on will be fine. BUG=368549 Review URL: https://codereview.chromium.org/359063004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280702 0039d316-1c4b-4281-b951-d872f2087c98
* Updated the WindowEventTarget interface in ui\base to return a bool from all ↵ananta@chromium.org2014-06-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | its methods which indicates whether the message was handled. This is to ensure that the default handling on the Windows message is performed by the caller (LegacyRenderWidgetHostHWND). Most of the changes in this patch are around passing a bool flag to the methods in the WindowEventTarget interface and passing that information from the LegacyRenderWidgetHostHWND to the message crackers in ATL. The changes apart from those are as below:- 1. Added a handler for WM_SYSCOMMAND in the LegacyRenderWidgetHostHWND class. This forwards the message to the parent. This is needed because there are cases when the LegacyRenderWidgetHostHWND class is of the same size as the parent. For e.g. App windows etc. In these cases the LegacyRenderWidgetHostHWND window receives non client mouse messages which when defproced result in the WM_SYSCOMMAND message coming in. 2. There are cases when the LegacyRenderWidgetHostHWND is created after the parent is made visible and the associated RenderWidget is visible. Added code to make the LegacyRenderWidgetHostHWND hwnd visible. 3. Added a Destroy method to the LegacyRenderWidgetHostHWND class. This method destroys the window. The instance is destroyed in OnFinalMessage. This ensures that we don't have issues with the LegacyRenderWidgetHostHWND instance getting deleted in the context of a message and crashes due to us calling SetMsgHandled which dereferences members in the ATL base class. BUG=381609 R=sky Review URL: https://codereview.chromium.org/349563002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@279269 0039d316-1c4b-4281-b951-d872f2087c98
* More NVDA browse mode fixesdmazzoni@chromium.org2014-06-191-22/+43
| | | | | | | | | | | The previous change (https://codereview.chromium.org/332893004/) wasn't quite right. To avoid errors, we need to only fire focus and load events when the web view itself has focus, not say when the location bar has focus. And because there are transient periods when we can't fire events, we need to keep track of whether we need to fire a focus event with a flag and fire it later. BUG=368549 NOTRY=true Review URL: https://codereview.chromium.org/344573003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278303 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crash if legacy hwnd is NULL on win 8.dmazzoni@chromium.org2014-06-151-3/+6
| | | | | | | | | | | | | Change r276950 (https://codereview.chromium.org/329053004/) fixed a bug but introduced a new crash on win 8 by not checking the legacy hwnd for NULL. BUG=384732,372478,379019 TBR=ananta Review URL: https://codereview.chromium.org/337543005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@277319 0039d316-1c4b-4281-b951-d872f2087c98
* Fix race in BrowserAccessibilityManagerWin creation.dmazzoni@chromium.org2014-06-131-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, BrowserAccessibilityManagerWin needed its parent HWND and parent IAccessible upon construction, and if RWHVA didn't have those, it didn't create the BAMW. This resulted in at least two races: * If an accessibility tree update came from the renderer but the BAMW wasn't created because the window wasn't available, the tree update would get discarded - possibly leading to an assertion failure / renderer crash later on the next update from being out of sync. * If we tried to create the BAMW before the LegacyRWHH existed, we would fall through and create a BAM instead of a BAMW, making that whole tab inaccessible. To fix both issues, we always create a BAMW when needed, and we update the BAMW with the LegacyRWHH as soon as it's available. BUG=372478,379019 NOTRY=true Review URL: https://codereview.chromium.org/329053004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276950 0039d316-1c4b-4281-b951-d872f2087c98
* Fix bug where NVDA wouldn't enter browse mode on page load.dmazzoni@chromium.org2014-06-131-0/+13
| | | | | | | | | | | | This started happening when we started sending events on web pages before they fully load. BUG=368549 NOTRY=true Review URL: https://codereview.chromium.org/332893004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276944 0039d316-1c4b-4281-b951-d872f2087c98
* Removing WTL from content runner.cpu@chromium.org2014-06-111-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | The _Module object is used by ATL COM classes to lock the module, like so _pAtlModule->Lock(); For example when CreateInstance is called: BrowserAccessibility* BrowserAccessibility::Create() { CComObject<BrowserAccessibilityWin>* instance; HRESULT hr = CComObject<BrowserAccessibilityWin>::CreateInstance(&instance); We need to get rid of WTL so we can get rid of ATL since it causes many problems. See bug for details. BUG=5027 TEST=chrome runs. Accessibility works. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=275987 Review URL: https://codereview.chromium.org/323723002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276360 0039d316-1c4b-4281-b951-d872f2087c98
* RWHI should implement BrowserAccessibilityDelegatedmazzoni@chromium.org2014-04-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This is just refactoring, there should be no behavior changes. I realized that most of the functionality of BrowserAccessibilityDelegate was implemented by RenderWidgetHostImpl, but each RenderWidgetHostView* was actually implementing the interface, resulting in extra code. It's simpler to have RWHI implement it and just call into RWHV for the few cases where the view is involved. This also removes the parallel mac-only delegate, since it was duplicating most of the same functionality. Calling OriginInScreen is a couple of extra lines of code because it needs to convert from NSPoint & NSSize to gfx::Rect, but in every other case it's the same or simpler this way. BUG=none NOTRY=true Review URL: https://codereview.chromium.org/246773008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267097 0039d316-1c4b-4281-b951-d872f2087c98
* Make BrowserAccessibilityManager use AXTree (re-land).dmazzoni@chromium.org2014-04-211-24/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | This is the final step of migrating content/*/accessibility to make full use of the new infrastructure in ui/accessibility. Previously, BrowserAccessibilityManager owned the tree of BrowserAccessibility objects and handled making changes to the tree in response to messages from the renderer. Now, AXTree handles the updates from the renderer and notifies BrowserAccessibilityManager (via AXTreeDelegate) when it should create or destroy BrowserAccessibility objects, and when it should notify a BrowserAccessibility object that it's been modified. This makes the serialization/unserialization logic fully tested now, and greatly clarifies the semantics of when in the update cycle various notifications are called (e.g., PreInitialize and PostInitialize are now OnDataChanged and OnUpdateFinished). BUG=316726 NOTRY=true Review URL: https://codereview.chromium.org/234723003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@265021 0039d316-1c4b-4281-b951-d872f2087c98
* Revert of Make BrowserAccessibilityManager use AXTree. ↵ckocagil@chromium.org2014-04-211-32/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/234723003/) Reason for revert: Broke Linux ASan LSan Tests (2) See http://build.chromium.org/p/chromium.memory/builders/Linux%20ASan%20LSan%20Tests%20%282%29/builds/1774 Original issue's description: > Make BrowserAccessibilityManager use AXTree. > > This is the final step of migrating content/*/accessibility to make > full use of the new infrastructure in ui/accessibility. > > Previously, BrowserAccessibilityManager owned the tree of > BrowserAccessibility objects and handled making changes to the > tree in response to messages from the renderer. Now, AXTree > handles the updates from the renderer and notifies > BrowserAccessibilityManager (via AXTreeDelegate) when it > should create or destroy BrowserAccessibility objects, and when > it should notify a BrowserAccessibility object that it's been > modified. > > This makes the serialization/unserialization logic fully tested now, > and greatly clarifies the semantics of when in the update cycle > various notifications are called (e.g., PreInitialize and PostInitialize > are now OnDataChanged and OnUpdateFinished). > > BUG=316726 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=264979 TBR=aboxhall@chromium.org,dtseng@chromium.org,thakis@chromium.org,dmazzoni@chromium.org NOTREECHECKS=true NOTRY=true BUG=316726 Review URL: https://codereview.chromium.org/244883003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264982 0039d316-1c4b-4281-b951-d872f2087c98
* Make BrowserAccessibilityManager use AXTree.dmazzoni@chromium.org2014-04-211-24/+32
| | | | | | | | | | | | | | | | | | | | | | | | | This is the final step of migrating content/*/accessibility to make full use of the new infrastructure in ui/accessibility. Previously, BrowserAccessibilityManager owned the tree of BrowserAccessibility objects and handled making changes to the tree in response to messages from the renderer. Now, AXTree handles the updates from the renderer and notifies BrowserAccessibilityManager (via AXTreeDelegate) when it should create or destroy BrowserAccessibility objects, and when it should notify a BrowserAccessibility object that it's been modified. This makes the serialization/unserialization logic fully tested now, and greatly clarifies the semantics of when in the update cycle various notifications are called (e.g., PreInitialize and PostInitialize are now OnDataChanged and OnUpdateFinished). BUG=316726 Review URL: https://codereview.chromium.org/234723003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264979 0039d316-1c4b-4281-b951-d872f2087c98
* Fire live region changed event on Windows.dmazzoni@chromium.org2014-04-211-4/+3
| | | | | | | | | | | | IE now fires this event when a live region changes, so we should fire it too since some screen readers now expect it. BUG=364531 Review URL: https://codereview.chromium.org/238263013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264978 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor BrowserAccessibility to prepare for AXNode (re-land)dmazzoni@chromium.org2014-04-101-2/+2
| | | | | | | | | | | | | | | | | | | The only purpose of this change is to rename some member variables and accessors in BrowserAccessibility so that in the subsequent change we can repurpose BrowserAccessibility to make use of AXNode instead. There should be no code logic changes here - just look at browser_accessibility.h, everything else just follows from that. BUG=316726 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=262673 Review URL: https://codereview.chromium.org/224803005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262956 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 262673 "Refactor BrowserAccessibility to prepare for AXNode."dmazzoni@google.com2014-04-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | > Refactor BrowserAccessibility to prepare for AXNode. > > The only purpose of this change is to rename some member > variables and accessors in BrowserAccessibility so that in the > subsequent change we can repurpose BrowserAccessibility to > make use of AXNode instead. > > There should be no code logic changes here - just look at > browser_accessibility.h, everything else just follows from > that. > > BUG=316726 > > Review URL: https://codereview.chromium.org/224803005 TBR=dmazzoni@chromium.org Review URL: https://codereview.chromium.org/230933002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262690 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor BrowserAccessibility to prepare for AXNode.dmazzoni@chromium.org2014-04-091-2/+2
| | | | | | | | | | | | | | | | | The only purpose of this change is to rename some member variables and accessors in BrowserAccessibility so that in the subsequent change we can repurpose BrowserAccessibility to make use of AXNode instead. There should be no code logic changes here - just look at browser_accessibility.h, everything else just follows from that. BUG=316726 Review URL: https://codereview.chromium.org/224803005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262673 0039d316-1c4b-4281-b951-d872f2087c98
* Fire ax focus on root document when root changes.dmazzoni@chromium.org2014-04-081-0/+5
| | | | | | | | BUG=347448 Review URL: https://codereview.chromium.org/227773002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262343 0039d316-1c4b-4281-b951-d872f2087c98
* Fire accessibility focus/blur events on root web document.dmazzoni@chromium.org2014-04-031-0/+14
| | | | | | | | | | | | | | When the aura Window containing the RWHVA gets or loses focus, we must fire the corresponding accessibility event on that object, which corresponds to the root "document" in the web hierarchy. This worked before the Aura switch because native HWNDs fired these events automatically. BUG=347448 Review URL: https://codereview.chromium.org/214243005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261495 0039d316-1c4b-4281-b951-d872f2087c98
* Send accessibility scroll event on Windows and Android.dmazzoni@chromium.org2014-02-281-0/+3
| | | | | | | | | | | | This is in response to a recent Blink change (r167866) that adds a new accessibility event that fires every time a container (frame or scrollable html element) scrolls. BUG=230839, 312318, 338540 Review URL: https://codereview.chromium.org/179023003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254245 0039d316-1c4b-4281-b951-d872f2087c98
* Move ui/base/accessibility to ui/accessibility.dmazzoni@chromium.org2014-02-251-1/+1
| | | | | | | | | | | | | | | Gets rid of the enums defined in accessibility_types.h and switches to the enums defined in ui/accessibility/ax_enums.h, which are shared by "content". Eventually, content and views may share more common accessibility code, but moving to the same enums is a good first step. BUG=316726 R=piman@chromium.org, sky@chromium.org, tfarina@chromium.org Review URL: https://codereview.chromium.org/126763003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253207 0039d316-1c4b-4281-b951-d872f2087c98
* Generate ax enums from idl.dtseng@chromium.org2014-02-091-1/+1
| | | | | | | | | | This cl lays the groundwork for sharing all ax enums between platfrom accessibility and extension accessibility. BUG= Review URL: https://codereview.chromium.org/143473003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249993 0039d316-1c4b-4281-b951-d872f2087c98
* Set the BrowserAccessibilityManagerWin instance in the ↵ananta@chromium.org2014-02-081-1/+1
| | | | | | | | | | | | | | | | LegacyRenderWidgetHostHWND class in the ctor of the BrowserAccessibilityManagerWin class The current code was passing the BrowserAccessibilityManagerWin instance in the MaybeCallNotifyWinEvent function which gets invoked if there is an Accessible client around. This leads to a crash during shutdown as the BrowserAccessibilityManagerWin class in its dtor dereferences a deleted LegacyRenderWidgetHostHWND class. The LegacyRenderWidgetHostHWND instance is destroyed when the RenderWidgetHostViewAura instance is destroyed. BUG=342160 TBR=cpu Review URL: https://codereview.chromium.org/150713004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249951 0039d316-1c4b-4281-b951-d872f2087c98
* Create a visible window with class name Chrome_RenderWidgetHostHWND which ↵ananta@chromium.org2014-02-071-92/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | corresponds to the bounds of the web contents. This is done to ensure that legacy drivers for trackpoints/trackpads and others which use track gestures for back forward navigations work. These drivers call the WindowFromPoint API and get the process name. For Chrome they look for the old Window class Chrome_RenderWidgetHostHWND. They use this to determine whether to send mouse wheels and special keyboard message for back forward navigations, etc. With Aura we don't have this window class anymore causing Chrome to not work well for a number of users. To workaround this in the shortterm, a dummy HWND with the Chrome_RenderWidgetHostHWND class name is created. This window is visible and handles mouse events. It is transparent to ensure that it does not need to draw. To ensure that we don't mess wit mouse events too much we set capture to the parent window as needed. This window also serves as the parent to windowless NPAPI plugins like Flash. Additionally the dummy accessibility window with this class name has been removed and the functionality has been consolidated into the newly added LegacyRenderWidgetHostHWND class which provides this functionality. BUG=326022,335941 R=cpu@chromium.org, scottmg@chromium.org, sky@chromium.org, cpu, scottmg TBR=jam Review URL: https://codereview.chromium.org/151083002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249537 0039d316-1c4b-4281-b951-d872f2087c98
* Remove some code inside USE_AURA and OS_WIN ifdefs in content.jam@chromium.org2014-01-141-5/+3
| | | | | | | | | | | I also removed the _win.cc files inside content. BUG=330735 R=scottmg@chromium.org Review URL: https://codereview.chromium.org/137403005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244768 0039d316-1c4b-4281-b951-d872f2087c98
* Remove Chrome Frame code from BrowserAccessibilityManagerWin.grt@chromium.org2014-01-101-3/+0
| | | | | | | | | BUG=316496 R=dmazzoni@chromium.org Review URL: https://codereview.chromium.org/132313003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244167 0039d316-1c4b-4281-b951-d872f2087c98