1 /* 2 * Copyright (c) 2005-2006, Haiku, Inc. 3 * Distributed under the terms of the MIT license. 4 * 5 * Author: 6 * DarkWyrm <darkwyrm@earthlink.net> 7 */ 8 #include "PreviewColumn.h" 9 #include "ResFields.h" 10 #include <stdio.h> 11 12 PreviewColumn::PreviewColumn(const char *title, float width, 13 float minWidth, float maxWidth) 14 : BTitledColumn(title, width, minWidth, maxWidth) 15 { 16 } 17 18 void 19 PreviewColumn::DrawField(BField* field, BRect rect, BView* parent) 20 { 21 PreviewField *pField = (PreviewField*)field; 22 pField->DrawField(rect,parent); 23 } 24 25 bool 26 PreviewColumn::AcceptsField(const BField* field) const 27 { 28 return dynamic_cast<const PreviewField*>(field); 29 } 30