这篇教程C++ willMutate函数代码示例写得很实用,希望能帮到您。
本文整理汇总了C++中willMutate函数的典型用法代码示例。如果您正苦于以下问题:C++ willMutate函数的具体用法?C++ willMutate怎么用?C++ willMutate使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。 在下文中一共展示了willMutate函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。 示例1: mutationScopeExceptionOr<void> PropertySetCSSStyleDeclaration::setProperty(const String& propertyName, const String& value, const String& priority){ StyleAttributeMutationScope mutationScope(this); CSSPropertyID propertyID = cssPropertyID(propertyName); if (isCustomPropertyName(propertyName)) propertyID = CSSPropertyCustom; if (!propertyID) return { }; if (!willMutate()) return { }; bool important = equalIgnoringASCIICase(priority, "important"); if (!important && !priority.isEmpty()) return { }; bool changed; if (propertyID == CSSPropertyCustom) changed = m_propertySet->setCustomProperty(propertyName, value, important, cssParserContext()); else changed = m_propertySet->setProperty(propertyID, value, important, cssParserContext()); didMutate(changed ? PropertyChanged : NoChanges); if (changed) { // CSS DOM requires raising SYNTAX_ERR of parsing failed, but this is too dangerous for compatibility, // see <http://bugs.webkit.org/show_bug.cgi?id=7296>. mutationScope.enqueueMutationRecord(); } return { };}
开发者ID:eocanha,项目名称:webkit,代码行数:33,
示例2: ENABLEvoid PropertySetCSSStyleDeclaration::setProperty(const String& propertyName, const String& value, const String& priority, ExceptionCode& ec){#if ENABLE(MUTATION_OBSERVERS) StyleAttributeMutationScope mutationScope(this);#endif CSSPropertyID propertyID = cssPropertyID(propertyName); if (!propertyID) return; bool important = priority.find("important", 0, false) != notFound; willMutate(); ec = 0; bool changed = m_propertySet->setProperty(propertyID, value, important, contextStyleSheet()); didMutate(changed ? PropertyChanged : NoChanges); if (changed) { // CSS DOM requires raising SYNTAX_ERR of parsing failed, but this is too dangerous for compatibility, // see <http://bugs.webkit.org/show_bug.cgi?id=7296>.#if ENABLE(MUTATION_OBSERVERS) mutationScope.enqueueMutationRecord();#endif }}
开发者ID:dog-god,项目名称:iptv,代码行数:26,
示例3: ASSERTvoid PropertySetCSSStyleDeclaration::clearVariables(ExceptionState&){ ASSERT(RuntimeEnabledFeatures::cssVariablesEnabled()); StyleAttributeMutationScope mutationScope(this); willMutate(); bool changed = m_propertySet->clearVariables(); didMutate(changed ? PropertyChanged : NoChanges); if (changed) mutationScope.enqueueMutationRecord();}
开发者ID:IllusionRom-deprecated,项目名称:android_platform_external_chromium_org_third_party_WebKit,代码行数:10,
示例4: ASSERTbool PropertySetCSSStyleDeclaration::removeVariable(const AtomicString& name){ ASSERT(RuntimeEnabledFeatures::cssVariablesEnabled()); StyleAttributeMutationScope mutationScope(this); willMutate(); bool changed = m_propertySet->removeVariable(name); didMutate(changed ? PropertyChanged : NoChanges); if (changed) mutationScope.enqueueMutationRecord(); return changed;}
开发者ID:Igalia,项目名称:blink,代码行数:11,
示例5: mutationScopevoid AbstractPropertySetCSSStyleDeclaration::setCSSText(const String& text, ExceptionState& exceptionState){ StyleAttributeMutationScope mutationScope(this); willMutate(); // FIXME: Detect syntax errors and set exceptionState. propertySet().parseDeclaration(text, contextStyleSheet()); didMutate(PropertyChanged); mutationScope.enqueueMutationRecord();}
开发者ID:smil-in-javascript,项目名称:blink,代码行数:12,
示例6: mutationScopevoid PropertySetCSSStyleDeclaration::setCssText(const String& text, ExceptionCode&){ StyleAttributeMutationScope mutationScope(this); if (!willMutate()) return; bool changed = m_propertySet->parseDeclaration(text, contextStyleSheet()); didMutate(changed ? PropertyChanged : NoChanges); mutationScope.enqueueMutationRecord(); }
开发者ID:emutavchi,项目名称:WebKitForWayland,代码行数:12,
示例7: mutationScopevoid PropertySetCSSStyleDeclaration::setPropertyInternal(CSSPropertyID propertyID, const String& value, bool important, ExceptionCode& ec){ StyleAttributeMutationScope mutationScope(this); if (!willMutate()) return; ec = 0; bool changed = m_propertySet->setProperty(propertyID, value, important, contextStyleSheet()); didMutate(changed ? PropertyChanged : NoChanges); if (changed) mutationScope.enqueueMutationRecord();}
开发者ID:CannedFish,项目名称:webkit,代码行数:14,
示例8: mutationScopeString PropertySetCSSStyleDeclaration::removeProperty(const String& propertyName, ExceptionCode& ec){ StyleAttributeMutationScope mutationScope(this); CSSPropertyID propertyID = cssPropertyID(propertyName); if (!propertyID) return String(); if (!willMutate()) return String(); ec = 0; String result; bool changed = m_propertySet->removeProperty(propertyID, &result); didMutate(changed ? PropertyChanged : NoChanges); if (changed) mutationScope.enqueueMutationRecord(); return result;}
开发者ID:allsmy,项目名称:webkit,代码行数:20,
示例9: mutationScopevoid PropertySetCSSStyleDeclaration::setProperty(const String& propertyName, const String& value, const String& priority, ExceptionState& exceptionState){ StyleAttributeMutationScope mutationScope(this); CSSPropertyID propertyID = cssPropertyID(propertyName); if (!propertyID) return; bool important = priority.find("important", 0, false) != kNotFound; willMutate(); bool changed = m_propertySet->setProperty(propertyID, value, important, contextStyleSheet()); didMutate(changed ? PropertyChanged : NoChanges); if (changed) { // CSS DOM requires raising SyntaxError of parsing failed, but this is too dangerous for compatibility, // see <http://bugs.webkit.org/show_bug.cgi?id=7296>. mutationScope.enqueueMutationRecord(); }}
开发者ID:Igalia,项目名称:blink,代码行数:21,
注:本文中的willMutate函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 C++ willSendRequest函数代码示例 C++ wil_err函数代码示例 |