Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(320)

Side by Side Diff: Source/core/accessibility/AXObjectCache.cpp

Issue 213883003: Revert of Send AXLayoutComplete even when document hasn't finished loading yet. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/accessibility/AXObjectCache.h ('k') | Source/core/frame/FrameView.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2008, 2009, 2010 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 if (!view) 797 if (!view)
798 return; 798 return;
799 799
800 // We don't want to create a scroll view from this method, only update an ex isting one. 800 // We don't want to create a scroll view from this method, only update an ex isting one.
801 if (AXObject* scrollViewObject = get(view)) { 801 if (AXObject* scrollViewObject = get(view)) {
802 m_computedObjectAttributeCache->clear(); 802 m_computedObjectAttributeCache->clear();
803 scrollViewObject->updateChildrenIfNecessary(); 803 scrollViewObject->updateChildrenIfNecessary();
804 } 804 }
805 } 805 }
806 806
807 void AXObjectCache::handleLayoutComplete(RenderObject* renderer)
808 {
809 if (!renderer)
810 return;
811
812 m_computedObjectAttributeCache->clear();
813
814 // Create the AXObject if it didn't yet exist - that's always safe at the en d of a layout, and it
815 // allows an AX notification to be sent when a page has its first layout, ra ther than when the
816 // document first loads.
817 if (AXObject* obj = getOrCreate(renderer))
818 postNotification(obj, obj->document(), AXLayoutComplete, true);
819 }
820
821 void AXObjectCache::handleAriaExpandedChange(Node* node) 807 void AXObjectCache::handleAriaExpandedChange(Node* node)
822 { 808 {
823 if (AXObject* obj = getOrCreate(node)) 809 if (AXObject* obj = getOrCreate(node))
824 obj->handleAriaExpandedChanged(); 810 obj->handleAriaExpandedChanged();
825 } 811 }
826 812
827 void AXObjectCache::handleActiveDescendantChanged(Node* node) 813 void AXObjectCache::handleActiveDescendantChanged(Node* node)
828 { 814 {
829 if (AXObject* obj = getOrCreate(node)) 815 if (AXObject* obj = getOrCreate(node))
830 obj->handleActiveDescendantChanged(); 816 obj->handleActiveDescendantChanged();
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
1048 { 1034 {
1049 postPlatformNotification(getOrCreate(scrollView), AXScrollPositionChanged); 1035 postPlatformNotification(getOrCreate(scrollView), AXScrollPositionChanged);
1050 } 1036 }
1051 1037
1052 void AXObjectCache::handleScrollPositionChanged(RenderObject* renderObject) 1038 void AXObjectCache::handleScrollPositionChanged(RenderObject* renderObject)
1053 { 1039 {
1054 postPlatformNotification(getOrCreate(renderObject), AXScrollPositionChanged) ; 1040 postPlatformNotification(getOrCreate(renderObject), AXScrollPositionChanged) ;
1055 } 1041 }
1056 1042
1057 } // namespace WebCore 1043 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/accessibility/AXObjectCache.h ('k') | Source/core/frame/FrameView.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698