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

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

Issue 1759173002: [Layout API] Create api/LayoutLIItem and use it in html/HTMLLIElement (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « third_party/WebKit/Source/core/layout/api/LayoutItem.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef LayoutLIItem_h
6 #define LayoutLIItem_h
7
8 #include "core/layout/LayoutListItem.h"
9 #include "core/layout/api/LayoutBoxItem.h"
10
11 namespace blink {
12
13 class LayoutLIItem : public LayoutBoxItem {
14 public:
15 explicit LayoutLIItem(LayoutListItem* layoutListItem)
16 : LayoutBoxItem(layoutListItem)
17 {
18 }
19
20 explicit LayoutLIItem(const LayoutItem& item)
21 : LayoutBoxItem(item)
22 {
23 ASSERT(!item || item.isListItem());
24 }
25
26 explicit LayoutLIItem(std::nullptr_t) : LayoutBoxItem(nullptr) { }
27
28 LayoutLIItem() { }
29
30 void setNotInList(bool notInList)
31 {
32 return toListItem()->setNotInList(notInList);
33 }
34
35 private:
36 LayoutListItem* toListItem()
37 {
38 return toLayoutListItem(layoutObject());
39 }
40
41 const LayoutListItem* toListItem() const
42 {
43 return toLayoutListItem(layoutObject());
44 }
45 };
46
47 } // namespace blink
48
49 #endif // LayoutLIItem_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/api/LayoutItem.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698