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

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

Issue 24752002: Cleanup <static_cast>: Switch to toFoo for Accessibility Objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 2 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2011 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 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 m_children[pos]->detachFromParent(); 121 m_children[pos]->detachFromParent();
122 m_children.remove(pos); 122 m_children.remove(pos);
123 } 123 }
124 } 124 }
125 125
126 AccessibilityScrollbar* AccessibilityScrollView::addChildScrollbar(Scrollbar* sc rollbar) 126 AccessibilityScrollbar* AccessibilityScrollView::addChildScrollbar(Scrollbar* sc rollbar)
127 { 127 {
128 if (!scrollbar) 128 if (!scrollbar)
129 return 0; 129 return 0;
130 130
131 AccessibilityScrollbar* scrollBarObject = static_cast<AccessibilityScrollbar *>(axObjectCache()->getOrCreate(scrollbar)); 131 AccessibilityScrollbar* scrollBarObject = toAccessibilityScrollbar(axObjectC ache()->getOrCreate(scrollbar));
132 scrollBarObject->setParent(this); 132 scrollBarObject->setParent(this);
133 m_children.append(scrollBarObject); 133 m_children.append(scrollBarObject);
134 return scrollBarObject; 134 return scrollBarObject;
135 } 135 }
136 136
137 void AccessibilityScrollView::clearChildren() 137 void AccessibilityScrollView::clearChildren()
138 { 138 {
139 AccessibilityObject::clearChildren(); 139 AccessibilityObject::clearChildren();
140 m_verticalScrollbar = 0; 140 m_verticalScrollbar = 0;
141 m_horizontalScrollbar = 0; 141 m_horizontalScrollbar = 0;
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 return m_scrollView; 233 return m_scrollView;
234 } 234 }
235 235
236 void AccessibilityScrollView::scrollTo(const IntPoint& point) const 236 void AccessibilityScrollView::scrollTo(const IntPoint& point) const
237 { 237 {
238 if (m_scrollView) 238 if (m_scrollView)
239 m_scrollView->setScrollPosition(point); 239 m_scrollView->setScrollPosition(point);
240 } 240 }
241 241
242 } // namespace WebCore 242 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/accessibility/AccessibilityRenderObject.cpp ('k') | Source/core/accessibility/AccessibilityScrollbar.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698