📄 timer.java
字号:
//package com.sam.net.download;
//
//public class Timer extends Thread
//{
//
// int ss;
// int mm;
// int hh;
//
// public Timer()
// {
// ss = 0;
// mm = 0;
// hh = 0;
// }
//
// public void run()
// {
// do
// {
// if (ss < 10 && mm < 10 && hh < 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:0")).append(hh).append(":0").append(mm).append(":0").append(ss).toString());
// else
// if (ss < 10 && mm >= 10 && hh < 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:0")).append(hh).append(":").append(mm).append(":0").append(ss).toString());
// else
// if (ss < 10 && mm >= 10 && hh >= 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:")).append(hh).append(":").append(mm).append(":0").append(ss).toString());
// else
// if (ss < 10 && mm < 10 && hh >= 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:")).append(hh).append(":0").append(mm).append(":0").append(ss).toString());
// else
// if (ss >= 10 && mm < 10 && hh < 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:0")).append(hh).append(":0").append(mm).append(":").append(ss).toString());
// else
// if (ss >= 10 && mm >= 10 && hh < 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:0")).append(hh).append(":").append(mm).append(":").append(ss).toString());
// else
// if (ss >= 10 && mm >= 10 && hh >= 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:")).append(hh).append(":").append(mm).append(":").append(ss).toString());
// else
// if (ss >= 10 && mm < 10 && hh >= 10)
// MainFrame.yunxingtime.setText((new StringBuilder("程序已运行:")).append(hh).append(":0").append(mm).append(":").append(ss).toString());
// if (ss >= 59)
// {
// ss = 0;
// if (mm >= 59)
// {
// mm = 0;
// hh++;
// } else
// {
// mm++;
// }
// } else
// {
// ss++;
// }
// try
// {
// sleep(1000L);
// }
// catch (InterruptedException e)
// {
// e.printStackTrace();
// }
// String as[];
// if (MainFrame.tablemodel.downloadingList.size() != 0)
// as = new String[MainFrame.tablemodel.downloadingList.size()];
// MainFrame.renwushulb.setText((new StringBuilder("正在运行的任务数:")).append(MainFrame.tablemodel.downloadingList.size()).toString());
// } while (true);
// }
//}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -