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

Side by Side Diff: third_party/WebKit/Source/core/editing/FrameSelection.cpp

Issue 2852573002: Rename InvalidatePaintIfNeeded to drop deprecated IfNeeded suffix. (Closed)
Patch Set: Created 3 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 /* 1 /*
2 * Copyright (C) 2004, 2008, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2008, 2009, 2010 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
464 } 464 }
465 465
466 void FrameSelection::LayoutBlockWillBeDestroyed(const LayoutBlock& block) { 466 void FrameSelection::LayoutBlockWillBeDestroyed(const LayoutBlock& block) {
467 frame_caret_->LayoutBlockWillBeDestroyed(block); 467 frame_caret_->LayoutBlockWillBeDestroyed(block);
468 } 468 }
469 469
470 void FrameSelection::UpdateStyleAndLayoutIfNeeded() { 470 void FrameSelection::UpdateStyleAndLayoutIfNeeded() {
471 frame_caret_->UpdateStyleAndLayoutIfNeeded(); 471 frame_caret_->UpdateStyleAndLayoutIfNeeded();
472 } 472 }
473 473
474 void FrameSelection::InvalidatePaintIfNeeded( 474 void FrameSelection::InvalidatePaint(const LayoutBlock& block,
475 const LayoutBlock& block, 475 const PaintInvalidatorContext& context) {
476 const PaintInvalidatorContext& context) { 476 frame_caret_->InvalidatePaint(block, context);
477 frame_caret_->InvalidatePaintIfNeeded(block, context);
478 } 477 }
479 478
480 bool FrameSelection::ShouldPaintCaret(const LayoutBlock& block) const { 479 bool FrameSelection::ShouldPaintCaret(const LayoutBlock& block) const {
481 DCHECK_GE(GetDocument().Lifecycle().GetState(), 480 DCHECK_GE(GetDocument().Lifecycle().GetState(),
482 DocumentLifecycle::kLayoutClean); 481 DocumentLifecycle::kLayoutClean);
483 bool result = frame_caret_->ShouldPaintCaret(block); 482 bool result = frame_caret_->ShouldPaintCaret(block);
484 DCHECK(!result || (ComputeVisibleSelectionInDOMTreeDeprecated().IsCaret() && 483 DCHECK(!result || (ComputeVisibleSelectionInDOMTreeDeprecated().IsCaret() &&
485 ComputeVisibleSelectionInDOMTree().HasEditableStyle())); 484 ComputeVisibleSelectionInDOMTree().HasEditableStyle()));
486 return result; 485 return result;
487 } 486 }
(...skipping 693 matching lines...) Expand 10 before | Expand all | Expand 10 after
1181 } 1180 }
1182 1181
1183 void showTree(const blink::FrameSelection* sel) { 1182 void showTree(const blink::FrameSelection* sel) {
1184 if (sel) 1183 if (sel)
1185 sel->ShowTreeForThis(); 1184 sel->ShowTreeForThis();
1186 else 1185 else
1187 LOG(INFO) << "Cannot showTree for <null> FrameSelection."; 1186 LOG(INFO) << "Cannot showTree for <null> FrameSelection.";
1188 } 1187 }
1189 1188
1190 #endif 1189 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/editing/FrameSelection.h ('k') | third_party/WebKit/Source/core/frame/FrameView.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698