📄 searchdialog.java
字号:
import java.awt.Frame;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import java.awt.event.WindowListener;
import javax.swing.JDialog;
/**
* @author ThunellE
*
* To change this generated comment edit the template variable "typecomment":
* Window>Preferences>Java>Templates.
* To enable and disable the creation of type comments go to
* Window>Preferences>Java>Code Generation.
*/
public class SearchDialog extends JDialog
{
/**
* Comment for <code>serialVersionUID</code>
*/
private static final long serialVersionUID = -5193131794786297752L;
String searchComponent;
/**
* Constructor for SearchDialog.
*/
public SearchDialog(Frame owner)
{
super(owner);
final WindowListener winLis = new WindowAdapter()
{
public void windowDeactivated(WindowEvent e)
{
Editor.getEditor().getFrame().setNotSearching(false);
}
public void windowActivated(WindowEvent e)
{
Editor.getEditor().getFrame().setNotSearching(true);
}
};
this.addWindowListener(winLis);
}
public void setSearchComponent(String searchComponent)
{
this.searchComponent = searchComponent;
}
public String getSearchComponent()
{
return searchComponent;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -