0% found this document useful (0 votes)
9 views2 pages

Experiment No - 13

Uploaded by

Pratik Desai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views2 pages

Experiment No - 13

Uploaded by

Pratik Desai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

// Experiment No- 13-XIII-1//

importjava.awt.event.WindowAdapter;
importjava.awt.event.WindowEvent;
importjava.awt.event.WindowListener;
importjava.awt.*;
public class WindowAdapterTest
{
public static void main(String args[])
{
Frame frame = new Frame("Window Listener");
frame.addWindowListener(new WindowAdapter()
{
public void windowClosing(WindowEvent w)
{
System.exit(0);
}
});
frame.setSize(300, 300);
frame.setVisible(true);
}
}
// Experiment No- 13-XIII-3//
importjava.awt.*;
importjava.awt.event.*;
importjava.applet.*;
public class MouseMotionAdapterDemo extendsApplet
{
public void init()
{
addMouseMotionListener(new MouseMotionAdapter()
{
public void mouseDragged(MouseEvent me)
{
showStatus("Mouse Dragged");
}
});
}
}
/*<appletcode="MouseMotionAdapterDemo.class" height=300 width=300></applet>*/

You might also like