OLD | NEW |
1 /* | 1 /* |
2 * This file is part of the select element renderer in WebCore. | 2 * This file is part of the select element renderer in WebCore. |
3 * | 3 * |
4 * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. | 4 * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 LayoutRect itemBoundingBoxRect(const LayoutPoint&, int index); | 51 LayoutRect itemBoundingBoxRect(const LayoutPoint&, int index); |
52 | 52 |
53 bool scrollToRevealElementAtListIndex(int index); | 53 bool scrollToRevealElementAtListIndex(int index); |
54 bool listIndexIsVisible(int index); | 54 bool listIndexIsVisible(int index); |
55 | 55 |
56 int scrollToward(const IntPoint&); // Returns the new index or -1 if no scro
ll occurred | 56 int scrollToward(const IntPoint&); // Returns the new index or -1 if no scro
ll occurred |
57 | 57 |
58 int size() const; | 58 int size() const; |
59 | 59 |
60 private: | 60 private: |
61 HTMLSelectElement* selectElement() const; | 61 Result<HTMLSelectElement> selectElement() const; |
62 | 62 |
63 virtual const char* renderName() const { return "RenderListBox"; } | 63 virtual const char* renderName() const { return "RenderListBox"; } |
64 | 64 |
65 virtual bool isListBox() const { return true; } | 65 virtual bool isListBox() const { return true; } |
66 | 66 |
67 virtual void updateFromElement(); | 67 virtual void updateFromElement(); |
68 virtual bool canBeReplacedWithInlineRunIn() const OVERRIDE; | 68 virtual bool canBeReplacedWithInlineRunIn() const OVERRIDE; |
69 virtual bool hasControlClip() const { return true; } | 69 virtual bool hasControlClip() const { return true; } |
70 virtual void paintObject(PaintInfo&, const LayoutPoint&); | 70 virtual void paintObject(PaintInfo&, const LayoutPoint&); |
71 virtual LayoutRect controlClipRect(const LayoutPoint&) const; | 71 virtual LayoutRect controlClipRect(const LayoutPoint&) const; |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 ASSERT_WITH_SECURITY_IMPLICATION(!object || object->isListBox()); | 156 ASSERT_WITH_SECURITY_IMPLICATION(!object || object->isListBox()); |
157 return static_cast<RenderListBox*>(object); | 157 return static_cast<RenderListBox*>(object); |
158 } | 158 } |
159 | 159 |
160 // This will catch anyone doing an unnecessary cast. | 160 // This will catch anyone doing an unnecessary cast. |
161 void toRenderListBox(const RenderListBox*); | 161 void toRenderListBox(const RenderListBox*); |
162 | 162 |
163 } // namepace WebCore | 163 } // namepace WebCore |
164 | 164 |
165 #endif // RenderListBox_h | 165 #endif // RenderListBox_h |
OLD | NEW |