| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Peter Kelly (pmk@post.com) | 4 * (C) 2001 Peter Kelly (pmk@post.com) |
| 5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 6 * (C) 2007 David Smith (catfish.man@gmail.com) | 6 * (C) 2007 David Smith (catfish.man@gmail.com) |
| 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc.
All rights reserved. | 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc.
All rights reserved. |
| 8 * (C) 2007 Eric Seidel (eric@webkit.org) | 8 * (C) 2007 Eric Seidel (eric@webkit.org) |
| 9 * | 9 * |
| 10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
| (...skipping 701 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 712 | 712 |
| 713 if (LocalDOMWindow* window = document().domWindow()) | 713 if (LocalDOMWindow* window = document().domWindow()) |
| 714 window->scrollTo(window->scrollX(), newTop); | 714 window->scrollTo(window->scrollX(), newTop); |
| 715 } | 715 } |
| 716 } | 716 } |
| 717 | 717 |
| 718 int Element::scrollWidth() | 718 int Element::scrollWidth() |
| 719 { | 719 { |
| 720 document().updateLayoutIgnorePendingStylesheets(); | 720 document().updateLayoutIgnorePendingStylesheets(); |
| 721 if (LayoutBox* box = layoutBox()) | 721 if (LayoutBox* box = layoutBox()) |
| 722 return adjustLayoutUnitForAbsoluteZoom(box->scrollWidth(), *box).toDoubl
e(); | 722 return adjustLayoutUnitForAbsoluteZoom(box->scrollWidth(), *box).round()
; |
| 723 return 0; | 723 return 0; |
| 724 } | 724 } |
| 725 | 725 |
| 726 int Element::scrollHeight() | 726 int Element::scrollHeight() |
| 727 { | 727 { |
| 728 document().updateLayoutIgnorePendingStylesheets(); | 728 document().updateLayoutIgnorePendingStylesheets(); |
| 729 if (LayoutBox* box = layoutBox()) | 729 if (LayoutBox* box = layoutBox()) |
| 730 return adjustLayoutUnitForAbsoluteZoom(box->scrollHeight(), *box).toDoub
le(); | 730 return adjustLayoutUnitForAbsoluteZoom(box->scrollHeight(), *box).round(
); |
| 731 return 0; | 731 return 0; |
| 732 } | 732 } |
| 733 | 733 |
| 734 void Element::scrollBy(double x, double y) | 734 void Element::scrollBy(double x, double y) |
| 735 { | 735 { |
| 736 ScrollToOptions scrollToOptions; | 736 ScrollToOptions scrollToOptions; |
| 737 scrollToOptions.setLeft(x); | 737 scrollToOptions.setLeft(x); |
| 738 scrollToOptions.setTop(y); | 738 scrollToOptions.setTop(y); |
| 739 scrollBy(scrollToOptions); | 739 scrollBy(scrollToOptions); |
| 740 } | 740 } |
| (...skipping 2646 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3387 { | 3387 { |
| 3388 #if ENABLE(OILPAN) | 3388 #if ENABLE(OILPAN) |
| 3389 if (hasRareData()) | 3389 if (hasRareData()) |
| 3390 visitor->trace(elementRareData()); | 3390 visitor->trace(elementRareData()); |
| 3391 visitor->trace(m_elementData); | 3391 visitor->trace(m_elementData); |
| 3392 #endif | 3392 #endif |
| 3393 ContainerNode::trace(visitor); | 3393 ContainerNode::trace(visitor); |
| 3394 } | 3394 } |
| 3395 | 3395 |
| 3396 } // namespace blink | 3396 } // namespace blink |
| OLD | NEW |