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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutVTTCue.cpp

Issue 2589143003: Add 'get' prefix for Settings.in generated code. (Closed)
Patch Set: Only get prefix and no capitalization. Created 3 years, 11 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
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 24 matching lines...) Expand all
35 35
36 namespace { 36 namespace {
37 37
38 class SnapToLinesLayouter { 38 class SnapToLinesLayouter {
39 STACK_ALLOCATED(); 39 STACK_ALLOCATED();
40 40
41 public: 41 public:
42 SnapToLinesLayouter(LayoutVTTCue& cueBox, const IntRect& controlsRect) 42 SnapToLinesLayouter(LayoutVTTCue& cueBox, const IntRect& controlsRect)
43 : m_cueBox(cueBox), m_controlsRect(controlsRect), m_margin(0.0) { 43 : m_cueBox(cueBox), m_controlsRect(controlsRect), m_margin(0.0) {
44 if (Settings* settings = m_cueBox.document().settings()) 44 if (Settings* settings = m_cueBox.document().settings())
45 m_margin = settings->textTrackMarginPercentage() / 100.0; 45 m_margin = settings->getTextTrackMarginPercentage() / 100.0;
46 } 46 }
47 47
48 void layout(); 48 void layout();
49 49
50 private: 50 private:
51 bool isOutside(const IntRect&) const; 51 bool isOutside(const IntRect&) const;
52 bool isOverlapping() const; 52 bool isOverlapping() const;
53 LayoutUnit computeInitialPositionAdjustment(LayoutUnit&, 53 LayoutUnit computeInitialPositionAdjustment(LayoutUnit&,
54 LayoutUnit, 54 LayoutUnit,
55 LayoutUnit) const; 55 LayoutUnit) const;
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 LayoutState state(*this); 358 LayoutState state(*this);
359 359
360 // http://dev.w3.org/html5/webvtt/#dfn-apply-webvtt-cue-settings - step 13. 360 // http://dev.w3.org/html5/webvtt/#dfn-apply-webvtt-cue-settings - step 13.
361 if (!std::isnan(m_snapToLinesPosition)) 361 if (!std::isnan(m_snapToLinesPosition))
362 SnapToLinesLayouter(*this, computeControlsRect()).layout(); 362 SnapToLinesLayouter(*this, computeControlsRect()).layout();
363 else 363 else
364 repositionCueSnapToLinesNotSet(); 364 repositionCueSnapToLinesNotSet();
365 } 365 }
366 366
367 } // namespace blink 367 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutText.cpp ('k') | third_party/WebKit/Source/core/layout/TextAutosizer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698