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

Side by Side Diff: third_party/WebKit/Source/core/css/DOMWindowCSS.cpp

Issue 2755493004: Replace ASSERT, ASSERT_NOT_REACHED, and RELEASE_ASSERT in core/css/ (Closed)
Patch Set: All windows error are Resolved now. Created 3 years, 8 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 Motorola Mobility Inc. All rights reserved. 2 * Copyright (C) 2012 Motorola Mobility Inc. All rights reserved.
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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above 10 * 2. Redistributions in binary form must reproduce the above
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 if (unresolvedProperty == CSSPropertyVariable) { 45 if (unresolvedProperty == CSSPropertyVariable) {
46 MutableStylePropertySet* dummyStyle = 46 MutableStylePropertySet* dummyStyle =
47 MutableStylePropertySet::create(HTMLStandardMode); 47 MutableStylePropertySet::create(HTMLStandardMode);
48 bool isAnimationTainted = false; 48 bool isAnimationTainted = false;
49 return CSSParser::parseValueForCustomProperty(dummyStyle, "--valid", 49 return CSSParser::parseValueForCustomProperty(dummyStyle, "--valid",
50 nullptr, value, false, 50 nullptr, value, false,
51 nullptr, isAnimationTainted) 51 nullptr, isAnimationTainted)
52 .didParse; 52 .didParse;
53 } 53 }
54 54
55 ASSERT(CSSPropertyMetadata::isEnabledProperty(unresolvedProperty)); 55 DCHECK(CSSPropertyMetadata::isEnabledProperty(unresolvedProperty));
56 56
57 // This will return false when !important is present 57 // This will return false when !important is present
58 MutableStylePropertySet* dummyStyle = 58 MutableStylePropertySet* dummyStyle =
59 MutableStylePropertySet::create(HTMLStandardMode); 59 MutableStylePropertySet::create(HTMLStandardMode);
60 return CSSParser::parseValue(dummyStyle, unresolvedProperty, value, false) 60 return CSSParser::parseValue(dummyStyle, unresolvedProperty, value, false)
61 .didParse; 61 .didParse;
62 } 62 }
63 63
64 bool DOMWindowCSS::supports(const String& conditionText) { 64 bool DOMWindowCSS::supports(const String& conditionText) {
65 return CSSParser::parseSupportsCondition(conditionText); 65 return CSSParser::parseSupportsCondition(conditionText);
66 } 66 }
67 67
68 String DOMWindowCSS::escape(const String& ident) { 68 String DOMWindowCSS::escape(const String& ident) {
69 StringBuilder builder; 69 StringBuilder builder;
70 serializeIdentifier(ident, builder); 70 serializeIdentifier(ident, builder);
71 return builder.toString(); 71 return builder.toString();
72 } 72 }
73 73
74 } // namespace blink 74 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698