| OLD | NEW |
| 1 /** | 1 /** |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> | 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> |
| 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) | 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) |
| 5 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc. | 5 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 int xPos = 0; | 507 int xPos = 0; |
| 508 int height = m_rows.m_sizes[r]; | 508 int height = m_rows.m_sizes[r]; |
| 509 for (int c = 0; c < cols; c++) { | 509 for (int c = 0; c < cols; c++) { |
| 510 child->setLocation(IntPoint(xPos, yPos)); | 510 child->setLocation(IntPoint(xPos, yPos)); |
| 511 int width = m_cols.m_sizes[c]; | 511 int width = m_cols.m_sizes[c]; |
| 512 | 512 |
| 513 // has to be resized and itself resize its contents | 513 // has to be resized and itself resize its contents |
| 514 if (width != child->width() || height != child->height()) { | 514 if (width != child->width() || height != child->height()) { |
| 515 child->setWidth(width); | 515 child->setWidth(width); |
| 516 child->setHeight(height); | 516 child->setHeight(height); |
| 517 child->setNeedsLayout(); | 517 child->setNeedsLayoutAndFullRepaint(); |
| 518 child->layout(); | 518 child->layout(); |
| 519 } | 519 } |
| 520 | 520 |
| 521 xPos += width + borderThickness; | 521 xPos += width + borderThickness; |
| 522 | 522 |
| 523 child = child->nextSiblingBox(); | 523 child = child->nextSiblingBox(); |
| 524 if (!child) | 524 if (!child) |
| 525 return; | 525 return; |
| 526 } | 526 } |
| 527 yPos += height + borderThickness; | 527 yPos += height + borderThickness; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 547 if (needsLayout()) | 547 if (needsLayout()) |
| 548 return; | 548 return; |
| 549 if (axis.m_splitBeingResized == noSplit) | 549 if (axis.m_splitBeingResized == noSplit) |
| 550 return; | 550 return; |
| 551 int currentSplitPosition = splitPosition(axis, axis.m_splitBeingResized); | 551 int currentSplitPosition = splitPosition(axis, axis.m_splitBeingResized); |
| 552 int delta = (position - currentSplitPosition) - axis.m_splitResizeOffset; | 552 int delta = (position - currentSplitPosition) - axis.m_splitResizeOffset; |
| 553 if (!delta) | 553 if (!delta) |
| 554 return; | 554 return; |
| 555 axis.m_deltas[axis.m_splitBeingResized - 1] += delta; | 555 axis.m_deltas[axis.m_splitBeingResized - 1] += delta; |
| 556 axis.m_deltas[axis.m_splitBeingResized] -= delta; | 556 axis.m_deltas[axis.m_splitBeingResized] -= delta; |
| 557 setNeedsLayout(); | 557 setNeedsLayoutAndFullRepaint(); |
| 558 } | 558 } |
| 559 | 559 |
| 560 bool RenderFrameSet::userResize(MouseEvent* evt) | 560 bool RenderFrameSet::userResize(MouseEvent* evt) |
| 561 { | 561 { |
| 562 if (!m_isResizing) { | 562 if (!m_isResizing) { |
| 563 if (needsLayout()) | 563 if (needsLayout()) |
| 564 return false; | 564 return false; |
| 565 if (evt->type() == EventTypeNames::mousedown && evt->button() == LeftBut
ton) { | 565 if (evt->type() == EventTypeNames::mousedown && evt->button() == LeftBut
ton) { |
| 566 FloatPoint localPos = absoluteToLocal(evt->absoluteLocation(), UseTr
ansforms); | 566 FloatPoint localPos = absoluteToLocal(evt->absoluteLocation(), UseTr
ansforms); |
| 567 startResizing(m_cols, localPos.x()); | 567 startResizing(m_cols, localPos.x()); |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 661 return SetCursor; | 661 return SetCursor; |
| 662 } | 662 } |
| 663 if (canResizeColumn(roundedPoint)) { | 663 if (canResizeColumn(roundedPoint)) { |
| 664 cursor = columnResizeCursor(); | 664 cursor = columnResizeCursor(); |
| 665 return SetCursor; | 665 return SetCursor; |
| 666 } | 666 } |
| 667 return RenderBox::getCursor(point, cursor); | 667 return RenderBox::getCursor(point, cursor); |
| 668 } | 668 } |
| 669 | 669 |
| 670 } // namespace WebCore | 670 } // namespace WebCore |
| OLD | NEW |