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

Side by Side Diff: Source/core/rendering/RenderListBox.h

Issue 33983003: Introduce DEFINE_RENDER_OBJECT_TYPE_CASTS to replace manual toRenderFoo, and use it (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 2 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 | « Source/core/rendering/RenderLayerModelObject.h ('k') | Source/core/rendering/RenderListItem.h » ('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 * 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 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 153
154 bool m_optionsChanged; 154 bool m_optionsChanged;
155 bool m_scrollToRevealSelectionAfterLayout; 155 bool m_scrollToRevealSelectionAfterLayout;
156 bool m_inAutoscroll; 156 bool m_inAutoscroll;
157 int m_optionsWidth; 157 int m_optionsWidth;
158 int m_indexOffset; 158 int m_indexOffset;
159 159
160 RefPtr<Scrollbar> m_vBar; 160 RefPtr<Scrollbar> m_vBar;
161 }; 161 };
162 162
163 inline RenderListBox* toRenderListBox(RenderObject* object) 163 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderListBox, isListBox());
164 {
165 ASSERT_WITH_SECURITY_IMPLICATION(!object || object->isListBox());
166 return static_cast<RenderListBox*>(object);
167 }
168
169 // This will catch anyone doing an unnecessary cast.
170 void toRenderListBox(const RenderListBox*);
171 164
172 } // namepace WebCore 165 } // namepace WebCore
173 166
174 #endif // RenderListBox_h 167 #endif // RenderListBox_h
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderLayerModelObject.h ('k') | Source/core/rendering/RenderListItem.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698