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

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

Issue 2709503003: Expand FrameSeleciton::isContentEditable() to increase chances of hoisting update layout (Closed)
Patch Set: 2017-02-22T08:13:55 rebase Created 3 years, 10 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, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
3 * reserved. 3 * 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 * 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 copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 LocalFrame* frame() const { return m_frame; } 103 LocalFrame* frame() const { return m_frame; }
104 Element* rootEditableElement() const { 104 Element* rootEditableElement() const {
105 return computeVisibleSelectionInDOMTreeDeprecated().rootEditableElement(); 105 return computeVisibleSelectionInDOMTreeDeprecated().rootEditableElement();
106 } 106 }
107 Element* rootEditableElementOrDocumentElement() const; 107 Element* rootEditableElementOrDocumentElement() const;
108 ContainerNode* rootEditableElementOrTreeScopeRootNode() const; 108 ContainerNode* rootEditableElementOrTreeScopeRootNode() const;
109 109
110 bool hasEditableStyle() const { 110 bool hasEditableStyle() const {
111 return computeVisibleSelectionInDOMTreeDeprecated().hasEditableStyle(); 111 return computeVisibleSelectionInDOMTreeDeprecated().hasEditableStyle();
112 } 112 }
113 bool isContentEditable() const {
114 return computeVisibleSelectionInDOMTreeDeprecated().isContentEditable();
115 }
116 113
117 // An implementation of |WebFrame::moveCaretSelection()| 114 // An implementation of |WebFrame::moveCaretSelection()|
118 void moveCaretSelection(const IntPoint&); 115 void moveCaretSelection(const IntPoint&);
119 116
120 const VisibleSelection& computeVisibleSelectionInDOMTree() const; 117 const VisibleSelection& computeVisibleSelectionInDOMTree() const;
121 const VisibleSelectionInFlatTree& computeVisibleSelectionInFlatTree() const; 118 const VisibleSelectionInFlatTree& computeVisibleSelectionInFlatTree() const;
122 119
123 // TODO(editing-dev): We should replace 120 // TODO(editing-dev): We should replace
124 // |computeVisibleSelectionInDOMTreeDeprecated()| with update layout and 121 // |computeVisibleSelectionInDOMTreeDeprecated()| with update layout and
125 // |computeVisibleSelectionInDOMTree()| to increase places hoisting update 122 // |computeVisibleSelectionInDOMTree()| to increase places hoisting update
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 350
354 } // namespace blink 351 } // namespace blink
355 352
356 #ifndef NDEBUG 353 #ifndef NDEBUG
357 // Outside the WebCore namespace for ease of invocation from gdb. 354 // Outside the WebCore namespace for ease of invocation from gdb.
358 void showTree(const blink::FrameSelection&); 355 void showTree(const blink::FrameSelection&);
359 void showTree(const blink::FrameSelection*); 356 void showTree(const blink::FrameSelection*);
360 #endif 357 #endif
361 358
362 #endif // FrameSelection_h 359 #endif // FrameSelection_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/editing/Editor.cpp ('k') | third_party/WebKit/Source/core/editing/FrameSelection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698