Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * Homework 3: Primitive Directory & Copier
- Paul MacLean (MAC7537@calu.edu), Michael Gorse (GOR9632@calu.edu), Anthony Carrola (CAR3766@calu.edu)
- Group 8 (2^3)
- CET 350 - Technical Computer using Java
- */
- import java.io.*;
- import java.awt.*;
- import java.util.*;
- import java.lang.*;
- import java.awt.List;
- import java.awt.event.*;
- class Bounce extends Frame implements ActionListener,WindowListener
- {
- private static final long serialVersionUID = 1L;
- private static int FRAME_X = 800;
- private static int FRAME_Y = 500;
- private static int NetBarWidth = 300;
- private static int MenuElementXSize = 70;
- private static int MenuElementYSize = 30;
- private static int MenuElementYPos = FRAME_Y - 50;
- private Button RunButton = new Button("Run");
- private Button CircleButton = new Button("Circle");
- private Button TailButton = new Button("Tail");
- private Button ClearButton = new Button("Clear");
- private Button QuitButton = new Button("Quit");
- private Panel SpeedBarPanel = new Panel();
- private Scrollbar SpeedBar = new Scrollbar(Scrollbar.HORIZONTAL, 50, 1, 2, 100);
- //private Scrollbar SizeBar = new Scrollbar(Scrollbar.HORIZONTAL, 50, 0, 2, 100);
- private Label SpeedLabel = new Label("Speed");
- private Label SizeDisplay = new Label("Size");
- Bounce() {
- drawFrame();
- this.add(SpeedBar);
- SpeedBar.setVisible(true);
- this.setSize(FRAME_X, FRAME_Y); //OFFSET 32Y
- this.setVisible(true);
- this.setResizable(true);
- this.setTitle("howdy");
- this.addWindowListener(this);
- this.requestFocus();
- }
- public static void main(String[] args) throws IOException
- {
- new Bounce();
- }
- private void drawFrame() {
- System.out.println("HELLO");
- SpeedBar.setSize(5, 5);
- System.out.println(SpeedBar.getSize());
- }
- public void windowActivated(WindowEvent e) {
- }
- public void windowClosed(WindowEvent e) {
- System.exit(0);
- }
- public void windowClosing(WindowEvent e) {
- this.removeWindowListener(this);
- this.dispose();
- }
- public void windowDeactivated(WindowEvent e) {
- }
- public void windowDeiconified(WindowEvent e) {
- }
- public void windowIconified(WindowEvent e) {
- }
- public void windowOpened(WindowEvent e) {
- }
- public void actionPerformed(ActionEvent e) {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement