2008-05-06 Alice Liu <alice.liu@apple.com>
Reviewed by Adele Peterson and John Sullivan.
changes needed to build on Windows after r32911 and r32927
* WebCore.vcproj/WebCore.vcproj:
* page/AXObjectCache.cpp:
(WebCore::AXObjectCache::selectedChildrenChanged):
* page/AccessibilityObject.h:
(WebCore::AccessibilityObject::document):
(WebCore::AccessibilityObject::topDocumentFrameView):
(WebCore::AccessibilityObject::documentFrameView):
* page/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::document):
(WebCore::AccessibilityRenderObject::topDocumentFrameView):
(WebCore::AccessibilityRenderObject::documentFrameView):
* page/AccessibilityRenderObject.h:
* page/mac/AXObjectCacheMac.mm:
* page/mac/AccessibilityObjectWrapper.mm:
(-[AccessibilityObjectWrapper position]):
(-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
WebKit/win:
2008-05-06 Alice Liu <alice.liu@apple.com>
Reviewed by Adele Peterson and John Sullivan.
changes needed to build on Windows after r32911 and r32927
* AccessibleBase.cpp:
(AccessibleBase::get_accParent):
* AccessibleDocument.cpp:
(AccessibleDocument::document):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@32943
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2008-05-06 Alice Liu <alice.liu@apple.com>
+
+ Reviewed by Adele Peterson and John Sullivan.
+
+ changes needed to build on Windows after r32911 and r32927
+
+ * WebCore.vcproj/WebCore.vcproj:
+ * page/AXObjectCache.cpp:
+ (WebCore::AXObjectCache::selectedChildrenChanged):
+ * page/AccessibilityObject.h:
+ (WebCore::AccessibilityObject::document):
+ (WebCore::AccessibilityObject::topDocumentFrameView):
+ (WebCore::AccessibilityObject::documentFrameView):
+ * page/AccessibilityRenderObject.cpp:
+ (WebCore::AccessibilityRenderObject::document):
+ (WebCore::AccessibilityRenderObject::topDocumentFrameView):
+ (WebCore::AccessibilityRenderObject::documentFrameView):
+ * page/AccessibilityRenderObject.h:
+ * page/mac/AXObjectCacheMac.mm:
+ * page/mac/AccessibilityObjectWrapper.mm:
+ (-[AccessibilityObjectWrapper position]):
+ (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
+
2008-05-06 Brady Eidson <beidson@apple.com>
Reviewed by Sam Weinig
Name="page"\r
>\r
<File\r
+ RelativePath="..\page\AccessibilityListBox.cpp"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\page\AccessibilityListBox.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\page\AccessibilityListBoxOption.cpp"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\page\AccessibilityListBoxOption.h"\r
+ >\r
+ </File>\r
+ <File\r
RelativePath="..\page\AccessibilityObject.cpp"\r
>\r
</File>\r
obj->childrenChanged();
}
+void AXObjectCache::selectedChildrenChanged(RenderObject* renderer)
+{
+ postNotificationToElement(renderer, "AXSelectedChildrenChanged");
+}
+
} // namespace WebCore
virtual Widget* widget() const;
virtual Widget* widgetForAttachmentView() const;
void getDocumentLinks(Vector< RefPtr<AccessibilityObject> >&) const;
-
+ virtual Document* document() const { return 0; }
+ virtual FrameView* topDocumentFrameView() const { return 0; }
+ virtual FrameView* documentFrameView() const { return 0; }
+
void setAXObjectID(unsigned);
virtual void setFocused(bool);
virtual void setSelectedText(const String&);
return m_renderer->document()->topDocument()->renderer();
}
+Document* AccessibilityRenderObject::document() const
+{
+ return m_renderer->document();
+}
+
+FrameView* AccessibilityRenderObject::topDocumentFrameView() const
+{
+ return topRenderer()->view()->frameView();
+}
+
Widget* AccessibilityRenderObject::widget() const
{
if (!m_renderer->isWidget())
}
}
+FrameView* AccessibilityRenderObject::documentFrameView() const
+{
+ if (!m_renderer || !m_renderer->document())
+ return 0;
+
+ // this is the RenderObject's Document's Frame's FrameView
+ return m_renderer->document()->view();
+}
+
Widget* AccessibilityRenderObject::widgetForAttachmentView() const
{
if (!isAttachment())
RenderObject* renderer() const { return m_renderer; }
RenderObject* topRenderer() const;
RenderTextControl* textControl() const;
+ Document* document() const;
+ FrameView* topDocumentFrameView() const;
virtual KURL url() const;
virtual PlainTextRange selectedTextRange() const;
virtual Widget* widget() const;
virtual Widget* widgetForAttachmentView() const;
virtual void getDocumentLinks(Vector< RefPtr<AccessibilityObject> >&) const;
+ virtual FrameView* documentFrameView() const;
virtual const Vector<RefPtr<AccessibilityObject> >& children();
obj->setWrapper([[AccessibilityObjectWrapper alloc] initWithAccessibilityObject:obj]);
}
-void AXObjectCache::selectedChildrenChanged(RenderObject* renderer)
-{
- postNotificationToElement(renderer, "AXSelectedChildrenChanged");
-}
-
void AXObjectCache::postNotification(RenderObject* renderer, const String& message)
{
if (!renderer)
return textMarkerRangeFromVisiblePositions(selection.visibleStart(), selection.visibleEnd());
}
-- (FrameView *)documentFrameView:(AccessibilityObject *)object
-{
- while (object && !object->isAccessibilityRenderObject())
- object = object->parentObject();
-
- RenderObject* renderer = 0;
- if (object)
- renderer = static_cast<AccessibilityRenderObject*>(object)->renderer();
-
- if (!renderer || !renderer->document())
- return 0;
-
- // this is the RenderObject's Document's Frame's FrameView
- return renderer->document()->view();
-}
-
- (NSValue*)position
{
IntRect rect = m_object->elementRect();
// The Cocoa accessibility API wants the lower-left corner.
NSPoint point = NSMakePoint(rect.x(), rect.bottom());
- FrameView* frameView = [self documentFrameView:m_object];
+ FrameView* frameView = m_object->documentFrameView();
if (frameView) {
NSView* view = frameView->documentView();
point = [[view window] convertBaseToScreen: [view convertPoint: point toView:nil]];
return [self position];
if ([attributeName isEqualToString: NSAccessibilityWindowAttribute]) {
- FrameView* fv = [self documentFrameView:m_object];
+ FrameView* fv = m_object->documentFrameView();
if (fv)
return [fv->getView() window];
return nil;
if (!m_object)
return E_FAIL;
- return WebView::AccessibleObjectFromWindow(m_object->topRenderer()->view()->frameView()->containingWindow(),
+ return WebView::AccessibleObjectFromWindow(m_object->topDocumentFrameView()->containingWindow(),
OBJID_WINDOW, __uuidof(IAccessible), reinterpret_cast<void**>(parent));
}
{
if (!m_object)
return 0;
- return m_object->renderer()->document();
+ return m_object->document();
}
+2008-05-06 Alice Liu <alice.liu@apple.com>
+
+ Reviewed by Adele Peterson and John Sullivan.
+
+ changes needed to build on Windows after r32911 and r32927
+
+ * AccessibleBase.cpp:
+ (AccessibleBase::get_accParent):
+ * AccessibleDocument.cpp:
+ (AccessibleDocument::document):
+
2008-05-06 Brady Eidson <beidson@apple.com>
Reviewed by Darin Adler