added a JScrollPane to vertically scroll content in the main panel
git-svn-id: svn://anubis/gvsu@432 45c1a28c-8058-47b2-ae61-ca45b979098e
This commit is contained in:
parent
efd4358b2c
commit
327cc8b91d
@ -11,19 +11,21 @@ import java.util.*;
|
||||
*/
|
||||
class RetirementCalculatorPanel extends JPanel implements ActionListener
|
||||
{
|
||||
private JButton b;
|
||||
private RetirementCalculatorModel myModel;
|
||||
|
||||
public RetirementCalculatorPanel()
|
||||
{
|
||||
setLayout(new BorderLayout());
|
||||
b = new JButton("Hi There");
|
||||
b.addActionListener(this);
|
||||
add("South", b);
|
||||
JPanel inner = new JPanel(new GridLayout(3, 2));
|
||||
JButton b = new JButton("HI");
|
||||
inner.add(b);
|
||||
JScrollPane scrollpane = new JScrollPane(inner,
|
||||
ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS,
|
||||
ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
|
||||
add(scrollpane);
|
||||
}
|
||||
|
||||
public void actionPerformed(ActionEvent e)
|
||||
{
|
||||
b.setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -37,13 +37,16 @@ public class RetirementCalculatorModel
|
||||
|
||||
private double calculateRetirementFactor()
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
private double calculateSocialSecurity()
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
private double calculateSavingsFactor()
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user