| 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 Simon Hausmann <hausmann@kde.org> | 5 * 2000 Simon Hausmann <hausmann@kde.org> |
| 6 * 2000 Stefan Schimanski <1Stein@gmx.de> | 6 * 2000 Stefan Schimanski <1Stein@gmx.de> |
| 7 * 2001 George Staikos <staikos@kde.org> | 7 * 2001 George Staikos <staikos@kde.org> |
| 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
| 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> | 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> |
| 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| (...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 452 if (RefPtr<Range> nextCharacterRange = makeRange(position, next)) { | 452 if (RefPtr<Range> nextCharacterRange = makeRange(position, next)) { |
| 453 LayoutRect rect = editor()->firstRectForRange(nextCharacterRange.get()); | 453 LayoutRect rect = editor()->firstRectForRange(nextCharacterRange.get()); |
| 454 if (rect.contains(framePoint)) | 454 if (rect.contains(framePoint)) |
| 455 return nextCharacterRange.release(); | 455 return nextCharacterRange.release(); |
| 456 } | 456 } |
| 457 | 457 |
| 458 return 0; | 458 return 0; |
| 459 } | 459 } |
| 460 | 460 |
| 461 void Frame::createView(const IntSize& viewportSize, const StyleColor& background
Color, bool transparent, | 461 void Frame::createView(const IntSize& viewportSize, const StyleColor& background
Color, bool transparent, |
| 462 const IntSize& fixedLayoutSize, bool useFixedLayout, ScrollbarMode horizonta
lScrollbarMode, bool horizontalLock, | 462 ScrollbarMode horizontalScrollbarMode, bool horizontalLock, |
| 463 ScrollbarMode verticalScrollbarMode, bool verticalLock) | 463 ScrollbarMode verticalScrollbarMode, bool verticalLock) |
| 464 { | 464 { |
| 465 ASSERT(this); | 465 ASSERT(this); |
| 466 ASSERT(m_page); | 466 ASSERT(m_page); |
| 467 | 467 |
| 468 bool isMainFrame = this == m_page->mainFrame(); | 468 bool isMainFrame = this == m_page->mainFrame(); |
| 469 | 469 |
| 470 if (isMainFrame && view()) | 470 if (isMainFrame && view()) |
| 471 view()->setParentVisible(false); | 471 view()->setParentVisible(false); |
| 472 | 472 |
| 473 setView(0); | 473 setView(0); |
| 474 | 474 |
| 475 RefPtr<FrameView> frameView; | 475 RefPtr<FrameView> frameView; |
| 476 if (isMainFrame) { | 476 if (isMainFrame) |
| 477 frameView = FrameView::create(this, viewportSize); | 477 frameView = FrameView::create(this, viewportSize); |
| 478 frameView->setFixedLayoutSize(fixedLayoutSize); | 478 else |
| 479 frameView->setUseFixedLayout(useFixedLayout); | |
| 480 } else | |
| 481 frameView = FrameView::create(this); | 479 frameView = FrameView::create(this); |
| 482 | 480 |
| 483 frameView->setScrollbarModes(horizontalScrollbarMode, verticalScrollbarMode,
horizontalLock, verticalLock); | 481 frameView->setScrollbarModes(horizontalScrollbarMode, verticalScrollbarMode,
horizontalLock, verticalLock); |
| 484 | 482 |
| 485 setView(frameView); | 483 setView(frameView); |
| 486 | 484 |
| 487 if (backgroundColor.isValid()) | 485 if (backgroundColor.isValid()) |
| 488 frameView->updateBackgroundRecursively(backgroundColor.color(), transpar
ent); | 486 frameView->updateBackgroundRecursively(backgroundColor.color(), transpar
ent); |
| 489 | 487 |
| 490 if (isMainFrame) | 488 if (isMainFrame) |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 696 buffer->context()->translate(-paintingRect.x(), -paintingRect.y()); | 694 buffer->context()->translate(-paintingRect.x(), -paintingRect.y()); |
| 697 buffer->context()->clip(FloatRect(0, 0, paintingRect.maxX(), paintingRect.ma
xY())); | 695 buffer->context()->clip(FloatRect(0, 0, paintingRect.maxX(), paintingRect.ma
xY())); |
| 698 | 696 |
| 699 m_view->paintContents(buffer->context(), paintingRect); | 697 m_view->paintContents(buffer->context(), paintingRect); |
| 700 | 698 |
| 701 RefPtr<Image> image = buffer->copyImage(); | 699 RefPtr<Image> image = buffer->copyImage(); |
| 702 return DragImage::create(image.get()); | 700 return DragImage::create(image.get()); |
| 703 } | 701 } |
| 704 | 702 |
| 705 } // namespace WebCore | 703 } // namespace WebCore |
| OLD | NEW |