📄 statuslabel.java
字号:
package joeh.asciidraw;
import java.awt.*;
import java.applet.*;
import java.util.*;
import java.io.*;
//we extend label so that we can control the case that they click on us and send the
//focus back to the place that needs to receive typing events
public class StatusLabel extends Label {
AsciiDrawPanel adp;
public StatusLabel(String initMessage, AsciiDrawPanel p) {
super(initMessage);
adp = p;
}
public boolean handleEvent(Event evt)
{
switch(evt.id)
{
case Event.MOUSE_DOWN:
{
adp.requestFocus(); //give the focus back to the panel so that
//it can be typed to without first having to click the mouse there.
return true;
}
}
return true;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -