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

Side by Side Diff: third_party/WebKit/Source/modules/canvas2d/BaseRenderingContext2D.cpp

Issue 1987943002: [wip] unprefix filter Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Decide on BUG 109224, minor test code tweaks. Created 4 years, 7 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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/canvas2d/BaseRenderingContext2D.h" 5 #include "modules/canvas2d/BaseRenderingContext2D.h"
6 6
7 #include "bindings/core/v8/ExceptionMessages.h" 7 #include "bindings/core/v8/ExceptionMessages.h"
8 #include "bindings/core/v8/ExceptionState.h" 8 #include "bindings/core/v8/ExceptionState.h"
9 #include "bindings/core/v8/ExceptionStatePlaceholder.h" 9 #include "bindings/core/v8/ExceptionStatePlaceholder.h"
10 #include "core/css/parser/CSSParser.h" 10 #include "core/css/parser/CSSParser.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 String BaseRenderingContext2D::filter() const 369 String BaseRenderingContext2D::filter() const
370 { 370 {
371 return state().unparsedFilter(); 371 return state().unparsedFilter();
372 } 372 }
373 373
374 void BaseRenderingContext2D::setFilter(const String& filterString) 374 void BaseRenderingContext2D::setFilter(const String& filterString)
375 { 375 {
376 if (filterString == state().unparsedFilter()) 376 if (filterString == state().unparsedFilter())
377 return; 377 return;
378 378
379 CSSValue* filterValue = CSSParser::parseSingleValue(CSSPropertyWebkitFilter, filterString, CSSParserContext(HTMLStandardMode, 0)); 379 CSSValue* filterValue = CSSParser::parseSingleValue(CSSPropertyFilter, filte rString, CSSParserContext(HTMLStandardMode, 0));
380 380
381 if (!filterValue || filterValue->isInitialValue() || filterValue->isInherite dValue()) 381 if (!filterValue || filterValue->isInitialValue() || filterValue->isInherite dValue())
382 return; 382 return;
383 383
384 modifiableState().setUnparsedFilter(filterString); 384 modifiableState().setUnparsedFilter(filterString);
385 modifiableState().setFilter(filterValue); 385 modifiableState().setFilter(filterValue);
386 snapshotStateForFilter(); 386 snapshotStateForFilter();
387 } 387 }
388 388
389 SVGMatrixTearOff* BaseRenderingContext2D::currentTransform() const 389 SVGMatrixTearOff* BaseRenderingContext2D::currentTransform() const
(...skipping 996 matching lines...) Expand 10 before | Expand all | Expand 10 after
1386 1386
1387 imageBuffer()->willOverwriteCanvas(); 1387 imageBuffer()->willOverwriteCanvas();
1388 } 1388 }
1389 1389
1390 DEFINE_TRACE(BaseRenderingContext2D) 1390 DEFINE_TRACE(BaseRenderingContext2D)
1391 { 1391 {
1392 visitor->trace(m_stateStack); 1392 visitor->trace(m_stateStack);
1393 } 1393 }
1394 1394
1395 } // namespace blink 1395 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698