📄 imageupdatethread.java
字号:
/* * To change this template, choose Tools | Templates * and open the template in the editor. */package screenpen;import java.util.logging.Level;import java.util.logging.Logger;/** * * @author zhaolin */public class ImageUpdateThread extends Thread{ private Main main; private boolean stop = false; public ImageUpdateThread(Main main){ this.main = main; } public boolean isStop() { return stop; } public void setStop(boolean stop) { this.stop = stop; } public void run(){ while(!stop){ try { main.updateImage(); main.repaint(); Thread.sleep(2000); } catch (InterruptedException ex) { Logger.getLogger(ImageUpdateThread.class.getName()).log(Level.SEVERE, null, ex); } } }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -