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

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

Issue 2950283002: Make UpdateSelectionForMouseDownDispatchingSelectStart() to take SelectionInFlatTree (Closed)
Patch Set: 2017-06-26T17:37:56 Rebase Created 3 years, 5 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/SelectionController.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved.
3 * Copyright (C) 2015 Google Inc. All rights reserved. 3 * Copyright (C) 2015 Google 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 * 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 13 matching lines...) Expand all
24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 */ 25 */
26 26
27 #ifndef SelectionController_h 27 #ifndef SelectionController_h
28 #define SelectionController_h 28 #define SelectionController_h
29 29
30 #include "core/CoreExport.h" 30 #include "core/CoreExport.h"
31 #include "core/dom/SynchronousMutationObserver.h" 31 #include "core/dom/SynchronousMutationObserver.h"
32 #include "core/editing/FrameSelection.h" 32 #include "core/editing/FrameSelection.h"
33 #include "core/editing/TextGranularity.h" 33 #include "core/editing/TextGranularity.h"
34 #include "core/editing/VisibleSelection.h"
35 #include "core/page/EventWithHitTestResults.h" 34 #include "core/page/EventWithHitTestResults.h"
36 #include "platform/heap/Handle.h" 35 #include "platform/heap/Handle.h"
37 36
38 namespace blink { 37 namespace blink {
39 38
40 class HitTestResult; 39 class HitTestResult;
41 class LocalFrame; 40 class LocalFrame;
42 41
43 class CORE_EXPORT SelectionController final 42 class CORE_EXPORT SelectionController final
44 : public GarbageCollectedFinalized<SelectionController>, 43 : public GarbageCollectedFinalized<SelectionController>,
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 const MouseEventWithHitTestResults&); 107 const MouseEventWithHitTestResults&);
109 void SelectClosestWordOrLinkFromMouseEvent( 108 void SelectClosestWordOrLinkFromMouseEvent(
110 const MouseEventWithHitTestResults&); 109 const MouseEventWithHitTestResults&);
111 void SetNonDirectionalSelectionIfNeeded(const SelectionInFlatTree&, 110 void SetNonDirectionalSelectionIfNeeded(const SelectionInFlatTree&,
112 TextGranularity, 111 TextGranularity,
113 EndPointsAdjustmentMode, 112 EndPointsAdjustmentMode,
114 HandleVisibility); 113 HandleVisibility);
115 void SetCaretAtHitTestResult(const HitTestResult&); 114 void SetCaretAtHitTestResult(const HitTestResult&);
116 bool UpdateSelectionForMouseDownDispatchingSelectStart( 115 bool UpdateSelectionForMouseDownDispatchingSelectStart(
117 Node*, 116 Node*,
118 const VisibleSelectionInFlatTree&, 117 const SelectionInFlatTree&,
119 TextGranularity, 118 TextGranularity,
120 HandleVisibility); 119 HandleVisibility);
121 120
122 FrameSelection& Selection() const; 121 FrameSelection& Selection() const;
123 122
124 // Implements |SynchronousMutationObserver|. 123 // Implements |SynchronousMutationObserver|.
125 // TODO(yosin): We should relocate |m_originalBaseInFlatTree| when DOM tree 124 // TODO(yosin): We should relocate |m_originalBaseInFlatTree| when DOM tree
126 // changed. 125 // changed.
127 void ContextDestroyed(Document*) final; 126 void ContextDestroyed(Document*) final;
128 127
(...skipping 16 matching lines...) Expand all
145 }; 144 };
146 SelectionState selection_state_; 145 SelectionState selection_state_;
147 }; 146 };
148 147
149 bool IsLinkSelection(const MouseEventWithHitTestResults&); 148 bool IsLinkSelection(const MouseEventWithHitTestResults&);
150 bool IsExtendingSelection(const MouseEventWithHitTestResults&); 149 bool IsExtendingSelection(const MouseEventWithHitTestResults&);
151 150
152 } // namespace blink 151 } // namespace blink
153 152
154 #endif // SelectionController_h 153 #endif // SelectionController_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/SelectionController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698