| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 798 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 809 return 0; | 809 return 0; |
| 810 | 810 |
| 811 FingerprintSourceData data; | 811 FingerprintSourceData data; |
| 812 if (LayoutObject* parent = parentElementLayoutObject(layoutObject)) | 812 if (LayoutObject* parent = parentElementLayoutObject(layoutObject)) |
| 813 data.m_parentHash = getFingerprint(parent); | 813 data.m_parentHash = getFingerprint(parent); |
| 814 | 814 |
| 815 data.m_qualifiedNameHash = | 815 data.m_qualifiedNameHash = |
| 816 QualifiedNameHash::hash(toElement(node)->tagQName()); | 816 QualifiedNameHash::hash(toElement(node)->tagQName()); |
| 817 | 817 |
| 818 if (const ComputedStyle* style = layoutObject->style()) { | 818 if (const ComputedStyle* style = layoutObject->style()) { |
| 819 data.m_packedStyleProperties = style->direction(); | 819 data.m_packedStyleProperties = static_cast<unsigned>(style->direction()); |
| 820 data.m_packedStyleProperties |= (style->position() << 1); | 820 data.m_packedStyleProperties |= (style->position() << 1); |
| 821 data.m_packedStyleProperties |= | 821 data.m_packedStyleProperties |= |
| 822 (static_cast<unsigned>(style->floating()) << 4); | 822 (static_cast<unsigned>(style->floating()) << 4); |
| 823 data.m_packedStyleProperties |= | 823 data.m_packedStyleProperties |= |
| 824 (static_cast<unsigned>(style->display()) << 6); | 824 (static_cast<unsigned>(style->display()) << 6); |
| 825 data.m_packedStyleProperties |= (style->width().type() << 11); | 825 data.m_packedStyleProperties |= (style->width().type() << 11); |
| 826 // packedStyleProperties effectively using 15 bits now. | 826 // packedStyleProperties effectively using 15 bits now. |
| 827 | 827 |
| 828 // consider for adding: writing mode, padding. | 828 // consider for adding: writing mode, padding. |
| 829 | 829 |
| (...skipping 595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1425 } | 1425 } |
| 1426 } | 1426 } |
| 1427 potentiallyInconsistentSuperclusters.clear(); | 1427 potentiallyInconsistentSuperclusters.clear(); |
| 1428 } | 1428 } |
| 1429 | 1429 |
| 1430 DEFINE_TRACE(TextAutosizer) { | 1430 DEFINE_TRACE(TextAutosizer) { |
| 1431 visitor->trace(m_document); | 1431 visitor->trace(m_document); |
| 1432 } | 1432 } |
| 1433 | 1433 |
| 1434 } // namespace blink | 1434 } // namespace blink |
| OLD | NEW |