Chapter 13


Click here to start

Table of contents

Chapter 13

Chapter 13 Objectives

GUI Objects

Interacting with Buttons

Creating a Frame Object

Placing a Button on a Frame

Handling Action Events - ActionListener

Handling Action Events - actionPerformed

Handling Window Events

Adding Menus to a Frame

Handling Menu Selection

Mouse Events - MouseListener

Mouse Events - mouseClicked

Mouse Move Events - MouseMotionListener

Mouse Motion Events - mouseDragged

Other GUI Objects

Running Applets as Applications

Sample Class: A Simple Calculator

Sample Interaction

Development Steps

Author: Robert Rittenhouse

E-mail: rob@cs1.mcm.edu

Homepage: http://cs1.mcm.edu/~rob