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

Side by Side Diff: Source/core/rendering/RenderTextTrackCue.cpp

Issue 50903009: Remove virtual where not needed in TextTrackCue (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add FINAL to TextTrackCueBox Created 7 years, 1 month 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
« no previous file with comments | « Source/core/html/track/TextTrackCue.cpp ('k') | no next file » | 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) 2012 Victor Carbune (victor@rosedu.org) 2 * Copyright (C) 2012 Victor Carbune (victor@rosedu.org)
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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 // If WebVTT Regions are used, the regular WebVTT layout algorithm is no 44 // If WebVTT Regions are used, the regular WebVTT layout algorithm is no
45 // longer necessary, since cues having the region parameter set do not have 45 // longer necessary, since cues having the region parameter set do not have
46 // any positioning parameters. Also, in this case, the regions themselves 46 // any positioning parameters. Also, in this case, the regions themselves
47 // have positioning information. 47 // have positioning information.
48 if (!m_cue->regionId().isEmpty()) 48 if (!m_cue->regionId().isEmpty())
49 return; 49 return;
50 50
51 LayoutStateMaintainer statePusher(view(), this, locationOffset(), hasTransfo rm() || hasReflection() || style()->isFlippedBlocksWritingMode()); 51 LayoutStateMaintainer statePusher(view(), this, locationOffset(), hasTransfo rm() || hasReflection() || style()->isFlippedBlocksWritingMode());
52 52
53 if (m_cue->cueType() == TextTrackCue::WebVTT) { 53 if (m_cue->snapToLines())
54 if (m_cue->snapToLines()) 54 repositionCueSnapToLinesSet();
55 repositionCueSnapToLinesSet(); 55 else
56 else 56 repositionCueSnapToLinesNotSet();
57 repositionCueSnapToLinesNotSet();
58 }
59 57
60 statePusher.pop(); 58 statePusher.pop();
61 } 59 }
62 60
63 bool RenderTextTrackCue::findFirstLineBox(InlineFlowBox*& firstLineBox) 61 bool RenderTextTrackCue::findFirstLineBox(InlineFlowBox*& firstLineBox)
64 { 62 {
65 if (firstChild()->isRenderInline()) 63 if (firstChild()->isRenderInline())
66 firstLineBox = toRenderInline(firstChild())->firstLineBox(); 64 firstLineBox = toRenderInline(firstChild())->firstLineBox();
67 else 65 else
68 return false; 66 return false;
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 } 259 }
262 } 260 }
263 261
264 void RenderTextTrackCue::repositionCueSnapToLinesNotSet() 262 void RenderTextTrackCue::repositionCueSnapToLinesNotSet()
265 { 263 {
266 // FIXME: Implement overlapping detection when snap-to-lines is not set. htt p://wkb.ug/84296 264 // FIXME: Implement overlapping detection when snap-to-lines is not set. htt p://wkb.ug/84296
267 } 265 }
268 266
269 } // namespace WebCore 267 } // namespace WebCore
270 268
OLDNEW
« no previous file with comments | « Source/core/html/track/TextTrackCue.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698