首页 > 学院 > 开发设计 > 正文

用Java编写的记事本程序(3)

2019-11-18 13:37:38
字体:
来源:转载
供稿:网友

  class Pop_undo_actionAdapter implements java.awt.event.ActionListener{
Jsb adaptee;
Pop_undo_actionAdapter(Jsb adaptee){
this.adaptee=adaptee;
}
public void actionPerformed(ActionEvent e){
adaptee.pop_undo_actionPerformed(e);
}
}

class Pop_cut_actionAdapter implements java.awt.event.ActionListener{
Jsb adaptee;
Pop_cut_actionAdapter(Jsb adaptee){
this.adaptee=adaptee;
}
public void actionPerformed(ActionEvent e){
adaptee.pop_cut_actionPerformed(e);
}
}

class Pop_copy_actionAdapter implements java.awt.event.ActionListener{
Jsb adaptee;
Pop_copy_actionAdapter(Jsb adaptee){
this.adaptee=adaptee;
}
public void actionPerformed(ActionEvent e){
adaptee.pop_copy_acionPerformed(e);
}
}

class Pop_paste_actionAdapter implements java.awt.event.ActionListener{
Jsb adaptee;
Pop_paste_actionAdapter(Jsb adaptee){
this.adaptee=adaptee;
}
public void actionPerformed(ActionEvent e){
adaptee.pop_paste_actionPerformed(e);
}
}

class Pop_delete_actionAdapter implements java.awt.event.ActionListener{
Jsb adaptee;
Pop_delete_actionAdapter(Jsb adaptee){
this.adaptee=adaptee;
}
public void actionPerformed(ActionEvent e){
adaptee.pop_delete_actionPerformed(e);
}
}

/******************* Event class end **********************************/
/*************************************************************
* title: DlgText.java
* author: jeason
* date: 2004-12-21
**************************************************************/
package jeason;

import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class Dlgtext extends JDialog{
PRivate boolean check=false;

JLabel text=new JLabel( );
JButton BTnOk=new JButton( );
JButton btnNo=new JButton( );

FlowLayout flowLayout1=new FlowLayout();

Dlgtext(){
this(null,"",false);
}

Dlgtext(Frame frame, String title, boolean modal){
super(frame,title,modal);

text.setText(" 你要保存吗? ");
text.setSize(200,60);

this.setSize(200,80);
this.setModal(true);

btnOk.setText("确定(Y)");
btnOk.setMnemonic(´Y´);


发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表