Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(409)

Side by Side Diff: Source/core/inspector/InspectorCSSAgent.cpp

Issue 1033943002: Rename LayoutStyle to papayawhip (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: ensureComputedStyle Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/html/track/vtt/VTTCue.cpp ('k') | Source/core/inspector/InspectorDOMAgent.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010, Google Inc. All rights reserved. 2 * Copyright (C) 2010, 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 782 matching lines...) Expand 10 before | Expand all | Expand 10 after
793 return; 793 return;
794 794
795 RefPtrWillBeRawPtr<CSSComputedStyleDeclaration> computedStyleInfo = CSSCompu tedStyleDeclaration::create(node, true); 795 RefPtrWillBeRawPtr<CSSComputedStyleDeclaration> computedStyleInfo = CSSCompu tedStyleDeclaration::create(node, true);
796 RefPtrWillBeRawPtr<InspectorStyle> inspectorStyle = InspectorStyle::create(I nspectorCSSId(), computedStyleInfo, 0); 796 RefPtrWillBeRawPtr<InspectorStyle> inspectorStyle = InspectorStyle::create(I nspectorCSSId(), computedStyleInfo, 0);
797 style = inspectorStyle->buildArrayForComputedStyle(); 797 style = inspectorStyle->buildArrayForComputedStyle();
798 } 798 }
799 799
800 void InspectorCSSAgent::collectPlatformFontsForRenderer(LayoutText* renderer, Ha shCountedSet<String>* fontStats) 800 void InspectorCSSAgent::collectPlatformFontsForRenderer(LayoutText* renderer, Ha shCountedSet<String>* fontStats)
801 { 801 {
802 for (InlineTextBox* box = renderer->firstTextBox(); box; box = box->nextText Box()) { 802 for (InlineTextBox* box = renderer->firstTextBox(); box; box = box->nextText Box()) {
803 const LayoutStyle& style = renderer->styleRef(box->isFirstLineStyle()); 803 const ComputedStyle& style = renderer->styleRef(box->isFirstLineStyle()) ;
804 const Font& font = style.font(); 804 const Font& font = style.font();
805 TextRun run = box->constructTextRunForInspector(style, font); 805 TextRun run = box->constructTextRunForInspector(style, font);
806 SimpleShaper shaper(&font, run); 806 SimpleShaper shaper(&font, run);
807 GlyphBuffer glyphBuffer; 807 GlyphBuffer glyphBuffer;
808 shaper.advance(run.length(), &glyphBuffer); 808 shaper.advance(run.length(), &glyphBuffer);
809 for (unsigned i = 0; i < glyphBuffer.size(); ++i) { 809 for (unsigned i = 0; i < glyphBuffer.size(); ++i) {
810 String familyName = glyphBuffer.fontDataAt(i)->platformData().fontFa milyName(); 810 String familyName = glyphBuffer.fontDataAt(i)->platformData().fontFa milyName();
811 if (familyName.isNull()) 811 if (familyName.isNull())
812 familyName = ""; 812 familyName = "";
813 fontStats->add(familyName); 813 fontStats->add(familyName);
(...skipping 747 matching lines...) Expand 10 before | Expand all | Expand 10 after
1561 visitor->trace(m_invalidatedDocuments); 1561 visitor->trace(m_invalidatedDocuments);
1562 visitor->trace(m_nodeToInspectorStyleSheet); 1562 visitor->trace(m_nodeToInspectorStyleSheet);
1563 visitor->trace(m_documentToViaInspectorStyleSheet); 1563 visitor->trace(m_documentToViaInspectorStyleSheet);
1564 #endif 1564 #endif
1565 visitor->trace(m_inspectorUserAgentStyleSheet); 1565 visitor->trace(m_inspectorUserAgentStyleSheet);
1566 InspectorBaseAgent::trace(visitor); 1566 InspectorBaseAgent::trace(visitor);
1567 } 1567 }
1568 1568
1569 } // namespace blink 1569 } // namespace blink
1570 1570
OLDNEW
« no previous file with comments | « Source/core/html/track/vtt/VTTCue.cpp ('k') | Source/core/inspector/InspectorDOMAgent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698