| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> | 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> |
| 3 * 1999 Lars Knoll <knoll@kde.org> | 3 * 1999 Lars Knoll <knoll@kde.org> |
| 4 * 1999 Antti Koivisto <koivisto@kde.org> | 4 * 1999 Antti Koivisto <koivisto@kde.org> |
| 5 * 2000 Dirk Mueller <mueller@kde.org> | 5 * 2000 Dirk Mueller <mueller@kde.org> |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) | 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) |
| 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
| 9 * Copyright (C) 2009 Google Inc. All rights reserved. | 9 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 10 * | 10 * |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 | 149 |
| 150 FrameView::~FrameView() | 150 FrameView::~FrameView() |
| 151 { | 151 { |
| 152 if (m_postLayoutTasksTimer.isActive()) | 152 if (m_postLayoutTasksTimer.isActive()) |
| 153 m_postLayoutTasksTimer.stop(); | 153 m_postLayoutTasksTimer.stop(); |
| 154 | 154 |
| 155 if (m_didScrollTimer.isActive()) | 155 if (m_didScrollTimer.isActive()) |
| 156 m_didScrollTimer.stop(); | 156 m_didScrollTimer.stop(); |
| 157 | 157 |
| 158 removeFromAXObjectCache(); | 158 removeFromAXObjectCache(); |
| 159 resetScrollbars(); | |
| 160 | 159 |
| 161 // Custom scrollbars should already be destroyed at this point | 160 // Custom scrollbars should already be destroyed at this point |
| 162 ASSERT(!horizontalScrollbar() || !horizontalScrollbar()->isCustomScrollbar()
); | 161 ASSERT(!horizontalScrollbar() || !horizontalScrollbar()->isCustomScrollbar()
); |
| 163 ASSERT(!verticalScrollbar() || !verticalScrollbar()->isCustomScrollbar()); | 162 ASSERT(!verticalScrollbar() || !verticalScrollbar()->isCustomScrollbar()); |
| 164 | 163 |
| 165 setHasHorizontalScrollbar(false); // Remove native scrollbars now before we
lose the connection to the HostWindow. | 164 setHasHorizontalScrollbar(false); // Remove native scrollbars now before we
lose the connection to the HostWindow. |
| 166 setHasVerticalScrollbar(false); | 165 setHasVerticalScrollbar(false); |
| 167 | 166 |
| 168 ASSERT(!m_scrollCorner); | 167 ASSERT(!m_scrollCorner); |
| 169 | 168 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 206 m_maintainScrollPositionAnchor = nullptr; | 205 m_maintainScrollPositionAnchor = nullptr; |
| 207 m_viewportConstrainedObjects.clear(); | 206 m_viewportConstrainedObjects.clear(); |
| 208 } | 207 } |
| 209 | 208 |
| 210 void FrameView::removeFromAXObjectCache() | 209 void FrameView::removeFromAXObjectCache() |
| 211 { | 210 { |
| 212 if (AXObjectCache* cache = axObjectCache()) | 211 if (AXObjectCache* cache = axObjectCache()) |
| 213 cache->remove(this); | 212 cache->remove(this); |
| 214 } | 213 } |
| 215 | 214 |
| 216 void FrameView::resetScrollbars() | |
| 217 { | |
| 218 // Reset the document's scrollbars back to our defaults before we yield the
floor. | |
| 219 m_firstLayout = true; | |
| 220 setScrollbarsSuppressed(true); | |
| 221 if (m_canHaveScrollbars) | |
| 222 setScrollbarModes(ScrollbarAuto, ScrollbarAuto); | |
| 223 else | |
| 224 setScrollbarModes(ScrollbarAlwaysOff, ScrollbarAlwaysOff); | |
| 225 setScrollbarsSuppressed(false); | |
| 226 } | |
| 227 | |
| 228 void FrameView::init() | 215 void FrameView::init() |
| 229 { | 216 { |
| 230 reset(); | 217 reset(); |
| 231 | 218 |
| 232 m_size = LayoutSize(); | 219 m_size = LayoutSize(); |
| 233 | 220 |
| 234 // Propagate the marginwidth/height and scrolling modes to the view. | 221 // Propagate the marginwidth/height and scrolling modes to the view. |
| 235 // FIXME: Do we need to do this for OOPI? | 222 // FIXME: Do we need to do this for OOPI? |
| 236 Element* ownerElement = m_frame->deprecatedLocalOwner(); | 223 Element* ownerElement = m_frame->deprecatedLocalOwner(); |
| 237 if (ownerElement && (isHTMLFrameElement(*ownerElement) || isHTMLIFrameElemen
t(*ownerElement))) { | 224 if (ownerElement && (isHTMLFrameElement(*ownerElement) || isHTMLIFrameElemen
t(*ownerElement))) { |
| (...skipping 2775 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3013 void FrameView::willRemoveScrollbar(Scrollbar* scrollbar, ScrollbarOrientation o
rientation) | 3000 void FrameView::willRemoveScrollbar(Scrollbar* scrollbar, ScrollbarOrientation o
rientation) |
| 3014 { | 3001 { |
| 3015 ScrollableArea::willRemoveScrollbar(scrollbar, orientation); | 3002 ScrollableArea::willRemoveScrollbar(scrollbar, orientation); |
| 3016 if (AXObjectCache* cache = axObjectCache()) { | 3003 if (AXObjectCache* cache = axObjectCache()) { |
| 3017 cache->remove(scrollbar); | 3004 cache->remove(scrollbar); |
| 3018 cache->handleScrollbarUpdate(this); | 3005 cache->handleScrollbarUpdate(this); |
| 3019 } | 3006 } |
| 3020 } | 3007 } |
| 3021 | 3008 |
| 3022 } // namespace blink | 3009 } // namespace blink |
| OLD | NEW |