01: /*
02: * Copyright (C) 2005 Jeff Tassin
03: *
04: * This library is free software; you can redistribute it and/or
05: * modify it under the terms of the GNU Lesser General Public
06: * License as published by the Free Software Foundation; either
07: * version 2.1 of the License, or (at your option) any later version.
08: *
09: * This library is distributed in the hope that it will be useful,
10: * but WITHOUT ANY WARRANTY; without even the implied warranty of
11: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12: * Lesser General Public License for more details.
13: *
14: * You should have received a copy of the GNU Lesser General Public
15: * License along with this library; if not, write to the Free Software
16: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17: */
18:
19: package com.jeta.swingbuilder.gui.beanmgr;
20:
21: import java.awt.BorderLayout;
22:
23: import com.jeta.forms.components.panel.FormPanel;
24: import com.jeta.open.gui.framework.JETAPanel;
25:
26: /**
27: * View for configuring an imported Java Bean
28: *
29: * @author Jeff Tassin
30: */
31: public class BeanDefinitionView extends JETAPanel {
32: /**
33: * The view panel
34: */
35: private FormPanel m_view;
36:
37: /**
38: * ctor
39: */
40: public BeanDefinitionView() {
41: m_view = new FormPanel(
42: "com/jeta/swingbuilder/gui/beanmgr/beanDefinition.jfrm");
43: setLayout(new BorderLayout());
44: add(m_view, BorderLayout.CENTER);
45: }
46:
47: public String getBeanName() {
48: String bname = m_view
49: .getText(BeanDefinitionNames.ID_BEAN_CLASS);
50: bname = bname.replace('/', '.');
51: bname = bname.replace('\\', '.');
52: return bname;
53: }
54:
55: public boolean isScrollable() {
56: return m_view.isSelected(BeanDefinitionNames.ID_SCROLLABLE);
57: }
58: }
|