当前位置: 首页>>代码示例>>C++>>正文


C++ ConversionCheckers::append方法代码示例

本文整理汇总了C++中ConversionCheckers::append方法的典型用法代码示例。如果您正苦于以下问题:C++ ConversionCheckers::append方法的具体用法?C++ ConversionCheckers::append怎么用?C++ ConversionCheckers::append使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ConversionCheckers的用法示例。


在下文中一共展示了ConversionCheckers::append方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1:

PassOwnPtr<InterpolationValue> CSSImageListInterpolationType::maybeConvertNeutral(const UnderlyingValue& underlyingValue, ConversionCheckers& conversionCheckers) const
{
    if (!underlyingValue) {
        conversionCheckers.append(UnderlyingImageListChecker::create(*this, nullptr));
        return nullptr;
    }
    conversionCheckers.append(UnderlyingImageListChecker::create(*this, underlyingValue->clone()));
    return underlyingValue->clone();
}
开发者ID:howardroark2018,项目名称:chromium,代码行数:9,代码来源:CSSImageListInterpolationType.cpp

示例2: maybeConvertInherit

InterpolationValue CSSPaintInterpolationType::maybeConvertInherit(const StyleResolverState& state, ConversionCheckers& conversionCheckers) const
{
    if (!state.parentStyle())
        return nullptr;
    StyleColor parentColor;
    if (!PaintPropertyFunctions::getColor(cssProperty(), *state.parentStyle(), parentColor)) {
        conversionCheckers.append(ParentPaintChecker::create(cssProperty()));
        return nullptr;
    }
    conversionCheckers.append(ParentPaintChecker::create(cssProperty(), parentColor));
    return InterpolationValue(CSSColorInterpolationType::createInterpolableColor(parentColor));
}
开发者ID:endlessm,项目名称:chromium-browser,代码行数:12,代码来源:CSSPaintInterpolationType.cpp

示例3: maybeConvertInherit

InterpolationValue CSSBasicShapeInterpolationType::maybeConvertInherit(const StyleResolverState& state, ConversionCheckers& conversionCheckers) const
{
    const BasicShape* shape = BasicShapePropertyFunctions::getBasicShape(cssProperty(), *state.parentStyle());
    // const_cast to take a ref.
    conversionCheckers.append(InheritedShapeChecker::create(cssProperty(), const_cast<BasicShape*>(shape)));
    return BasicShapeInterpolationFunctions::maybeConvertBasicShape(shape, state.parentStyle()->effectiveZoom());
}
开发者ID:aobzhirov,项目名称:ChromiumGStreamerBackend,代码行数:7,代码来源:CSSBasicShapeInterpolationType.cpp

示例4: maybeConvertNeutral

InterpolationValue CSSBasicShapeInterpolationType::maybeConvertNeutral(const InterpolationValue& underlying, ConversionCheckers& conversionCheckers) const
{
    // const_cast is for taking refs.
    NonInterpolableValue* nonInterpolableValue = const_cast<NonInterpolableValue*>(underlying.nonInterpolableValue.get());
    conversionCheckers.append(UnderlyingCompatibilityChecker::create(nonInterpolableValue));
    return InterpolationValue(BasicShapeInterpolationFunctions::createNeutralValue(*underlying.nonInterpolableValue), nonInterpolableValue);
}
开发者ID:aobzhirov,项目名称:ChromiumGStreamerBackend,代码行数:7,代码来源:CSSBasicShapeInterpolationType.cpp

示例5: maybeConvertInherit

InterpolationValue CSSScaleInterpolationType::maybeConvertInherit(
    const StyleResolverState& state,
    ConversionCheckers& conversionCheckers) const {
  Scale parentScale(state.parentStyle()->scale());
  conversionCheckers.append(ParentScaleChecker::create(parentScale));
  return InterpolationValue(parentScale.createInterpolableValue());
}
开发者ID:ollie314,项目名称:chromium,代码行数:7,代码来源:CSSScaleInterpolationType.cpp

示例6: maybeConvertValue

InterpolationValue CSSTransformInterpolationType::maybeConvertValue(
    const CSSValue& value,
    const StyleResolverState& state,
    ConversionCheckers& conversionCheckers) const {
  if (value.isValueList()) {
    CSSLengthArray lengthArray;
    for (const CSSValue* item : toCSSValueList(value)) {
      const CSSFunctionValue& transformFunction = toCSSFunctionValue(*item);
      if (transformFunction.functionType() == CSSValueMatrix ||
          transformFunction.functionType() == CSSValueMatrix3d) {
        lengthArray.typeFlags.set(CSSPrimitiveValue::UnitTypePixels);
        continue;
      }
      for (const CSSValue* argument : transformFunction) {
        const CSSPrimitiveValue& primitiveValue =
            toCSSPrimitiveValue(*argument);
        if (!primitiveValue.isLength())
          continue;
        primitiveValue.accumulateLengthArray(lengthArray);
      }
    }
    std::unique_ptr<InterpolationType::ConversionChecker> lengthUnitsChecker =
        LengthUnitsChecker::maybeCreate(std::move(lengthArray), state);

    if (lengthUnitsChecker)
      conversionCheckers.append(std::move(lengthUnitsChecker));
  }

  TransformOperations transform;
  TransformBuilder::createTransformOperations(
      value, state.cssToLengthConversionData(), transform);
  return convertTransform(std::move(transform));
}
开发者ID:ollie314,项目名称:chromium,代码行数:33,代码来源:CSSTransformInterpolationType.cpp

示例7: convertShadowList

PassOwnPtr<InterpolationValue> CSSShadowListInterpolationType::maybeConvertInherit(const StyleResolverState& state, ConversionCheckers& conversionCheckers) const
{
    if (!state.parentStyle())
        return nullptr;
    const ShadowList* parentShadowList = ShadowListPropertyFunctions::getShadowList(cssProperty(), *state.parentStyle());
    conversionCheckers.append(ParentShadowListChecker::create(*this, cssProperty(), const_cast<ShadowList*>(parentShadowList))); // Take ref.
    return convertShadowList(parentShadowList, state.parentStyle()->effectiveZoom());
}
开发者ID:shaoboyan,项目名称:chromium-crosswalk,代码行数:8,代码来源:CSSShadowListInterpolationType.cpp

示例8: maybeConvertInherit

InterpolationValue CSSClipInterpolationType::maybeConvertInherit(const StyleResolverState& state, ConversionCheckers& conversionCheckers) const
{
    ClipAutos parentAutos = getClipAutos(*state.parentStyle());
    conversionCheckers.append(ParentAutosChecker::create(parentAutos));
    if (parentAutos.isAuto)
        return nullptr;
    return createClipValue(state.parentStyle()->clip(), state.parentStyle()->effectiveZoom());
}
开发者ID:aobzhirov,项目名称:ChromiumGStreamerBackend,代码行数:8,代码来源:CSSClipInterpolationType.cpp


注:本文中的ConversionCheckers::append方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。