| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. |
| 3 * 2009 Torch Mobile Inc. All rights reserved. | 3 * 2009 Torch Mobile Inc. All rights reserved. |
| 4 * (http://www.torchmobile.com/) | 4 * (http://www.torchmobile.com/) |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * | 9 * |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 126 if (Style()->Width().IsPercentOrCalc()) | 126 if (Style()->Width().IsPercentOrCalc()) |
| 127 min_logical_width = LayoutUnit(); | 127 min_logical_width = LayoutUnit(); |
| 128 } | 128 } |
| 129 | 129 |
| 130 void LayoutListBox::ScrollToRect(const LayoutRect& rect) { | 130 void LayoutListBox::ScrollToRect(const LayoutRect& rect) { |
| 131 if (HasOverflowClip()) { | 131 if (HasOverflowClip()) { |
| 132 DCHECK(Layer()); | 132 DCHECK(Layer()); |
| 133 DCHECK(Layer()->GetScrollableArea()); | 133 DCHECK(Layer()->GetScrollableArea()); |
| 134 Layer()->GetScrollableArea()->ScrollIntoView( | 134 Layer()->GetScrollableArea()->ScrollIntoView( |
| 135 rect, ScrollAlignment::kAlignToEdgeIfNeeded, | 135 rect, ScrollAlignment::kAlignToEdgeIfNeeded, |
| 136 ScrollAlignment::kAlignToEdgeIfNeeded, false); | 136 ScrollAlignment::kAlignToEdgeIfNeeded); |
| 137 } | 137 } |
| 138 } | 138 } |
| 139 | 139 |
| 140 } // namespace blink | 140 } // namespace blink |
| OLD | NEW |