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

Side by Side Diff: third_party/WebKit/Source/core/layout/api/SelectionState.h

Issue 2732643004: Add operator<< to SelectionState for debug logging. (Closed)
Patch Set: Created 3 years, 9 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef SelectionState_h 5 #ifndef SelectionState_h
6 #define SelectionState_h 6 #define SelectionState_h
7 7
8 #ifndef NDEBUG
9 #include <iosfwd>
10 #include "core/CoreExport.h"
11 #endif
12
8 namespace blink { 13 namespace blink {
9 14
10 enum SelectionState { 15 enum SelectionState {
11 // The object is not selected. 16 // The object is not selected.
12 SelectionNone, 17 SelectionNone,
13 // The object either contains the start of a selection run or is the start of 18 // The object either contains the start of a selection run or is the start of
14 // a run. 19 // a run.
15 SelectionStart, 20 SelectionStart,
16 // The object is fully encompassed by a selection run. 21 // The object is fully encompassed by a selection run.
17 SelectionInside, 22 SelectionInside,
18 // The object either contains the end of a selection run or is the end of a 23 // The object either contains the end of a selection run or is the end of a
19 // run. 24 // run.
20 SelectionEnd, 25 SelectionEnd,
21 // The object contains an entire run or is the sole selected object in that 26 // The object contains an entire run or is the sole selected object in that
22 // run. 27 // run.
23 SelectionBoth 28 SelectionBoth
24 }; 29 };
25 30
31 #ifndef NDEBUG
32 CORE_EXPORT std::ostream& operator<<(std::ostream&, const SelectionState&);
33 #endif
34
26 } // namespace blink 35 } // namespace blink
27 36
28 #endif // SelectionState_h 37 #endif // SelectionState_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698