本文整理汇总了C++中cueDidChange函数的典型用法代码示例。如果您正苦于以下问题:C++ cueDidChange函数的具体用法?C++ cueDidChange怎么用?C++ cueDidChange使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了cueDidChange函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: if
void TextTrackCue::setVertical(const String& value, ExceptionCode& ec)
{
// http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#dom-texttrackcue-vertical
// On setting, the text track cue writing direction must be set to the value given
// in the first cell of the row in the table above whose second cell is a
// case-sensitive match for the new value, if any. If none of the values match, then
// the user agent must instead throw a SyntaxError exception.
WritingDirection direction = m_writingDirection;
if (value == horizontalKeyword())
direction = Horizontal;
else if (value == verticalGrowingLeftKeyword())
direction = VerticalGrowingLeft;
else if (value == verticalGrowingRightKeyword())
direction = VerticalGrowingRight;
else
ec = SYNTAX_ERR;
if (direction == m_writingDirection)
return;
cueWillChange();
m_writingDirection = direction;
cueDidChange();
}
开发者ID:fmalita,项目名称:webkit,代码行数:25,代码来源:TextTrackCue.cpp
示例2: cueWillChange
void TextTrackCue::setId(const AtomicString& id) {
if (m_id == id)
return;
cueWillChange();
m_id = id;
cueDidChange();
}
开发者ID:mirror,项目名称:chromium,代码行数:8,代码来源:TextTrackCue.cpp
示例3: cueWillChange
void VTTCue::setSnapToLines(bool value)
{
if (m_snapToLines == value)
return;
cueWillChange();
m_snapToLines = value;
cueDidChange();
}
开发者ID:kjthegod,项目名称:WebKit,代码行数:9,代码来源:VTTCue.cpp
示例4: cueWillChange
void TextTrackCue::setEndTime(double value)
{
if (m_endTime == value)
return;
cueWillChange();
m_endTime = value;
cueDidChange();
}
开发者ID:Moondee,项目名称:Artemis,代码行数:9,代码来源:TextTrackCue.cpp
示例5: cueWillChange
void TextTrackCue::setText(const String& text)
{
if (m_content == text)
return;
cueWillChange();
// Clear the document fragment but don't bother to create it again just yet as we can do that
// when it is requested.
m_webVTTNodeTree = 0;
m_content = text;
cueDidChange();
}
开发者ID:fmalita,项目名称:webkit,代码行数:12,代码来源:TextTrackCue.cpp
示例6: cueWillChange
void TextTrackCue::setStartTime(double value, ExceptionState& exceptionState)
{
// NaN, Infinity and -Infinity values should trigger a TypeError.
if (isInfiniteOrNonNumber(value, exceptionState))
return;
// TODO(93143): Add spec-compliant behavior for negative time values.
if (m_startTime == value || value < 0)
return;
cueWillChange();
m_startTime = value;
cueDidChange();
}
开发者ID:glenkim-dev,项目名称:blink-crosswalk,代码行数:14,代码来源:TextTrackCue.cpp
示例7: provided
void VTTCue::setLine(int position, ExceptionState& exceptionState)
{
// http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#dom-texttrackcue-line
// On setting, if the text track cue snap-to-lines flag is not set, and the new
// value is negative or greater than 100, then throw an IndexSizeError exception.
if (!m_snapToLines && (position < 0 || position > 100)) {
exceptionState.throwDOMException(IndexSizeError, "The snap-to-lines flag is not set, and the value provided (" + String::number(position) + ") is not between 0 and 100.");
return;
}
// Otherwise, set the text track cue line position to the new value.
if (m_linePosition == position)
return;
cueWillChange();
m_linePosition = position;
m_computedLinePosition = calculateComputedLinePosition();
cueDidChange();
}
开发者ID:kjthegod,项目名称:WebKit,代码行数:19,代码来源:VTTCue.cpp
示例8: if
void VTTCue::setVertical(const String& value)
{
WritingDirection direction = m_writingDirection;
if (value == horizontalKeyword())
direction = Horizontal;
else if (value == verticalGrowingLeftKeyword())
direction = VerticalGrowingLeft;
else if (value == verticalGrowingRightKeyword())
direction = VerticalGrowingRight;
else
ASSERT_NOT_REACHED();
if (direction == m_writingDirection)
return;
cueWillChange();
m_writingDirection = direction;
cueDidChange();
}
开发者ID:kjthegod,项目名称:WebKit,代码行数:19,代码来源:VTTCue.cpp
注:本文中的cueDidChange函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论