OLD | NEW |
1 /* | 1 /* |
2 * (C) 1999 Lars Knoll (knoll@kde.org) | 2 * (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 2000 Dirk Mueller (mueller@kde.org) | 3 * (C) 2000 Dirk Mueller (mueller@kde.org) |
4 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. |
5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) | 5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) |
6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) | 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 1850 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1861 gSecureTextTimers->add(this, secureTextTimer); | 1861 gSecureTextTimers->add(this, secureTextTimer); |
1862 } | 1862 } |
1863 secureTextTimer->restartWithNewText(lastTypedCharacterOffset); | 1863 secureTextTimer->restartWithNewText(lastTypedCharacterOffset); |
1864 } | 1864 } |
1865 | 1865 |
1866 PassRefPtr<AbstractInlineTextBox> LayoutText::firstAbstractInlineTextBox() | 1866 PassRefPtr<AbstractInlineTextBox> LayoutText::firstAbstractInlineTextBox() |
1867 { | 1867 { |
1868 return AbstractInlineTextBox::getOrCreate(LineLayoutText(this), m_firstTextB
ox); | 1868 return AbstractInlineTextBox::getOrCreate(LineLayoutText(this), m_firstTextB
ox); |
1869 } | 1869 } |
1870 | 1870 |
1871 void LayoutText::invalidateDisplayItemClients(const LayoutBoxModelObject& paintI
nvalidationContainer, PaintInvalidationReason invalidationReason, const LayoutRe
ct* paintInvalidationRect) const | 1871 void LayoutText::invalidateDisplayItemClients(const LayoutBoxModelObject& paintI
nvalidationContainer, PaintInvalidationReason invalidationReason) const |
1872 { | 1872 { |
1873 LayoutObject::invalidateDisplayItemClients(paintInvalidationContainer, inval
idationReason, paintInvalidationRect); | 1873 LayoutObject::invalidateDisplayItemClients(paintInvalidationContainer, inval
idationReason); |
1874 | 1874 |
1875 // Use the paintInvalidationRect of LayoutText for inline boxes, which saves
the cost to calculate paint invalidation rect | |
1876 // for every inline box. This won't cause more rasterization invalidations b
ecause the whole LayoutText is being invalidated. | |
1877 for (InlineTextBox* box = firstTextBox(); box; box = box->nextTextBox()) { | 1875 for (InlineTextBox* box = firstTextBox(); box; box = box->nextTextBox()) { |
1878 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(*box, in
validationReason, paintInvalidationRect); | 1876 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(*box, in
validationReason); |
1879 if (box->truncation() != cNoTruncation) { | 1877 if (box->truncation() != cNoTruncation) { |
1880 if (EllipsisBox* ellipsisBox = box->root().ellipsisBox()) | 1878 if (EllipsisBox* ellipsisBox = box->root().ellipsisBox()) |
1881 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(
*ellipsisBox, invalidationReason, paintInvalidationRect); | 1879 paintInvalidationContainer.invalidateDisplayItemClientOnBacking(
*ellipsisBox, invalidationReason); |
1882 } | 1880 } |
1883 } | 1881 } |
1884 } | 1882 } |
1885 | 1883 |
1886 } // namespace blink | 1884 } // namespace blink |
OLD | NEW |