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

Side by Side Diff: third_party/WebKit/Source/core/testing/Internals.cpp

Issue 2450793002: Call invalidatePaintForTickmarks() in Internals::addTextMatchMarker() (Closed)
Patch Set: runAfterLayoutAndPaint Created 4 years, 1 month 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 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2013 Apple Inc. All rights reserved. 3 * Copyright (C) 2013 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 973 matching lines...) Expand 10 before | Expand all | Expand 10 after
984 if (!marker) 984 if (!marker)
985 return String(); 985 return String();
986 return marker->description(); 986 return marker->description();
987 } 987 }
988 988
989 void Internals::addTextMatchMarker(const Range* range, bool isActive) { 989 void Internals::addTextMatchMarker(const Range* range, bool isActive) {
990 ASSERT(range); 990 ASSERT(range);
991 range->ownerDocument().updateStyleAndLayoutIgnorePendingStylesheets(); 991 range->ownerDocument().updateStyleAndLayoutIgnorePendingStylesheets();
992 range->ownerDocument().markers().addTextMatchMarker(EphemeralRange(range), 992 range->ownerDocument().markers().addTextMatchMarker(EphemeralRange(range),
993 isActive); 993 isActive);
994 range->ownerDocument().view()->invalidatePaintForTickmarks();
Xianzhu 2016/11/01 06:41:22 Please add a comment like: This simulates what the
hiroshige 2016/11/04 09:28:06 Done.
994 } 995 }
995 996
996 static bool parseColor(const String& value, 997 static bool parseColor(const String& value,
997 Color& color, 998 Color& color,
998 ExceptionState& exceptionState, 999 ExceptionState& exceptionState,
999 String errorMessage) { 1000 String errorMessage) {
1000 if (!color.setFromString(value)) { 1001 if (!color.setFromString(value)) {
1001 exceptionState.throwDOMException(InvalidAccessError, errorMessage); 1002 exceptionState.throwDOMException(InvalidAccessError, errorMessage);
1002 return false; 1003 return false;
1003 } 1004 }
(...skipping 2007 matching lines...) Expand 10 before | Expand all | Expand 10 after
3011 return ClientRect::create(); 3012 return ClientRect::create();
3012 3013
3013 return ClientRect::create(FloatRect(node->layoutObject()->visualRect())); 3014 return ClientRect::create(FloatRect(node->layoutObject()->visualRect()));
3014 } 3015 }
3015 3016
3016 void Internals::crash() { 3017 void Internals::crash() {
3017 CHECK(false) << "Intentional crash"; 3018 CHECK(false) << "Intentional crash";
3018 } 3019 }
3019 3020
3020 } // namespace blink 3021 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698