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

Side by Side Diff: Source/core/layout/svg/SVGTextQuery.cpp

Issue 927583002: Moving RenderSVG* files from rendering/ to layout/ (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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/layout/svg/SVGLayoutTreeAsText.cpp ('k') | Source/core/loader/ImageLoader.cpp » ('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) Research In Motion Limited 2010-2012. All rights reserved. 2 * Copyright (C) Research In Motion Limited 2010-2012. All rights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 ASSERT(renderer->isSVGText()); 57 ASSERT(renderer->isSVGText());
58 RenderBlockFlow* renderBlockFlow = toRenderBlockFlow(renderer); 58 RenderBlockFlow* renderBlockFlow = toRenderBlockFlow(renderer);
59 59
60 // LayoutSVGText only ever contains a single line box. 60 // LayoutSVGText only ever contains a single line box.
61 InlineFlowBox* flowBox = renderBlockFlow->firstLineBox(); 61 InlineFlowBox* flowBox = renderBlockFlow->firstLineBox();
62 ASSERT(flowBox == renderBlockFlow->lastLineBox()); 62 ASSERT(flowBox == renderBlockFlow->lastLineBox());
63 return flowBox; 63 return flowBox;
64 } 64 }
65 65
66 if (renderer->isRenderInline()) { 66 if (renderer->isRenderInline()) {
67 // We're given a LayoutSVGInline or objects that derive from it (RenderS VGTSpan / LayoutSVGTextPath) 67 // We're given a LayoutSVGInline or objects that derive from it (LayoutS VGTSpan / LayoutSVGTextPath)
68 RenderInline* renderInline = toRenderInline(renderer); 68 RenderInline* renderInline = toRenderInline(renderer);
69 69
70 // LayoutSVGInline only ever contains a single line box. 70 // LayoutSVGInline only ever contains a single line box.
71 InlineFlowBox* flowBox = renderInline->firstLineBox(); 71 InlineFlowBox* flowBox = renderInline->firstLineBox();
72 ASSERT(flowBox == renderInline->lastLineBox()); 72 ASSERT(flowBox == renderInline->lastLineBox());
73 return flowBox; 73 return flowBox;
74 } 74 }
75 75
76 ASSERT_NOT_REACHED(); 76 ASSERT_NOT_REACHED();
77 return 0; 77 return 0;
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after
508 int SVGTextQuery::characterNumberAtPosition(const FloatPoint& position) const 508 int SVGTextQuery::characterNumberAtPosition(const FloatPoint& position) const
509 { 509 {
510 CharacterNumberAtPositionData data(position); 510 CharacterNumberAtPositionData data(position);
511 if (!executeQuery(&data, &SVGTextQuery::characterNumberAtPositionCallback)) 511 if (!executeQuery(&data, &SVGTextQuery::characterNumberAtPositionCallback))
512 return -1; 512 return -1;
513 513
514 return data.processedCharacters; 514 return data.processedCharacters;
515 } 515 }
516 516
517 } 517 }
OLDNEW
« no previous file with comments | « Source/core/layout/svg/SVGLayoutTreeAsText.cpp ('k') | Source/core/loader/ImageLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698